Actividad 4
EJEMPLOS APPLET
import java.awt.Color;
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
/*
* marinmatiz.java*
* Created on 27/10/2011, 04:48:12 PM
*/
/**
*
* @author BRYLLITH
*/
public class marinmatiz extends javax.swing.JApplet {
/** Initializes the appletmarinmatiz */
public void init() {
try {
java.awt.EventQueue.invokeAndWait(new Runnable() {
public void run() {
initComponents();}
});
} catch (Exception ex) {
ex.printStackTrace();
}
}
/** This method is called from within the init() methodto
* initialize the form.
* WARNING: Do NOT modify this code. The content of this method is
* always regenerated by the Form Editor.
*/@SuppressWarnings("unchecked")
// //GEN-BEGIN:initComponents
private void initComponents() {
jLabel1 = new javax.swing.JLabel();
jButton1 = new javax.swing.JButton();jButton2 = new javax.swing.JButton();
jButton3 = new javax.swing.JButton();
jLabel1.setFont(new java.awt.Font("Tahoma", 0, 18)); // NOI18N
jLabel1.setForeground(newjava.awt.Color(102, 102, 255));
jLabel1.setText("HOLA PROFESORA");
jButton1.setText("ROJO");
jButton1.setActionCommand("jButton1");jButton1.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jButton1ActionPerformed(evt);
}});
jButton2.setText("VERDE");
jButton2.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {...
Regístrate para leer el documento completo.