graphics
Class FramedRectangle
java.lang.Object
graphics.AbstractGraphic
graphics.AbstractColorableGraphic
graphics.FramedRectangle
- All Implemented Interfaces:
- CenterLocatable, IColorable, IColorableGraphic, IGraphic, ILocatable, IRotatable, ISizeable
public class FramedRectangle
- extends AbstractColorableGraphic
A Graphic that is the outline of a rectangle.
- Author:
- Michael Kozelsky
Created on: Jul 29, 2006 Rectangle.java
Constructor Summary |
FramedRectangle()
Creates a new instance of the Rectangle Graphic with dimension (0,0) and
location(0,0) |
Method Summary |
void |
actualPaint(Graphics2D gs,
Point location,
Dimension dimension)
This method uses the Graphics2D object to paint a FramedRectangle onto
the container at a specified point with a specified dimension |
Shape |
getShape()
Should return a java.awt.Shape representation of this graphic. |
Methods inherited from class graphics.AbstractGraphic |
addMouseListener, addMouseMotionListener, contains, getBounds, getCenterLocation, getContainer, getDimension, getLocation, getMouseListeners, getMouseMotionListeners, getMovement, getRotation, intersects, move, rotate, setCenterLocation, setContainer, setDimension, setLocation, setMovement, setRotation |
Methods inherited from interface graphics.IGraphic |
addMouseListener, addMouseMotionListener, contains, getBounds, getContainer, getMouseListeners, getMouseMotionListeners, getMovement, intersects, setContainer, setMovement |
FramedRectangle
public FramedRectangle()
- Creates a new instance of the Rectangle Graphic with dimension (0,0) and
location(0,0)
actualPaint
public void actualPaint(Graphics2D gs,
Point location,
Dimension dimension)
- This method uses the Graphics2D object to paint a FramedRectangle onto
the container at a specified point with a specified dimension
- Parameters:
gs
- The Graphics2D object to do the paintinglocation
- The point at which to paint the rectangledimension
- The dimension of the rectangle to paint- See Also:
IGraphic.actualPaint(java.awt.Graphics2D,
java.awt.Point, java.awt.Dimension)
getShape
public Shape getShape()
- Description copied from interface:
IGraphic
- Should return a java.awt.Shape representation of this graphic.
The shape is used as a delegate for the methods: contains, intersects, etc.
- Returns:
- a java.awt.Rectangle
- See Also:
IGraphic.getShape()