1 2 /* 3 * program to paint a blue dot in the context of the nonrepresentational 4 * painting world, npw 5 * 6 */ 7 8 9 10 11 package npw; 12 import java.awt.Color; 13 import javax.swing.SwingUtilities; 14 import painter.SPainter; 15 import shapes.SCircle; 16 17 public class BlueDot { //solution to the blue dot problem 18 19 private void paintTheImage() { 20 SPainter klee = new SPainter("Blue Dot",600,600); 21 SCircle dot = new SCircle(200); 22 klee.setColor(Color.BLUE); 23 klee.paint(dot); 24 } 25 // required infrastructure 26 27 public BlueDot() { 28 29 paintTheImage(); 30 } 31 32 33 public static void main(String[] args) { 34 SwingUtilities.invokeLater(new Runnable() { 35 public void run() { 36 new BlueDot(); 37 } 38 39 40 }); 41 } 42 43 44 } 45