GreenT.java
1    package npw;
2    
3    import java.awt.Color;
4    import javax.swing.SwingUtilities;
5    
6    import painter.SPainter;
7    import shapes.SRectangle;
8    
9    public class GreenT {
10       public static void main(String[] args) {
11           SwingUtilities.invokeLater(new Runnable() {
12               public void run() {
13                   new GreenT();
14               }
15           });
16       }
17   
18   
19       public GreenT() {
20           paintTheImage();
21       }
22   
23       private void paintTheImage() {
24           SPainter J = new SPainter("greenT", 600, 600);
25   
26           SRectangle Horizontal = new SRectangle(400, 100);
27           J.mbk(50);
28   
29           J.setColor(Color.green);
30   
31   
32           J.paint(Horizontal);
33   //        J.moveToCenter();
34           J.mfd(250);
35           J.tr();
36           J.paint(Horizontal);
37   
38   
39       }
40   }