Defspublic class Defs extends StructureNode Defs are used as placeholders where proxied ModelNode
can be stored for reference by ElementNodeProxy instances.
Note that according to the SVG 1.1 DTD, <defs> should be
StructureNode.
However, we should not apply GraphicsNode and
TextNode properties on <defs> as it
is useless: <defs> content is never rendered directly,
so properties set on defs are _never_ inherited by <defs>
children. Therefore, having defs support graphics and text properties is
an oversight in the SVG Tiny specification.
Note: There is a JDTS test failure when defs extends ElementNode instead of
StructureNode. This is caused by the fact that in that case it breaks
an inheritance chain from a child to defs's parent. |
Constructors Summary |
---|
public Defs(DocumentNode ownerDocument)Constructor.
super(ownerDocument);
// do not render this node
canRenderState |= CAN_RENDER_RENDERABLE_BIT;
|
Methods Summary |
---|
public java.lang.String | getLocalName()
return SVGConstants.SVG_DEFS_TAG;
| public ElementNode | newInstance(DocumentNode doc)Used by DocumentNode to create a new instance from
a prototype Defs .
return new Defs(doc);
|
|