Package com.storedobject.svg
Class Canvas
java.lang.Object
com.storedobject.svg.Svg
com.storedobject.svg.Canvas
-
Nested Class Summary
Nested classes/interfaces inherited from class com.storedobject.svg.Svg
Svg.Anchor, Svg.Margin, Svg.Mover, Svg.Scale, Svg.ScaleTo -
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionAdd an SVG.autoSize()Set the auto-size flag to true.autoSize(boolean autoSize) Set the auto-size flag.voidbuild()Build the SVG.Add a clip element.booleanisBuilt()Check if the chart is built.Remove an SVG.voidremoveClip(Element clip) Remove a clip element.size(double width, double height) Set the size.Methods inherited from class com.storedobject.svg.Svg
add, add, add, escapeXml, flipHorizontally, flipVertically, getFilledSvg, getHeight, getScaledSvg, getSvg, getWidth, getX, getY, margin, margin, scale, scale, scaleTo, scaleToHeight, scaleToWidth, toString
-
Constructor Details
-
Canvas
public Canvas()Constructor. -
Canvas
public Canvas(double width, double height) Constructor.- Parameters:
width- Width.height- Height.
-
-
Method Details
-
clip
-
removeClip
-
size
Set the size.- Parameters:
width- Width.height- Height.- Returns:
- Self.
-
autoSize
Set the auto-size flag.- Parameters:
autoSize- Auto-size flag.- Returns:
- Self.
-
autoSize
-
add
Add an SVG.- Parameters:
svg- SVG to add.- Returns:
- The
MovableSvgthat wraps the added SVG.
-
remove
Remove an SVG.- Parameters:
svg- SVG to remove.- Returns:
- The removed SVG (could be a
MovableSvg).
-
build
-
isBuilt
-