|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--org.apache.batik.gvt.AbstractGraphicsNode
A partial implementation of the GraphicsNode interface.
| Field Summary | |
protected GraphicsNodeChangeEvent |
changeCompletedEvent
|
protected GraphicsNodeChangeEvent |
changeStartedEvent
|
protected ClipRable |
clip
The clipping filter for this graphics node. |
protected java.awt.Composite |
composite
The compositing operation to be used when a graphics node is painted on top of another one. |
protected java.lang.ref.WeakReference |
enableBackgroundGraphicsNodeRable
The GraphicsNodeRable for this node with all filtering applied |
protected Filter |
filter
The filter of this graphics node. |
protected java.lang.ref.WeakReference |
graphicsNodeRable
The GraphicsNodeRable for this node. |
protected java.awt.RenderingHints |
hints
The rendering hints that control the quality to use when rendering this graphics node. |
protected java.awt.geom.AffineTransform |
inverseTransform
The inverse transform for this node, i.e., from parent node to this node. |
protected boolean |
isVisible
This flag bit indicates whether or not this graphics node is visible. |
protected javax.swing.event.EventListenerList |
listeners
The listeners list. |
protected Mask |
mask
The mask of this graphics node. |
protected CompositeGraphicsNode |
parent
The parent of this graphics node. |
protected int |
pointerEventType
Indicates how this graphics node reacts to events. |
protected RootGraphicsNode |
root
The root of the GVT tree. |
protected java.awt.geom.AffineTransform |
transform
The transform of this graphics node. |
protected java.lang.ref.WeakReference |
weakRef
A Weak Reference to this. |
| Fields inherited from interface org.apache.batik.gvt.GraphicsNode |
ALL, FILL, IDENTITY, NONE, PAINTED, STROKE, VISIBLE, VISIBLE_FILL, VISIBLE_PAINTED, VISIBLE_STROKE |
| Constructor Summary | |
protected |
AbstractGraphicsNode()
Constructs a new graphics node. |
| Method Summary | |
boolean |
contains(java.awt.geom.Point2D p)
Returns true if the specified Point2D is inside the boundary of this node, false otherwise. |
void |
fireGraphicsNodeChangeCompleted()
|
void |
fireGraphicsNodeChangeStarted()
|
void |
fireGraphicsNodeChangeStarted(GraphicsNodeChangeEvent changeStartedEvent)
|
void |
fireGraphicsNodeChangeStarted(java.awt.geom.Rectangle2D from,
java.awt.geom.Rectangle2D to)
|
java.awt.geom.Rectangle2D |
getBounds()
Returns the bounds of this node in user space. |
ClipRable |
getClip()
Returns the clipping filter of this node or null if any. |
java.awt.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. |
java.awt.geom.AffineTransform |
getGlobalTransform()
Returns the concatenated transform of this node. |
Filter |
getGraphicsNodeRable(boolean createIfNeeded)
Returns the GraphicsNodeRable for this node. |
java.awt.geom.AffineTransform |
getInverseTransform()
Returns the inverse transform for this node. |
Mask |
getMask()
Returns the mask of this node or null if any. |
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. |
java.awt.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. |
java.awt.geom.AffineTransform |
getTransform()
Returns the transform of this node or null if any. |
java.awt.geom.Rectangle2D |
getTransformedBounds(java.awt.geom.AffineTransform txf)
Returns the bounds of this node after applying the input transform (if any), concatenated with this node's transform (if any). |
java.awt.geom.Rectangle2D |
getTransformedGeometryBounds(java.awt.geom.AffineTransform txf)
Returns the bounds of the area covered by this node, without taking any of its rendering attribute into account. |
java.awt.geom.Rectangle2D |
getTransformedPrimitiveBounds(java.awt.geom.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). |
java.lang.ref.WeakReference |
getWeakReference()
Returns a canonical WeakReference to this GraphicsNode. |
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 the cached geometric bounds. |
protected boolean |
isAntialiasedClip(java.awt.geom.AffineTransform usr2dev,
java.awt.RenderingHints hints,
java.awt.Shape clip)
Returns true if there is a clip and it should be antialiased |
protected boolean |
isOffscreenBufferNeeded()
Returns true of an offscreen buffer is needed to render this node, false otherwise. |
boolean |
isVisible()
Returns true if this node is visible, false otherwise. |
GraphicsNode |
nodeHitAt(java.awt.geom.Point2D p)
Returns the GraphicsNode containing point p if this node or one of its children is sensitive to mouse events at p. |
protected java.awt.geom.Rectangle2D |
normalizeRectangle(java.awt.geom.Rectangle2D bounds)
This method makes sure that neither the width nor height of the rectangle is zero. |
void |
paint(java.awt.Graphics2D g2d)
Paints this node. |
void |
setClip(ClipRable newClipper)
Sets the clipping filter of this node. |
void |
setComposite(java.awt.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. |
protected void |
setParent(CompositeGraphicsNode newParent)
Sets the parent node of this graphics node. |
void |
setPointerEventType(int pointerEventType)
Sets the type that describes how this graphics node reacts to events. |
void |
setRenderingHint(java.awt.RenderingHints.Key key,
java.lang.Object value)
Maps the specified key to the specified value in the rendering hints of this node. |
void |
setRenderingHints(java.util.Map hints)
Copies all of the mappings from the specified Map to the rendering hints of this node. |
void |
setRenderingHints(java.awt.RenderingHints newHints)
Sets the rendering hints of this node. |
protected void |
setRoot(RootGraphicsNode newRoot)
Sets the root node of this graphics node. |
void |
setTransform(java.awt.geom.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. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.apache.batik.gvt.GraphicsNode |
getGeometryBounds, getOutline, getPrimitiveBounds, primitivePaint |
| Field Detail |
protected javax.swing.event.EventListenerList listeners
protected java.awt.geom.AffineTransform transform
protected java.awt.geom.AffineTransform inverseTransform
protected java.awt.Composite composite
protected boolean isVisible
protected ClipRable clip
protected java.awt.RenderingHints hints
protected CompositeGraphicsNode parent
protected RootGraphicsNode root
protected Mask mask
protected Filter filter
protected int pointerEventType
protected java.lang.ref.WeakReference graphicsNodeRable
protected java.lang.ref.WeakReference enableBackgroundGraphicsNodeRable
protected java.lang.ref.WeakReference weakRef
protected GraphicsNodeChangeEvent changeStartedEvent
protected GraphicsNodeChangeEvent changeCompletedEvent
| Constructor Detail |
protected AbstractGraphicsNode()
| Method Detail |
public java.lang.ref.WeakReference getWeakReference()
getWeakReference in interface GraphicsNodepublic int getPointerEventType()
getPointerEventType in interface GraphicsNodepublic void setPointerEventType(int pointerEventType)
setPointerEventType in interface GraphicsNodepointerEventType - VISIBLE_PAINTED | VISIBLE_FILL | VISIBLE_STROKE |
VISIBLE | PAINTED | FILL | STROKE | ALL | NONEpublic void setTransform(java.awt.geom.AffineTransform newTransform)
setTransform in interface GraphicsNodenewTransform - the new transform of this nodepublic java.awt.geom.AffineTransform getTransform()
getTransform in interface GraphicsNodepublic java.awt.geom.AffineTransform getInverseTransform()
getInverseTransform in interface GraphicsNodepublic java.awt.geom.AffineTransform getGlobalTransform()
getGlobalTransform in interface GraphicsNodepublic void setComposite(java.awt.Composite newComposite)
setComposite in interface GraphicsNodecomposite - the composite of this nodepublic java.awt.Composite getComposite()
getComposite in interface GraphicsNodepublic void setVisible(boolean isVisible)
setVisible in interface GraphicsNodeisVisible - If true this node is visiblepublic boolean isVisible()
isVisible in interface GraphicsNodepublic void setClip(ClipRable newClipper)
GraphicsNodesetClip in interface GraphicsNodeorg.apache.batik.gvt.GraphicsNodenewClipper - the new clipping filter of this nodepublic ClipRable getClip()
getClip in interface GraphicsNode
public void setRenderingHint(java.awt.RenderingHints.Key key,
java.lang.Object value)
setRenderingHint in interface GraphicsNodekey - the key of the hint to be setvalue - the value indicating preferences for the specified
hint category.public void setRenderingHints(java.util.Map hints)
setRenderingHints in interface GraphicsNodehints - the rendering hints to be setpublic void setRenderingHints(java.awt.RenderingHints newHints)
setRenderingHints in interface GraphicsNodenewHints - the new rendering hints of this nodepublic java.awt.RenderingHints getRenderingHints()
getRenderingHints in interface GraphicsNodepublic void setMask(Mask newMask)
setMask in interface GraphicsNodenewMask - the new mask of this nodepublic Mask getMask()
getMask in interface GraphicsNodepublic void setFilter(Filter newFilter)
setFilter in interface GraphicsNodenewFilter - the new filter of this nodepublic Filter getFilter()
getFilter in interface GraphicsNodepublic Filter getGraphicsNodeRable(boolean createIfNeeded)
getGraphicsNodeRable in interface GraphicsNodepublic Filter getEnableBackgroundGraphicsNodeRable(boolean createIfNeeded)
getEnableBackgroundGraphicsNodeRable in interface GraphicsNodepublic void paint(java.awt.Graphics2D g2d)
paint in interface GraphicsNodeg2d - the Graphics2D to useprotected boolean isOffscreenBufferNeeded()
protected boolean isAntialiasedClip(java.awt.geom.AffineTransform usr2dev,
java.awt.RenderingHints hints,
java.awt.Shape clip)
public void fireGraphicsNodeChangeStarted(java.awt.geom.Rectangle2D from,
java.awt.geom.Rectangle2D to)
public void fireGraphicsNodeChangeStarted()
public void fireGraphicsNodeChangeStarted(GraphicsNodeChangeEvent changeStartedEvent)
public void fireGraphicsNodeChangeCompleted()
public CompositeGraphicsNode getParent()
getParent in interface GraphicsNodepublic RootGraphicsNode getRoot()
getRoot in interface GraphicsNodeprotected void setRoot(RootGraphicsNode newRoot)
newRoot - the new root node of this nodeprotected void setParent(CompositeGraphicsNode newParent)
newParent - the new parent node of this nodeprotected void invalidateGeometryCache()
public java.awt.geom.Rectangle2D getBounds()
getBounds in interface GraphicsNodepublic java.awt.geom.Rectangle2D getTransformedBounds(java.awt.geom.AffineTransform txf)
getTransformedBounds in interface GraphicsNodetxf - the affine transform with which this node's transform should
be concatenated. Should not be null.public java.awt.geom.Rectangle2D getTransformedPrimitiveBounds(java.awt.geom.AffineTransform txf)
getTransformedPrimitiveBounds in interface GraphicsNodetxf - the affine transform with which this node's transform should
be concatenated. Should not be null.public java.awt.geom.Rectangle2D getTransformedGeometryBounds(java.awt.geom.AffineTransform txf)
getTransformedGeometryBounds in interface GraphicsNodeorg.apache.batik.gvt.GraphicsNodetxf - the affine transform with which this node's transform should
be concatenated. Should not be null.public boolean contains(java.awt.geom.Point2D p)
contains in interface GraphicsNodep - the specified Point2D in the user spacepublic boolean intersects(java.awt.geom.Rectangle2D r)
intersects in interface GraphicsNoder - the specified Rectangle2D in the user node spacepublic GraphicsNode nodeHitAt(java.awt.geom.Point2D p)
nodeHitAt in interface GraphicsNodep - the specified Point2D in the user spaceprotected java.awt.geom.Rectangle2D normalizeRectangle(java.awt.geom.Rectangle2D bounds)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||