com.kitfox.svg
Class ShapeElement
java.lang.Object
com.kitfox.svg.SVGElement
com.kitfox.svg.TransformableElement
com.kitfox.svg.RenderableElement
com.kitfox.svg.ShapeElement
- All Implemented Interfaces:
- Serializable
- Direct Known Subclasses:
- Circle, Ellipse, Group, Line, MissingGlyph, Path, Polygon, Polyline, Rect, Text, Tspan, Use
public abstract class ShapeElement
- extends RenderableElement
Parent of shape objects
- Author:
- Mark McKay, Mark McKay
- See Also:
- Serialized Form
|
Field Summary |
protected float |
strokeWidthScalar
This is necessary to get text elements to render the stroke the correct
width. |
| Fields inherited from class com.kitfox.svg.SVGElement |
children, cssClass, diagram, id, ignorePresAttrib, inlineStyles, parent, presAttribs, serialVersionUID, SVG_NS, trackManager, xmlBase |
|
Constructor Summary |
ShapeElement()
Creates a new instance of ShapeElement |
| Methods inherited from class com.kitfox.svg.SVGElement |
addAttribute, buildPath, getChild, getChild, getChildren, getId, getInlineAttributes, getNumChildren, getParent, getParentContext, getPath, getPres, getPresAbsolute, getPresentationAttributes, getStyle, getStyle, getStyleAbsolute, getXMLBase, hasAttribute, indexOfChild, loaderAddChild, loaderAddText, loaderEndElement, loaderStartElement, nextFloat, parsePathList, parseSingleTransform, parseTransform, popParentContext, pushParentContext, removeAttribute, removeChild, setAttribute, setDiagram, swapChildren |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
strokeWidthScalar
protected float strokeWidthScalar
- This is necessary to get text elements to render the stroke the correct
width. It is an alternative to producing new font glyph sets at different
sizes.
ShapeElement
public ShapeElement()
- Creates a new instance of ShapeElement
render
public abstract void render(Graphics2D g)
throws SVGException
- Specified by:
render in class RenderableElement
- Throws:
SVGException
renderShape
protected void renderShape(Graphics2D g,
Shape shape)
throws SVGException
- Throws:
SVGException
getShape
public abstract Shape getShape()
includeStrokeInBounds
protected Rectangle2D includeStrokeInBounds(Rectangle2D rect)
throws SVGException
- Throws:
SVGException
Copyright © 2011-2012 Barchart, Inc.. All Rights Reserved.