/** * Copyright (c): Uwe Schmidt, FH Wedel * * You may study, modify and distribute this source code * FOR NON-COMMERCIAL PURPOSES ONLY. * This copyright message has to remain unchanged. * * Note that this document is provided 'as is', * WITHOUT WARRANTY of any kind either expressed or implied. */ import java.awt.Color; import java.awt.Graphics; import javax.swing.JApplet; public class SwingHelloWorld extends JApplet { public void paint(Graphics g) { setBackground( Color.red ); setForeground( Color.yellow ); super.paint(g); g.drawString( "Hello World!", 50, 50 ); } }