com.mxgraph.shape
Class mxStencilShape
- java.lang.Object
-
- com.mxgraph.shape.mxBasicShape
-
- com.mxgraph.shape.mxStencilShape
-
- All Implemented Interfaces:
- mxIShape
public class mxStencilShape extends mxBasicShape
Stencil shape drawing that takes an XML definition of the shape and renders it. See http://projects.gnome.org/dia/custom-shapes for specs. See http://dia-installer.de/shapes_de.html for shapes.
-
-
Constructor Summary
Constructors Constructor and Description mxStencilShape()mxStencilShape(org.w3c.dom.Document document)mxStencilShape(java.lang.String shapeXml)Constructs a new stencil for the given Dia shape description.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description com.mxgraph.shape.mxStencilShape.svgShapecreateElement(org.w3c.dom.Node root)Forms an internal representation of the specified SVG element and returns that representationvoidcreateShape(org.w3c.dom.Node root, com.mxgraph.shape.mxStencilShape.svgShape shape)java.awt.geom.Rectangle2DgetBoundingBox()java.lang.StringgetIconPath()java.lang.StringgetName()voidpaintNode(mxGraphics2DCanvas canvas, mxCellState state, com.mxgraph.shape.mxStencilShape.svgShape shape, double widthRatio, double heightRatio)voidpaintShape(mxGraphics2DCanvas canvas, mxCellState state)voidsetBoundingBox(java.awt.geom.Rectangle2D boundingBox)voidsetIconPath(java.lang.String iconPath)voidsetName(java.lang.String name)-
Methods inherited from class com.mxgraph.shape.mxBasicShape
createShape, getFillColor, getStrokeColor, hasGradient, hasShadow
-
-
-
-
Constructor Detail
-
mxStencilShape
public mxStencilShape()
-
mxStencilShape
public mxStencilShape(java.lang.String shapeXml)
Constructs a new stencil for the given Dia shape description.
-
mxStencilShape
public mxStencilShape(org.w3c.dom.Document document)
-
-
Method Detail
-
paintShape
public void paintShape(mxGraphics2DCanvas canvas, mxCellState state)
- Specified by:
paintShapein interfacemxIShape- Overrides:
paintShapein classmxBasicShape
-
paintNode
public void paintNode(mxGraphics2DCanvas canvas, mxCellState state, com.mxgraph.shape.mxStencilShape.svgShape shape, double widthRatio, double heightRatio)
-
createShape
public void createShape(org.w3c.dom.Node root, com.mxgraph.shape.mxStencilShape.svgShape shape)
-
createElement
public com.mxgraph.shape.mxStencilShape.svgShape createElement(org.w3c.dom.Node root)
Forms an internal representation of the specified SVG element and returns that representation- Parameters:
root- the SVG element to represent- Returns:
- the internal representation of the element, or null if an error occurs
-
getName
public java.lang.String getName()
-
setName
public void setName(java.lang.String name)
-
getIconPath
public java.lang.String getIconPath()
-
setIconPath
public void setIconPath(java.lang.String iconPath)
-
getBoundingBox
public java.awt.geom.Rectangle2D getBoundingBox()
-
setBoundingBox
public void setBoundingBox(java.awt.geom.Rectangle2D boundingBox)
-
-
DataMelt 3.0 © DataMelt by jWork.ORG