3 public class Exemple2 {
5 public static void main(String[] args) {
6 DrawingWindow w = new DrawingWindow("Exemple 3", 640, 480);
8 int width = Math.min(w.width - 1, w.height - 1) / 2;
10 for (int z = 0; z <= width; z++) {
12 float s = 3.0f * z / width;
13 if (z <= width / 3.0f) {
17 } else if (z <= 2.0f * width / 3.0f) {
29 w.drawRect(z, z, w.width - 1 - z, w.height - 1 - z);