mxIShape
public class mxStencilShape extends mxBasicShape
Modifier and Type | Class | Description |
---|---|---|
protected class |
mxStencilShape.svgShape |
Modifier and Type | Field | Description |
---|---|---|
protected java.awt.geom.Rectangle2D |
boundingBox |
|
protected java.awt.geom.AffineTransform |
cachedTransform |
Transform cached to save instance created.
|
protected java.lang.String |
iconPath |
|
protected java.lang.String |
name |
|
protected org.w3c.dom.Node |
root |
Reference to the root node of the Dia shape description.
|
protected mxStencilShape.svgShape |
rootShape |
|
protected java.awt.geom.GeneralPath |
shapePath |
Constructor | Description |
---|---|
mxStencilShape() |
|
mxStencilShape(java.lang.String shapeXml) |
Constructs a new stencil for the given Dia shape description.
|
mxStencilShape(org.w3c.dom.Document document) |
Modifier and Type | Method | Description |
---|---|---|
mxStencilShape.svgShape |
createElement(org.w3c.dom.Node root) |
Forms an internal representation of the specified SVG element and returns
that representation
|
void |
createShape(org.w3c.dom.Node root,
mxStencilShape.svgShape shape) |
|
java.awt.geom.Rectangle2D |
getBoundingBox() |
|
java.lang.String |
getIconPath() |
|
java.lang.String |
getName() |
|
protected static java.util.Map<java.lang.String,java.lang.Object> |
getStylenames(java.lang.String style) |
Returns the stylenames in a style of the form stylename[;key=value] or an
empty array if the given style does not contain any stylenames.
|
void |
paintNode(mxGraphics2DCanvas canvas,
mxCellState state,
mxStencilShape.svgShape shape,
double widthRatio,
double heightRatio) |
|
void |
paintShape(mxGraphics2DCanvas canvas,
mxCellState state) |
|
void |
setBoundingBox(java.awt.geom.Rectangle2D boundingBox) |
|
void |
setIconPath(java.lang.String iconPath) |
|
void |
setName(java.lang.String name) |
|
protected void |
transformShape(java.awt.Shape shape,
double transX,
double transY,
double widthRatio,
double heightRatio) |
Scales the points composing this shape by the x and y ratios specified
|
configureGraphics, createShape, getFillColor, getGradientBounds, getStrokeColor, hasGradient, hasShadow
protected java.awt.geom.GeneralPath shapePath
protected org.w3c.dom.Node root
protected mxStencilShape.svgShape rootShape
protected java.awt.geom.Rectangle2D boundingBox
protected java.lang.String name
protected java.lang.String iconPath
protected java.awt.geom.AffineTransform cachedTransform
public mxStencilShape()
public mxStencilShape(java.lang.String shapeXml)
public mxStencilShape(org.w3c.dom.Document document)
public void paintShape(mxGraphics2DCanvas canvas, mxCellState state)
paintShape
in interface mxIShape
paintShape
in class mxBasicShape
public void paintNode(mxGraphics2DCanvas canvas, mxCellState state, mxStencilShape.svgShape shape, double widthRatio, double heightRatio)
protected void transformShape(java.awt.Shape shape, double transX, double transY, double widthRatio, double heightRatio)
shape
- the shape to scaletransX
- the x translationtransY
- the y translationwidthRatio
- the x co-ordinate scaleheightRatio
- the y co-ordinate scalepublic void createShape(org.w3c.dom.Node root, mxStencilShape.svgShape shape)
public mxStencilShape.svgShape createElement(org.w3c.dom.Node root)
root
- the SVG element to representprotected static java.util.Map<java.lang.String,java.lang.Object> getStylenames(java.lang.String style)
style
- String of the form stylename[;stylename][;key=value].public java.lang.String getName()
public void setName(java.lang.String name)
public java.lang.String getIconPath()
public void setIconPath(java.lang.String iconPath)
public java.awt.geom.Rectangle2D getBoundingBox()
public void setBoundingBox(java.awt.geom.Rectangle2D boundingBox)
Copyright (c) 2010-2017 Gaudenz Alder, JGraph Ltd. All rights reserved.