|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface GraphicsNode
The base class for all graphics nodes. A GraphicsNode encapsulates graphical attributes and can perform atomic operations of a complex rendering.
| Field Summary | |
|---|---|
static int |
ALL
Indicates that this graphics node can be the target for events if any cases. |
static int |
FILL
Indicates that this graphics node can be the target for events when the mouse is over the filled area whatever or not it is the visible. |
static AffineTransform |
IDENTITY
The identity affine transform matrix used to draw renderable images. |
static int |
NONE
Indicates that this graphics node can not be the target for events. |
static int |
PAINTED
Indicates that this graphics node can be the target for events when the mouse is over the painted area whatever or not it is the visible. |
static int |
STROKE
Indicates that this graphics node can be the target for events when the mouse is over the stroked area whatever or not it is the visible. |
static int |
VISIBLE
Indicates that this graphics node can be the target for events when it is visible and whatever is the filled and stroked area. |
static int |
VISIBLE_FILL
Indicates that this graphics node can be the target for events when it is visible and when the mouse is over the filled area if any. |
static int |
VISIBLE_PAINTED
Indicates that this graphics node can be the target for events when it is visible and when the mouse is over the "painted" area. |
static int |
VISIBLE_STROKE
Indicates that this graphics node can be the target for events when it is visible and when the mouse is over the stroked area if any. |
| Method Summary | |
|---|---|
boolean |
contains(Point2D p)
Returns true if the specified Point2D is inside the boundary of this node, false otherwise. |
Rectangle2D |
getBounds()
Returns the bounds of this node in user space. |
ClipRable |
getClip()
Returns the clipping filter of this node or null if any. |
Composite |
getComposite()
Returns the composite of this node or null if any. |
Filter |
getEnableBackgroundGraphicsNodeRable(boolean createIfNeeded)
Returns the GraphicsNodeRable for this node. |
Filter |
getFilter()
Returns the filter of this node or null if any. |
Rectangle2D |
getGeometryBounds()
Returns the bounds of the area covered by this node, without taking any of its rendering attribute into account. |
AffineTransform |
getGlobalTransform()
Returns the concatenated transform of this node. |
Filter |
getGraphicsNodeRable(boolean createIfNeeded)
Returns the GraphicsNodeRable for this node. |
AffineTransform |
getInverseTransform()
Returns the inverse transform for this node. |
Mask |
getMask()
Returns the mask of this node or null if any. |
Shape |
getOutline()
Returns the outline of this node. |
CompositeGraphicsNode |
getParent()
Returns the parent of this node or null if any. |
int |
getPointerEventType()
Returns the type that describes how this graphics node reacts to events. |
Rectangle2D |
getPrimitiveBounds()
Returns the bounds of the area covered by this node's primitive paint. |
RenderingHints |
getRenderingHints()
Returns the rendering hints of this node or null if any. |
RootGraphicsNode |
getRoot()
Returns the root of the GVT tree or null if the node is not part of a GVT tree. |
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. |
AffineTransform |
getTransform()
Returns the transform of this node or null if any. |
Rectangle2D |
getTransformedBounds(AffineTransform txf)
Returns the bounds of this node after applying the input transform (if any), concatenated with this node's transform (if any). |
Rectangle2D |
getTransformedGeometryBounds(AffineTransform txf)
Returns the bounds of the area covered by this node, without taking any of its rendering attribute into accoun. |
Rectangle2D |
getTransformedPrimitiveBounds(AffineTransform txf)
Returns the bounds of this node's primitivePaint after applying the input transform (if any), concatenated with this node's transform (if any). |
Rectangle2D |
getTransformedSensitiveBounds(AffineTransform txf)
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. |
WeakReference |
getWeakReference()
Returns a canonical WeakReference to this GraphicsNode. |
boolean |
intersects(Rectangle2D r)
Returns true if the interior of this node intersects the interior of a specified Rectangle2D, false otherwise. |
boolean |
isVisible()
Returns true if this node is visible, false otherwise. |
GraphicsNode |
nodeHitAt(Point2D p)
Returns the GraphicsNode containing point p if this node or one of its children is sensitive to mouse events at p. |
void |
paint(Graphics2D g2d)
Paints this node. |
void |
primitivePaint(Graphics2D g2d)
Paints this node without applying Filter, Mask, Composite, and clip. |
void |
setClip(ClipRable newClipper)
Sets the clipping filter of this node. |
void |
setComposite(Composite newComposite)
Sets the composite of this node. |
void |
setFilter(Filter newFilter)
Sets the filter of this node. |
void |
setMask(Mask newMask)
Sets the mask of this node. |
void |
setPointerEventType(int pointerEventType)
Sets the type that describes how this graphics node reacts to events. |
void |
setRenderingHint(RenderingHints.Key key,
Object value)
Maps the specified key to the specified value in the rendering hints of this node. |
void |
setRenderingHints(Map hints)
Copies all of the mappings from the specified Map to the rendering hints of this node. |
void |
setRenderingHints(RenderingHints newHints)
Sets the rendering hints of this node. |
void |
setTransform(AffineTransform newTransform)
Sets the transform of this node. |
void |
setVisible(boolean isVisible)
Sets if this node is visible or not depending on the specified value. |
| Field Detail |
|---|
static final int VISIBLE_PAINTED
static final int VISIBLE_FILL
static final int VISIBLE_STROKE
static final int VISIBLE
static final int PAINTED
static final int FILL
static final int STROKE
static final int ALL
static final int NONE
static final AffineTransform IDENTITY
| Method Detail |
|---|
WeakReference getWeakReference()
int getPointerEventType()
void setPointerEventType(int pointerEventType)
pointerEventType - VISIBLE_PAINTED | VISIBLE_FILL | VISIBLE_STROKE |
VISIBLE | PAINTED | FILL | STROKE | ALL | NONEvoid setTransform(AffineTransform newTransform)
newTransform - the new transform of this nodeAffineTransform getTransform()
AffineTransform getInverseTransform()
AffineTransform getGlobalTransform()
void setComposite(Composite newComposite)
newComposite - the composite of this nodeComposite getComposite()
void setVisible(boolean isVisible)
isVisible - If true this node is visibleboolean isVisible()
void setClip(ClipRable newClipper)
newClipper - the new clipping filter of this nodeClipRable getClip()
void setRenderingHint(RenderingHints.Key key,
Object value)
key - the key of the hint to be setvalue - the value indicating preferences for the specified
hint category.void setRenderingHints(Map hints)
hints - the rendering hints to be setvoid setRenderingHints(RenderingHints newHints)
newHints - the new rendering hints of this nodeRenderingHints getRenderingHints()
void setMask(Mask newMask)
newMask - the new mask of this nodeMask getMask()
void setFilter(Filter newFilter)
newFilter - the new filter of this nodeFilter getFilter()
Filter getGraphicsNodeRable(boolean createIfNeeded)
Filter getEnableBackgroundGraphicsNodeRable(boolean createIfNeeded)
void paint(Graphics2D g2d)
g2d - the Graphics2D to usevoid primitivePaint(Graphics2D g2d)
g2d - the Graphics2D to useCompositeGraphicsNode getParent()
RootGraphicsNode getRoot()
Rectangle2D getBounds()
Rectangle2D getTransformedBounds(AffineTransform txf)
txf - the affine transform with which this node's transform should
be concatenated. Should not be null.Rectangle2D getPrimitiveBounds()
Rectangle2D getTransformedPrimitiveBounds(AffineTransform txf)
txf - the affine transform with which this node's transform should
be concatenated. Should not be null.Rectangle2D getGeometryBounds()
Rectangle2D getTransformedGeometryBounds(AffineTransform txf)
txf - the affine transform with which this node's transform should
be concatenated. Should not be null.Rectangle2D getSensitiveBounds()
Rectangle2D getTransformedSensitiveBounds(AffineTransform txf)
txf - the affine transform with which this node's
transform should be concatenated. Should not be null.boolean contains(Point2D p)
p - the specified Point2D in the user spaceboolean intersects(Rectangle2D r)
r - the specified Rectangle2D in the user node spaceGraphicsNode nodeHitAt(Point2D p)
p - the specified Point2D in the user spaceShape getOutline()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||