import java.applet.Applet;
import java.awt.*;
import java.awt.event.*;
public class FirstButton extends Applet  implements ActionListener {
      Label label;
      Button button;
   public void init() {
      setBackground(Color.orange);
      setFont(new Font("SansSerif", Font.BOLD, 18));
      label = new Label();
      label.setText("This is my first button :-)");
      add(label);
      button = new Button("Knopf");
      button.setBackground(Color.white);
      button.addActionListener(this);
      add(button);
   }
   public void paint(Graphics page) {
      page.setColor(Color.red);
      page.fillRect(200,0,100,100);
      page.setColor(Color.blue);
      page.fillRect(225,25,50,50);
   }
   public void actionPerformed(ActionEvent e) {
      label.setText("Damn - you pressed it ...");
      System.out.println(e);
      remove(button);
   }
} // end of Applet FirstButton
     


