1 package org.catacomb.graph.drawing; 2 3 4 import java.awt.Color; 5 6 7 8 public class Square extends Rectangle { 9 10 11 public Square() { 12 super(); 13 } 14 15 public Square(double d, double e, double f, double g) { 16 super(d, e, f, g); 17 } 18 19 20 public static Square defaultSquare() { 21 Square d = new Square(); 22 d.rx = 1.0; 23 d.ry = 1.0; 24 d.setColor(Color.red); 25 d.setFilled(); 26 d.setFillColor(Color.blue); 27 return d; 28 } 29 30 31 32 public void applySymmetryToShape(Shape shp) { 33 shp.setSymmetry(ShapeSymmetry.SQUARE); 34 } 35 36 }