java.lang.Object
org.apache.batik.gvt.AbstractGraphicsNode
org.apache.batik.gvt.CompositeGraphicsNode
org.apache.batik.gvt.ImageNode
- All Implemented Interfaces:
- java.util.Collection, GraphicsNode, java.lang.Iterable, java.util.List
- public class ImageNode
- extends CompositeGraphicsNode
A graphics node that represents an image described as a graphics node.
- Version:
- $Id: ImageNode.java,v 1.19 2005/02/12 01:48:24 deweese Exp $
| Fields inherited from class org.apache.batik.gvt.AbstractGraphicsNode |
changeCompletedEvent, changeStartedEvent, clip, composite, enableBackgroundGraphicsNodeRable, EPSILON, filter, graphicsNodeRable, hints, inverseTransform, isVisible, listeners, mask, parent, pointerEventType, root, transform, weakRef |
|
Constructor Summary |
ImageNode()
Constructs a new empty ImageNode. |
| Methods inherited from class org.apache.batik.gvt.CompositeGraphicsNode |
add, add, addAll, addAll, clear, contains, containsAll, ensureCapacity, get, getBackgroundEnable, getChildren, getGeometryBounds, getOutline, getSensitiveBounds, getTransformedBBox, getTransformedGeometryBounds, getTransformedPrimitiveBounds, getTransformedSensitiveBounds, indexOf, invalidateGeometryCache, isEmpty, iterator, lastIndexOf, listIterator, listIterator, primitivePaint, remove, remove, removeAll, retainAll, set, setBackgroundEnable, setRoot, size, subList, toArray, toArray |
| Methods inherited from class org.apache.batik.gvt.AbstractGraphicsNode |
fireGraphicsNodeChangeCompleted, fireGraphicsNodeChangeStarted, fireGraphicsNodeChangeStarted, fireGraphicsNodeChangeStarted, getBounds, getClip, getComposite, getEnableBackgroundGraphicsNodeRable, getFilter, getGlobalTransform, getGraphicsNodeRable, getInverseTransform, getMask, getParent, getPointerEventType, getRenderingHints, getRoot, getTransform, getTransformedBounds, getWeakReference, intersects, isAntialiasedClip, isOffscreenBufferNeeded, isVisible, normalizeRectangle, setClip, setComposite, setFilter, setMask, setParent, setPointerEventType, setRenderingHint, setRenderingHints, setRenderingHints, setTransform |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
hitCheckChildren
protected boolean hitCheckChildren
ImageNode
public ImageNode()
- Constructs a new empty ImageNode.
setVisible
public void setVisible(boolean isVisible)
- Description copied from class:
CompositeGraphicsNode
- Sets if this node is visible or not depending on the specified value.
Don't fire a graphicsNodeChange event because this doesn't really
effect us (it effects our children through CSS inheritence).
- Specified by:
setVisible in interface GraphicsNode- Overrides:
setVisible in class CompositeGraphicsNode
getPrimitiveBounds
public java.awt.geom.Rectangle2D getPrimitiveBounds()
- Description copied from class:
CompositeGraphicsNode
- Returns the bounds of the area covered by this node's primitive paint.
- Specified by:
getPrimitiveBounds in interface GraphicsNode- Overrides:
getPrimitiveBounds in class CompositeGraphicsNode
setHitCheckChildren
public void setHitCheckChildren(boolean hitCheckChildren)
- If hitCheckChildren is true then nodeHitAt will return
child nodes of this image. Otherwise it will only
return this node (if the point is in the image).
getHitCheckChildren
public boolean getHitCheckChildren()
paint
public void paint(java.awt.Graphics2D g2d)
- Paints this node.
- Specified by:
paint in interface GraphicsNode- Overrides:
paint in class AbstractGraphicsNode
contains
public boolean contains(java.awt.geom.Point2D p)
- Returns true if the specified Point2D is inside the boundary of this
node, false otherwise.
- Specified by:
contains in interface GraphicsNode- Overrides:
contains in class CompositeGraphicsNode
nodeHitAt
public 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.
- Specified by:
nodeHitAt in interface GraphicsNode- Overrides:
nodeHitAt in class CompositeGraphicsNode
setImage
public void setImage(GraphicsNode newImage)
- Sets the graphics node that represents the image.
getImage
public GraphicsNode getImage()
- Returns the graphics node that represents the image.