Package com.jsevy.jsvg
Class SVGEntity
- java.lang.Object
-
- com.jsevy.jxml.XMLNode
-
- com.jsevy.jxml.XMLElement
-
- com.jsevy.jsvg.SVGEntity
-
- All Implemented Interfaces:
java.lang.Cloneable
,org.w3c.dom.Element
,org.w3c.dom.Node
public abstract class SVGEntity extends XMLElement
A special case of DXFObjects used for graphical entities. In particular, maintains the affine transformation that can be associated with any graphical element.- Author:
- jsevy
-
-
Field Summary
-
Fields inherited from interface org.w3c.dom.Node
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_POSITION_CONTAINED_BY, DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITION_PRECEDING, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE
-
-
Constructor Summary
Constructors Constructor Description SVGEntity(com.jsevy.jsvg.SVGStyle style, java.awt.geom.AffineTransform transform)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.awt.geom.Rectangle2D
getBounds()
Returns the rectangle that bounds the shape, i.e., the smallest enclosing rectangle.java.awt.geom.AffineTransform
getTransform()
static void
setPrecisionDigits(int decimalDigits)
Set the number of digits when a quantity is truncated with a call to setPrecision()void
setTransform(java.awt.geom.AffineTransform newTransform)
-
Methods inherited from class com.jsevy.jxml.XMLElement
cloneNode, compareDocumentPosition, getAttribute, getAttributeNode, getAttributeNodeNS, getAttributeNS, getAttributes, getElementsByTagName, getElementsByTagNameNS, getNodeType, getSchemaTypeInfo, getTagName, getTextContent, hasAttribute, hasAttributeNS, hasAttributes, removeAttribute, removeAttributeNode, removeAttributeNS, setAttribute, setAttributeNode, setAttributeNodeNS, setAttributeNodes, setAttributeNS, setIdAttribute, setIdAttributeNode, setIdAttributeNS, setOwnerDocument
-
Methods inherited from class com.jsevy.jxml.XMLNode
appendChild, clone, equals, getBaseURI, getChildNodes, getDescendants, getFeature, getFirstChild, getLastChild, getLocalName, getNamespaceURI, getNextSibling, getNodeName, getNodeValue, getOwnerDocument, getParentNode, getPrefix, getPreviousSibling, getUserData, hasChildNodes, insertAfter, insertBefore, isDefaultNamespace, isEqualNode, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, normalize, prependChild, removeChild, replaceChild, setNamespaceURI, setNodeName, setNodeValue, setParentNode, setPrefix, setTextContent, setUserData
-
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.w3c.dom.Node
appendChild, getBaseURI, getChildNodes, getFeature, getFirstChild, getLastChild, getLocalName, getNamespaceURI, getNextSibling, getNodeName, getNodeValue, getOwnerDocument, getParentNode, getPrefix, getPreviousSibling, getUserData, hasChildNodes, insertBefore, isDefaultNamespace, isEqualNode, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, normalize, removeChild, replaceChild, setNodeValue, setPrefix, setTextContent, setUserData
-
-
-
-
Method Detail
-
getTransform
public java.awt.geom.AffineTransform getTransform()
-
setTransform
public void setTransform(java.awt.geom.AffineTransform newTransform)
-
getBounds
public java.awt.geom.Rectangle2D getBounds()
Returns the rectangle that bounds the shape, i.e., the smallest enclosing rectangle. Note that this takes into account any transformation associated with the shape (rotation, scaling, skewing, etc.), giving the bounding rectangle for the transformed shape.- Returns:
- Rectangle bounding the shape
-
setPrecisionDigits
public static void setPrecisionDigits(int decimalDigits)
Set the number of digits when a quantity is truncated with a call to setPrecision()- Parameters:
decimalDigits
- Number of digits following the decimal point, between 0 and 16
-
-