public class PathShape extends ShapeDelegate
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
TOOL_KEY |
Constructor and Description |
---|
PathShape()
Deprecated.
|
PathShape(java.awt.geom.GeneralPath path) |
Modifier and Type | Method and Description |
---|---|
boolean |
alterShape(java.awt.geom.Rectangle2D newRect)
Directly modify the shape's frame so that it fits tightly within the new framing rectangle.
|
java.awt.geom.GeneralPath |
convertToPath()
Convert this shape to a GeneralPath
|
java.awt.geom.GeneralPath |
getPath() |
java.awt.Shape |
getShape()
The AWT shape this delegate produces
|
java.lang.String |
getToolKey() |
boolean |
isRotatable()
Some shape delegates prefer to handle rotation themselves, instead of having the PathBasedVisionShape parent
rotate their shape after the fact.
|
boolean |
isSymmetric() |
void |
rotate(double angle,
java.awt.geom.Point2D anchor) |
void |
setPath(java.awt.geom.GeneralPath path) |
void |
transform(java.awt.geom.AffineTransform transform) |
void |
translateShape(double dX,
double dY)
Move the shape using the provided offsets.
|
createArea, getBounds2D, getCenterpoint
public static final java.lang.String TOOL_KEY
@Deprecated public PathShape()
public PathShape(java.awt.geom.GeneralPath path)
public java.lang.String getToolKey()
getToolKey
in class ShapeDelegate
public java.awt.Shape getShape()
ShapeDelegate
getShape
in class ShapeDelegate
public java.awt.geom.GeneralPath getPath()
public void setPath(java.awt.geom.GeneralPath path)
public void transform(java.awt.geom.AffineTransform transform)
public boolean isSymmetric()
isSymmetric
in class ShapeDelegate
public boolean alterShape(java.awt.geom.Rectangle2D newRect)
ShapeDelegate
alterShape
in class ShapeDelegate
newRect
- The new bounding rectangle for the shape.public void translateShape(double dX, double dY)
ShapeDelegate
translateShape
in class ShapeDelegate
public boolean isRotatable()
ShapeDelegate
isRotatable
in class ShapeDelegate
public void rotate(double angle, java.awt.geom.Point2D anchor)
rotate
in class ShapeDelegate
public java.awt.geom.GeneralPath convertToPath()
ShapeDelegate
convertToPath
in class ShapeDelegate