public class VectorFigure extends AbstractFigure
Modifier and Type | Field and Description |
---|---|
(package private) static int |
FILLMODE |
(package private) static int |
LINEMODE |
Constructor and Description |
---|
VectorFigure()
Create a new blank figure.
|
Modifier and Type | Method and Description |
---|---|
void |
add(java.awt.Composite c)
Add a new compositioning operator to the list of drawn objects.
|
void |
add(Figure f)
Add a new figure to the list of drawn objects
|
void |
add(java.awt.Paint p)
Add a new paint to the list of drawn objects.
|
void |
add(java.awt.Shape s)
Add a new painted shape to the list of drawn objects.
|
void |
add(java.awt.Stroke s)
Add a new stroke to the list of drawn objects.
|
void |
fillMode()
Add an object to the list that puts drawing into fill mode
|
java.awt.geom.Rectangle2D |
getBounds()
Get the bounding box of this figure.
|
java.awt.Shape |
getShape()
Get the shape of this figure.
|
void |
lineMode()
Add an object to the list that puts drawing into line mode
|
void |
paint(java.awt.Graphics2D g)
Paint the figure.
|
void |
setShape(java.awt.Shape s)
Set the shape of this Figure.
|
void |
transform(java.awt.geom.AffineTransform at)
Transform the figure with the supplied transform.
|
contains, getInteractor, getLayer, getOrigin, getParent, getToolTipText, getTransformContext, getUserObject, hit, intersects, isVisible, paint, repaint, repaint, setInteractor, setParent, setToolTipText, setUserObject, setVisible, translate
static final int FILLMODE
static final int LINEMODE
public void add(java.awt.Shape s)
public void add(Figure f)
public void add(java.awt.Composite c)
public void add(java.awt.Paint p)
public void add(java.awt.Stroke s)
public void fillMode()
public java.awt.geom.Rectangle2D getBounds()
getBounds
in interface Figure
getBounds
in class AbstractFigure
public java.awt.Shape getShape()
getShape
in interface Figure
getShape
in class AbstractFigure
public void lineMode()
public void paint(java.awt.Graphics2D g)
paint
in interface VisibleComponent
paint
in class AbstractFigure
g
- The 2D graphics object that this object
it to be painted upon.public void setShape(java.awt.Shape s)
public void transform(java.awt.geom.AffineTransform at)
transform
in interface Figure
transform
in class AbstractFigure
at
- The transform to be used.