public  MinuetoRectangle(int sizeX, int sizeY, MinuetoColor color, boolean fill)
   {
   	
		/* When subclassing to a class with multiple constructor,it's
		* important to specify which constructor to use. */
		super();
		
		if (sizeX < 1) throw new MinuetoZeroNegativeException("Cannot create rectangle of width " + sizeX);
		if (sizeY < 1) throw new MinuetoZeroNegativeException("Cannot create rectangle of height " + sizeY);
		if (color == null) throw new NullPointerException();
		
		BufferedImage bufferedImage;
		Graphics2D graphics2D;
   	   	
		/* Create the surface to draw the rectangle on. */
		bufferedImage = ImageTools.createImage( sizeX, sizeY );
		graphics2D = bufferedImage.createGraphics();
   	   	
		/* Set the color of the rectangle. */
		graphics2D.setColor(color.getAWTColor());
   	   	
		/* Draw the rectangle onto our surface. */
		if (fill == true) {
			graphics2D.fillRect(0,0,sizeX,sizeY);
			
		} else {
			graphics2D.drawRect(0,0,sizeX-1,sizeY-1);
			
		}
		
		super.setUpImage(bufferedImage);   	   	
   }