- Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlight.java
More file actions
Latest commit
57 lines (49 loc) · 1.41 KB
/
Copy pathlight.java
File metadata and controls
57 lines (49 loc) · 1.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
/*
* light.java
*
* Created on Aug 19, 2002, 10:08:05 PM
*/
/**
*
* @author g1.test1
*/importjava.applet.*;
importjava.awt.*;
publicclasslightextendsjava.applet.Applet {
publicvoidpaint(Graphicsa)
{
a.setColor(Color.black);
a.fillRect(50, 20, 100, 250);
a.setColor(Color.red);
a.fillOval(75,30 , 50, 50);
a.setColor(Color.yellow);
a.fillOval(75,85 , 50, 50);
a.setColor(Color.green);
a.fillOval(75,140 , 50, 50);
}
publicvoidinit() {
try {
java.awt.EventQueue.invokeAndWait(newRunnable() {
publicvoidrun() {
initComponents();
}
});
} catch (Exceptionex) {
ex.printStackTrace();
}
}
/** This method is called from within the init() method to
* initialize the form.
* WARNING: Do NOT modify this code. The content of this method is
* always regenerated by the Form Editor.
*/
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
privatevoidinitComponents() {
setLayout(newjava.awt.BorderLayout());
}// </editor-fold>//GEN-END:initComponents
// Variables declaration - do not modify//GEN-BEGIN:variables
// End of variables declaration//GEN-END:variables
}