import java.applet.Applet; import java.awt.Graphics; import java.awt.Color; import java.awt.Font; public class afg1 extends Applet { /** * Initializes the applet. You never need to call this directly; it is * called automatically by the system once the applet is created. */ int estado = 1; Font f1 = new Font ("Helvetica", Font.ITALIC, 50); public void paint (Graphics g){ g.setColor (Color.blue); g.fillRect (30, 40, 400, 400); g.setColor (Color.black); g.fillRect (33, 43, 390, 390); g.setColor (Color.red); g.fillRect (65, 220, 100, 160); g.setColor (Color.white); g.fillOval (65, 210, 100, 30); g.setFont (f1); g.drawString ("CHESCO-", 55, 115); g.drawString ("MATIC", 55, 185); } public void init() { } /** * Called to start the applet. You never need to call this directly; it * is called when the applet's document is visited. */ public void start() { } /** * Called to stop the applet. This is called when the applet's document is * no longer on the screen. It is guarenteed to be called before destroy() * is called. You never need to call this method directly */ public void stop() { } /** * Cleans up whatever resources are being held. If the applet is active * it is stopped. */ public void destroy() { } }