public class ShapeNode extends AbstractGraphicsNode
| Modifier and Type | Field and Description |
|---|---|
protected java.awt.Shape |
shape
The shape that describes this ShapeNode.
|
protected ShapePainter |
shapePainter
The shape painter used to paint the shape of this shape node.
|
changeCompletedEvent, changeStartedEvent, clip, composite, enableBackgroundGraphicsNodeRable, filter, graphicsNodeRable, hints, inverseTransform, isVisible, listeners, mask, parent, pointerEventType, root, transform, weakRefALL, FILL, IDENTITY, NONE, PAINTED, STROKE, VISIBLE, VISIBLE_FILL, VISIBLE_PAINTED, VISIBLE_STROKE| Constructor and Description |
|---|
ShapeNode()
Constructs a new empty ShapeNode.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
contains(java.awt.geom.Point2D p)
Returns true if the specified Point2D is inside the boundary of this
node, false otherwise.
|
java.awt.geom.Rectangle2D |
getGeometryBounds()
Returns the bounds of the area covered by this node, without
taking any of its rendering attribute into account.
|
java.awt.Shape |
getOutline()
Returns the outline of this node.
|
java.awt.geom.Rectangle2D |
getPrimitiveBounds()
Returns the bounds of the area covered by this node's primitive paint.
|
java.awt.Shape |
getSensitiveArea()
Returns the shape that represents the sensitive area of this graphics
node.
|
java.awt.geom.Rectangle2D |
getSensitiveBounds()
Returns the bounds of the sensitive area covered by this node,
This includes the stroked area but does not include the effects
of clipping, masking or filtering.
|
java.awt.Shape |
getShape()
Returns the shape of this ShapeNode.
|
ShapePainter |
getShapePainter()
Returns the ShapePainter used by this shape node to render its
shape.
|
boolean |
inSensitiveArea(java.awt.geom.Point2D pt) |
boolean |
intersects(java.awt.geom.Rectangle2D r)
Returns true if the interior of this node intersects the interior of a
specified Rectangle2D, false otherwise.
|
protected void |
invalidateGeometryCache()
Invalidates this ShapeNode.
|
void |
paint(java.awt.Graphics2D g2d)
Paints this node.
|
void |
primitivePaint(java.awt.Graphics2D g2d)
Paints this node without applying Filter, Mask, Composite, and clip.
|
void |
setPointerEventType(int pointerEventType)
Sets the type that describes how this graphics node reacts to events.
|
void |
setShape(java.awt.Shape newShape)
Sets the shape of this ShapeNode.
|
void |
setShapePainter(ShapePainter newShapePainter)
Sets the ShapePainter used by this shape node to render its
shape.
|
fireGraphicsNodeChangeCompleted, fireGraphicsNodeChangeStarted, fireGraphicsNodeChangeStarted, fireGraphicsNodeChangeStarted, getBounds, getClip, getComposite, getEnableBackgroundGraphicsNodeRable, getFilter, getGlobalTransform, getGraphicsNodeRable, getInverseTransform, getMask, getParent, getPointerEventType, getRenderingHints, getRoot, getTransform, getTransformedBounds, getTransformedGeometryBounds, getTransformedPrimitiveBounds, getTransformedSensitiveBounds, getWeakReference, isAntialiasedClip, isOffscreenBufferNeeded, isVisible, nodeHitAt, normalizeRectangle, setClip, setComposite, setFilter, setMask, setParent, setRenderingHint, setRenderingHints, setRenderingHints, setRoot, setTransform, setVisibleprotected java.awt.Shape shape
protected ShapePainter shapePainter
public void setShape(java.awt.Shape newShape)
newShape - the new shape of this shape nodepublic java.awt.Shape getShape()
public void setShapePainter(ShapePainter newShapePainter)
newShapePainter - the new ShapePainter to usepublic ShapePainter getShapePainter()
public void paint(java.awt.Graphics2D g2d)
paint in interface GraphicsNodepaint in class AbstractGraphicsNodeg2d - the Graphics2D to usepublic void primitivePaint(java.awt.Graphics2D g2d)
g2d - the Graphics2D to useprotected void invalidateGeometryCache()
invalidateGeometryCache in class AbstractGraphicsNodepublic void setPointerEventType(int pointerEventType)
AbstractGraphicsNodesetPointerEventType in interface GraphicsNodesetPointerEventType in class AbstractGraphicsNodepointerEventType - VISIBLE_PAINTED | VISIBLE_FILL | VISIBLE_STROKE |
VISIBLE | PAINTED | FILL | STROKE | ALL | NONEpublic boolean contains(java.awt.geom.Point2D p)
contains in interface GraphicsNodecontains in class AbstractGraphicsNodep - the specified Point2D in the user spacepublic boolean intersects(java.awt.geom.Rectangle2D r)
intersects in interface GraphicsNodeintersects in class AbstractGraphicsNoder - the specified Rectangle2D in the user node spacepublic java.awt.geom.Rectangle2D getPrimitiveBounds()
public boolean inSensitiveArea(java.awt.geom.Point2D pt)
public java.awt.geom.Rectangle2D getSensitiveBounds()
public java.awt.Shape getSensitiveArea()
public java.awt.geom.Rectangle2D getGeometryBounds()
public java.awt.Shape getOutline()
Copyright ? 2009 Apache Software Foundation. All Rights Reserved.