//filename: Bmw.java import java.awt.*; import java.applet.*; public class Bmw extends Applet { public void paint(Graphics g) { // draw the edge g.setColor(Color.black); g.fillOval(20, 20, 70, 70); // the blue slices g.setColor(Color.blue); g.fillArc(30, 30, 50, 50, 0, 90); g.fillArc(30, 30, 50, 50, 180, 90); // the white slices g.setColor(Color.white); g.fillArc(30, 30, 50, 50, 90, 90); g.fillArc(30, 30, 50, 50, 270, 90); } }
Previou page | Next page |