org.apache.batik.bridge
public class SVGImageElementBridge extends AbstractGraphicsNodeBridge
Nested Class Summary | |
---|---|
protected static class | SVGImageElementBridge.ForwardEventListener
A simple DOM listener to forward events from the SVG image document to
the original document. |
static class | SVGImageElementBridge.ProtectedStream
Next see if it's an XML document. |
Field Summary | |
---|---|
protected boolean | hitCheckChildren |
protected SVGDocument | imgDocument |
protected EventListener | listener |
protected BridgeContext | subCtx |
Constructor Summary | |
---|---|
SVGImageElementBridge()
Constructs a new bridge for the <image> element. |
Method Summary | |
---|---|
protected GraphicsNode | buildImageGraphicsNode(BridgeContext ctx, Element e)
Create a Graphics node according to the
resource pointed by the href : RasterImageNode
for bitmaps, CompositeGraphicsNode for svg files.
|
GraphicsNode | createGraphicsNode(BridgeContext ctx, Element e)
Creates a graphics node using the specified BridgeContext and for the
specified element.
|
protected GraphicsNode | createImageGraphicsNode(BridgeContext ctx, Element e, ParsedURL purl) |
protected GraphicsNode | createRasterImageNode(BridgeContext ctx, Element e, Filter img, ParsedURL purl)
Returns a GraphicsNode that represents an raster image in JPEG or PNG
format.
|
protected GraphicsNode | createSVGImageNode(BridgeContext ctx, Element e, SVGDocument imgDocument)
Returns a GraphicsNode that represents a svg document as an image.
|
void | dispose() |
protected static ICCColorSpaceExt | extractColorSpace(Element element, BridgeContext ctx)
Analyzes the color-profile property and builds an ICCColorSpaceExt
object from it.
|
protected static Rectangle2D | getImageBounds(BridgeContext ctx, Element element)
Returns the bounds of the specified image element.
|
Bridge | getInstance()
Returns a new instance of this bridge. |
String | getLocalName()
Returns 'image'. |
void | handleAnimatedAttributeChanged(AnimatedLiveAttributeValue alav)
Invoked when the animated value of an animatable attribute has changed. |
protected void | handleCSSPropertyChanged(int property)
Invoked for each CSS property that has changed. |
protected void | initializeDynamicSupport(BridgeContext ctx, Element e, GraphicsNode node)
This method is invoked during the build phase if the document
is dynamic. |
protected static void | initializeViewport(BridgeContext ctx, Element e, GraphicsNode node, float[] vb, Rectangle2D bounds)
Initializes according to the specified element, the specified graphics
node with the specified bounds. |
protected GraphicsNode | instantiateGraphicsNode()
Creates an ImageNode. |
boolean | isComposite()
Returns false as image is not a container. |
protected SVGImageElementBridge.ProtectedStream | openStream(Element e, ParsedURL purl) |
protected void | rebuildImageNode() |
protected void | updateImageBounds() |
Parameters: ctx : the bridge context to use e the element that describes the graphics node to build
Returns: the graphic node that represent the resource pointed by the reference
Parameters: ctx the bridge context to use e the element that describes the graphics node to build
Returns: a graphics node that represents the specified element
Parameters: ctx the bridge context e the image element img the image to use in creating the graphics node
Parameters: ctx the bridge context e the image element imgDocument the SVG document that represents the image
Parameters: element the element with the color-profile property ctx the bridge context
Parameters: ctx the bridge context element the image element
Parameters: ctx the bridge context e the image element that defines the properties node the graphics node vb the implicit viewBox definition bounds the bounds of the image element