maxGraph/docs/js-api/files/shape/mxShape-js.html

181 lines
119 KiB
HTML
Raw Normal View History

2012-05-21 20:32:26 +00:00
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
<html><head><title>mxShape</title><link rel="stylesheet" type="text/css" href="../../styles/main.css"><script language=JavaScript src="../../javascript/main.js"></script><script language=JavaScript src="../../javascript/prettify.js"></script><script language=JavaScript src="../../javascript/searchdata.js"></script></head><body class="ContentPage" onLoad="NDOnLoad();prettyPrint();"><script language=JavaScript><!--
if (browserType) {document.write("<div class=" + browserType + ">");if (browserVer) {document.write("<div class=" + browserVer + ">"); }}// --></script>
<!-- Generated by Natural Docs, version 1.5 -->
<!-- http://www.naturaldocs.org -->
<!-- saved from url=(0026)http://www.naturaldocs.org -->
2012-07-16 15:36:48 +00:00
<div id=Content><div class="CClass"><div class=CTopic id=MainTopic><h1 class=CTitle><a name="mxShape"></a>mxShape</h1><div class=CBody><p>Base class for all shapes.&nbsp; A shape in mxGraph is a separate implementation for SVG, VML and HTML.&nbsp; Which implementation to use is controlled by the <a href="#mxShape.dialect" class=LVariable id=link92 onMouseOver="ShowTip(event, 'tt4', 'link92')" onMouseOut="HideTip('tt4')">dialect</a> property which is assigned from within the <a href="../view/mxCellRenderer-js.html#mxCellRenderer" class=LClass id=link93 onMouseOver="ShowTip(event, 'tt73', 'link93')" onMouseOut="HideTip('tt73')">mxCellRenderer</a> when the shape is created.&nbsp; The dialect must be assigned for a shape, and it does normally depend on the browser and the confiuration of the graph (see <a href="../view/mxGraph-js.html#mxGraph" class=LClass id=link94 onMouseOver="ShowTip(event, 'tt74', 'link94')" onMouseOut="HideTip('tt74')">mxGraph</a> rendering hint).</p><p>For each supported shape in SVG and VML, a corresponding shape exists in mxGraph, namely for text, image, rectangle, rhombus, ellipse and polyline.&nbsp; The other shapes are a combination of these shapes (eg. label and swimlane) or they consist of one or more (filled) path objects (eg. actor and cylinder).&nbsp; The HTML implementation is optional but may be required for a HTML-only view of the graph.</p><h4 class=CHeading>Custom Shapes</h4><p>To extend from this class, the basic code looks as follows.&nbsp; In the special case where the custom shape consists only of one filled region or one filled region and an additional stroke the <a href="mxActor-js.html#mxActor" class=LClass id=link95 onMouseOver="ShowTip(event, 'tt75', 'link95')" onMouseOut="HideTip('tt75')">mxActor</a> and <a href="mxCylinder-js.html#mxCylinder" class=LClass id=link96 onMouseOver="ShowTip(event, 'tt76', 'link96')" onMouseOut="HideTip('tt76')">mxCylinder</a> should be subclassed, respectively.&nbsp; These implement <a href="#mxShape.redrawPath" class=LFunction id=link97 onMouseOver="ShowTip(event, 'tt72', 'link97')" onMouseOut="HideTip('tt72')">redrawPath</a> in order to create the path expression for VML and SVG via a unified API (see <a href="../util/mxPath-js.html#mxPath" class=LClass id=link98 onMouseOver="ShowTip(event, 'tt71', 'link98')" onMouseOut="HideTip('tt71')">mxPath</a>).&nbsp; <a href="mxCylinder-js.html#mxCylinder.redrawPath" class=LFunction id=link99 onMouseOver="ShowTip(event, 'tt77', 'link99')" onMouseOut="HideTip('tt77')">mxCylinder.redrawPath</a> has an additional boolean argument to draw the foreground and background separately.</p><blockquote><pre class="prettyprint">function CustomShape() { }
2012-05-21 20:32:26 +00:00
CustomShape.prototype = new mxShape();
CustomShape.prototype.constructor = CustomShape;</pre></blockquote><p>To register a custom shape in an existing graph instance, one must register the shape under a new name in the graph&rsquo;s cell renderer as follows:</p><blockquote><pre class="prettyprint">graph.cellRenderer.registerShape('customShape', CustomShape);</pre></blockquote><p>The second argument is the name of the constructor.</p><p>In order to use the shape you can refer to the given name above in a stylesheet.&nbsp; For example, to change the shape for the default vertex style, the following code is used:</p><blockquote><pre class="prettyprint">var style = graph.getStylesheet().getDefaultVertexStyle();
2012-07-16 15:36:48 +00:00
style[mxConstants.STYLE_SHAPE] = 'customShape';</pre></blockquote><!--START_ND_SUMMARY--><div class=Summary><div class=STitle>Summary</div><div class=SBorder><table border=0 cellspacing=0 cellpadding=0 class=STable><tr class="SMain"><td class=SEntry><a href="#mxShape" >mxShape</a></td><td class=SDescription>Base class for all shapes. </td></tr><tr class="SGroup SIndent1"><td class=SEntry><a href="#mxShape.Functions" >Functions</a></td><td class=SDescription></td></tr><tr class="SFunction SIndent2 SMarked"><td class=SEntry><a href="#mxShape.mxShape" id=link1 onMouseOver="ShowTip(event, 'tt1', 'link1')" onMouseOut="HideTip('tt1')">mxShape</a></td><td class=SDescription>Constructs a new shape.</td></tr><tr class="SGroup SIndent1"><td class=SEntry><a href="#mxShape.Variables" >Variables</a></td><td class=SDescription></td></tr><tr class="SVariable SIndent2 SMarked"><td class=SEntry><a href="#mxShape.SVG_STROKE_TOLERANCE" id=link2 onMouseOver="ShowTip(event, 'tt2', 'link2')" onMouseOut="HideTip('tt2')">SVG_STROKE_TOLERANCE</a></td><td class=SDescription>Event-tolerance for SVG strokes (in px). </td></tr><tr class="SVariable SIndent2"><td class=SEntry><a href="#mxShape.scale" id=link3 onMouseOver="ShowTip(event, 'tt3', 'link3')" onMouseOut="HideTip('tt3')">scale</a></td><td class=SDescription>Holds the scale in which the shape is being painted.</td></tr><tr class="SVariable SIndent2 SMarked"><td class=SEntry><a href="#mxShape.dialect" id=link4 onMouseOver="ShowTip(event, 'tt4', 'link4')" onMouseOut="HideTip('tt4')">dialect</a></td><td class=SDescription>Holds the dialect in which the shape is to be painted. </td></tr><tr class="SVariable SIndent2"><td class=SEntry><a href="#mxShape.crisp" id=link5 onMouseOver="ShowTip(event, 'tt5', 'link5')" onMouseOut="HideTip('tt5')">crisp</a></td><td class=SDescription>Special attribute for SVG rendering to set the shape-rendering attribute to crispEdges in the output. </td></tr><tr class="SVariable SIndent2 SMarked"><td class=SEntry><a href="#mxShape.roundedCrispSvg" id=link6 onMouseOver="ShowTip(event, 'tt6', 'link6')" onMouseOut="HideTip('tt6')">roundedCrispSvg</a></td><td class=SDescription>Specifies if crisp rendering should be enabled for rounded shapes. </td></tr><tr class="SVariable SIndent2"><td class=SEntry><a href="#mxShape.mixedModeHtml" id=link7 onMouseOver="ShowTip(event, 'tt7', 'link7')" onMouseOut="HideTip('tt7')">mixedModeHtml</a></td><td class=SDescription>Specifies if <a href="#mxShape.createHtml" class=LFunction id=link8 onMouseOver="ShowTip(event, 'tt8', 'link8')" onMouseOut="HideTip('tt8')">createHtml</a> should be used in mixed Html mode. </td></tr><tr class="SVariable SIndent2 SMarked"><td class=SEntry><a href="#mxShape.preferModeHtml" id=link9 onMouseOver="ShowTip(event, 'tt9', 'link9')" onMouseOut="HideTip('tt9')">preferModeHtml</a></td><td class=SDescription>Specifies if <a href="#mxShape.createHtml" class=LFunction id=link10 onMouseOver="ShowTip(event, 'tt8', 'link10')" onMouseOut="HideTip('tt8')">createHtml</a> should be used in prefer Html mode. </td></tr><tr class="SVariable SIndent2"><td class=SEntry><a href="#mxShape.bounds" id=link11 onMouseOver="ShowTip(event, 'tt10', 'link11')" onMouseOut="HideTip('tt10')">bounds</a></td><td class=SDescription>Holds the <a href="../util/mxRectangle-js.html#mxRectangle" class=LClass id=link12 onMouseOver="ShowTip(event, 'tt11', 'link12')" onMouseOut="HideTip('tt11')">mxRectangle</a> that specifies the bounds of this shape.</td></tr><tr class="SVariable SIndent2 SMarked"><td class=SEntry><a href="#mxShape.points" id=link13 onMouseOver="ShowTip(event, 'tt12', 'link13')" onMouseOut="HideTip('tt12')">points</a></td><td class=SDescription>Holds the array of <a href="../util/mxPoint-js.html#mxPoint" class=LClass id=link14 onMouseOver="ShowTip(event, 'tt13', 'link14')" onMouseOut="HideTip('tt13')">mxPoints</a> that specify the points of this shape.</td></tr><tr class="SVariable SIndent2"><td class=SEntry><a href="#mxShape.node" id=link15 onMouseOver="ShowTip(event, 'tt14', 'link15')" onMouseOut="HideTip('tt14')">node</a></td><td
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxShape.Functions"></a>Functions</h3></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.mxShape"></a>mxShape</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>function mxShape()</td></tr></table></blockquote><p>Constructs a new shape.</p></div></div></div>
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxShape.Variables"></a>Variables</h3></div></div>
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.SVG_STROKE_TOLERANCE"></a>SVG_STROKE_TOLERANCE</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.SVG_STROKE_TOLERANCE</td></tr></table></blockquote><p>Event-tolerance for SVG strokes (in px).&nbsp; Default is 8.</p></div></div></div>
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.scale"></a>scale</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.scale</td></tr></table></blockquote><p>Holds the scale in which the shape is being painted.</p></div></div></div>
2012-07-16 15:36:48 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.dialect"></a>dialect</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.dialect</td></tr></table></blockquote><p>Holds the dialect in which the shape is to be painted.&nbsp; This can be one of the DIALECT constants in <a href="../util/mxConstants-js.html#mxConstants" class=LClass id=link100 onMouseOver="ShowTip(event, 'tt78', 'link100')" onMouseOut="HideTip('tt78')">mxConstants</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.crisp"></a>crisp</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.crisp</td></tr></table></blockquote><p>Special attribute for SVG rendering to set the shape-rendering attribute to crispEdges in the output.&nbsp; This is ignored in IE.&nbsp; Default is false.&nbsp; To disable antialias in IE, the explorer.css file can be changed as follows:</p><p>[code] v\:* { behavior: url(#default#VML); antialias: false; } [/code]</p></div></div></div>
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.roundedCrispSvg"></a>roundedCrispSvg</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.roundedCrispSvg</td></tr></table></blockquote><p>Specifies if crisp rendering should be enabled for rounded shapes.&nbsp; Default is true.</p></div></div></div>
2012-07-16 15:36:48 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.mixedModeHtml"></a>mixedModeHtml</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.mixedModeHtml</td></tr></table></blockquote><p>Specifies if <a href="#mxShape.createHtml" class=LFunction id=link101 onMouseOver="ShowTip(event, 'tt8', 'link101')" onMouseOut="HideTip('tt8')">createHtml</a> should be used in mixed Html mode.&nbsp; Default is true.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2012-07-16 15:36:48 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.preferModeHtml"></a>preferModeHtml</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.preferModeHtml</td></tr></table></blockquote><p>Specifies if <a href="#mxShape.createHtml" class=LFunction id=link102 onMouseOver="ShowTip(event, 'tt8', 'link102')" onMouseOut="HideTip('tt8')">createHtml</a> should be used in prefer Html mode.&nbsp; Default is true.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2012-07-16 15:36:48 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.bounds"></a>bounds</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.bounds</td></tr></table></blockquote><p>Holds the <a href="../util/mxRectangle-js.html#mxRectangle" class=LClass id=link103 onMouseOver="ShowTip(event, 'tt11', 'link103')" onMouseOut="HideTip('tt11')">mxRectangle</a> that specifies the bounds of this shape.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2012-07-16 15:36:48 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.points"></a>points</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.points</td></tr></table></blockquote><p>Holds the array of <a href="../util/mxPoint-js.html#mxPoint" class=LClass id=link104 onMouseOver="ShowTip(event, 'tt13', 'link104')" onMouseOut="HideTip('tt13')">mxPoints</a> that specify the points of this shape.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.node"></a>node</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.node</td></tr></table></blockquote><p>Holds the outermost DOM node that represents this shape.</p></div></div></div>
2012-07-16 15:36:48 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.label"></a>label</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.label</td></tr></table></blockquote><p>Reference to the DOM node that should contain the label.&nbsp; This is null if the label should be placed inside <a href="#mxShape.node" class=LVariable id=link105 onMouseOver="ShowTip(event, 'tt14', 'link105')" onMouseOut="HideTip('tt14')">node</a> or <a href="#mxShape.innerNode" class=LVariable id=link106 onMouseOver="ShowTip(event, 'tt16', 'link106')" onMouseOut="HideTip('tt16')">innerNode</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2012-07-16 15:36:48 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.innerNode"></a>innerNode</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.innerNode</td></tr></table></blockquote><p>Holds the DOM node that graphically represents this shape.&nbsp; This may be null if the outermost DOM <a href="#mxShape.node" class=LVariable id=link107 onMouseOver="ShowTip(event, 'tt14', 'link107')" onMouseOut="HideTip('tt14')">node</a> represents this shape.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.style"></a>style</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.style</td></tr></table></blockquote><p>Holds the style of the cell state that corresponds to this shape.&nbsp; This may be null if the shape is used directly, without a cell state.</p></div></div></div>
2012-07-16 15:36:48 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.startOffset"></a>startOffset</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.startOffset</td></tr></table></blockquote><p>Specifies the offset in pixels from the first point in <a href="#mxShape.points" class=LVariable id=link108 onMouseOver="ShowTip(event, 'tt12', 'link108')" onMouseOut="HideTip('tt12')">points</a> and the actual start of the shape.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2012-07-16 15:36:48 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.endOffset"></a>endOffset</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.endOffset</td></tr></table></blockquote><p>Specifies the offset in pixels from the last point in <a href="#mxShape.points" class=LVariable id=link109 onMouseOver="ShowTip(event, 'tt12', 'link109')" onMouseOut="HideTip('tt12')">points</a> and the actual start of the shape.</p></div></div></div>
2012-05-30 16:26:17 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.boundingBox"></a>boundingBox</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.boundingBox</td></tr></table></blockquote><p>Contains the bounding box of the shape, that is, the smallest rectangle that includes all pixels of the shape.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.vmlNodes"></a>vmlNodes</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.vmlNodes</td></tr></table></blockquote><p>Array if VML node names to fix in IE8 standards mode.</p></div></div></div>
2012-05-30 16:26:17 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.vmlScale"></a>vmlScale</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.vmlScale</td></tr></table></blockquote><p>Internal scaling for VML using coordsize for better precision.</p></div></div></div>
2012-07-16 15:36:48 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxShape.strokewidth"></a>strokewidth</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.strokewidth</td></tr></table></blockquote><p>Holds the current strokewidth.&nbsp; Default is 1.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxShape.Functions"></a>Functions</h3></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.setCursor"></a>setCursor</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.setCursor = function(</td><td class=PParameter nowrap>cursor</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the cursor on the given shape.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cursor</td><td class=CDLDescription>The cursor to be used.</td></tr></table></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.getCursor"></a>getCursor</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.getCursor = function()</td></tr></table></blockquote><p>Returns the current cursor.</p></div></div></div>
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.init"></a>init</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.init = function(</td><td class=PParameter nowrap>container</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Initializes the shape by creaing the DOM node using <a href="#mxShape.create" class=LFunction id=link110 onMouseOver="ShowTip(event, 'tt27', 'link110')" onMouseOut="HideTip('tt27')">create</a> and adding it into the given container.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>container</td><td class=CDLDescription>DOM node that will contain the shape.</td></tr></table></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.reparseVml"></a>reparseVml</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.reparseVml = function()</td></tr></table></blockquote><p>Forces a parsing of the outerHTML of this node and restores all references specified in <a href="#mxShape.vmlNodes" class=LVariable id=link111 onMouseOver="ShowTip(event, 'tt21', 'link111')" onMouseOut="HideTip('tt21')">vmlNodes</a>.&nbsp; This is a workaround for the VML rendering bug in IE8 standards mode.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.insertGradient"></a>insertGradient</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.insertGradient = function(</td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inserts the given gradient node.</p></div></div></div>
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.isMixedModeHtml"></a>isMixedModeHtml</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.isMixedModeHtml = function()</td></tr></table></blockquote><p>Used to determine if a shape can be rendered using <a href="#mxShape.createHtml" class=LFunction id=link112 onMouseOver="ShowTip(event, 'tt8', 'link112')" onMouseOut="HideTip('tt8')">createHtml</a> in mixed mode Html without compromising the display accuracy.&nbsp; The default implementation will check if the shape is not rounded or rotated and has no gradient, and will use a DIV if that is the case.&nbsp; It will also check if <a href="#mxShape.mixedModeHtml" class=LVariable id=link113 onMouseOver="ShowTip(event, 'tt7', 'link113')" onMouseOut="HideTip('tt7')">mxShape.mixedModeHtml</a> is true, which is the default settings.&nbsp; Subclassers can either override <a href="#mxShape.mixedModeHtml" class=LVariable id=link114 onMouseOver="ShowTip(event, 'tt7', 'link114')" onMouseOut="HideTip('tt7')">mixedModeHtml</a> or this function if the result depends on dynamic values.&nbsp; The graph&rsquo;s dialect is available via <a href="#mxShape.dialect" class=LVariable id=link115 onMouseOver="ShowTip(event, 'tt4', 'link115')" onMouseOut="HideTip('tt4')">dialect</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.create"></a>create</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.create = function(</td><td class=PParameter nowrap>container</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Creates and returns the DOM node(s) for the shape in the given container.&nbsp; This implementation invokes &lt;createSvg&gt;, <a href="#mxShape.createHtml" class=LFunction id=link116 onMouseOver="ShowTip(event, 'tt8', 'link116')" onMouseOut="HideTip('tt8')">createHtml</a> or &lt;createVml&gt; depending on the <a href="#mxShape.dialect" class=LVariable id=link117 onMouseOver="ShowTip(event, 'tt4', 'link117')" onMouseOut="HideTip('tt4')">dialect</a> and style settings.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>container</td><td class=CDLDescription>DOM node that will contain the shape.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.createHtml"></a>createHtml</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.createHtml = function()</td></tr></table></blockquote><p>Creates and returns the HTML DOM node(s) to represent this shape.&nbsp; This implementation falls back to &lt;createVml&gt; so that the HTML creation is optional.</p></div></div></div>
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.destroy"></a>destroy</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.destroy = function()</td></tr></table></blockquote><p>Destroys the shape by removing it from the DOM and releasing the DOM node associated with the shape using <a href="../util/mxEvent-js.html#mxEvent.release" class=LFunction id=link118 onMouseOver="ShowTip(event, 'tt32', 'link118')" onMouseOut="HideTip('tt32')">mxEvent.release</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.apply"></a>apply</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.apply = function(</td><td class=PParameter nowrap>state</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Applies the style of the given <a href="../view/mxCellState-js.html#mxCellState" class=LClass id=link119 onMouseOver="ShowTip(event, 'tt34', 'link119')" onMouseOut="HideTip('tt34')">mxCellState</a> to the shape.&nbsp; This implementation assigns the following styles to local fields:</p><ul><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_FILLCOLOR" class=LVariable id=link120 onMouseOver="ShowTip(event, 'tt79', 'link120')" onMouseOut="HideTip('tt79')">mxConstants.STYLE_FILLCOLOR</a> =&gt; fill</li><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_GRADIENTCOLOR" class=LVariable id=link121 onMouseOver="ShowTip(event, 'tt80', 'link121')" onMouseOut="HideTip('tt80')">mxConstants.STYLE_GRADIENTCOLOR</a> =&gt; gradient</li><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_GRADIENT_DIRECTION" class=LVariable id=link122 onMouseOver="ShowTip(event, 'tt81', 'link122')" onMouseOut="HideTip('tt81')">mxConstants.STYLE_GRADIENT_DIRECTION</a> =&gt; gradientDirection</li><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_OPACITY" class=LVariable id=link123 onMouseOver="ShowTip(event, 'tt82', 'link123')" onMouseOut="HideTip('tt82')">mxConstants.STYLE_OPACITY</a> =&gt; opacity</li><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_STROKECOLOR" class=LVariable id=link124 onMouseOver="ShowTip(event, 'tt83', 'link124')" onMouseOut="HideTip('tt83')">mxConstants.STYLE_STROKECOLOR</a> =&gt; stroke</li><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_STROKEWIDTH" class=LVariable id=link125 onMouseOver="ShowTip(event, 'tt84', 'link125')" onMouseOut="HideTip('tt84')">mxConstants.STYLE_STROKEWIDTH</a> =&gt; strokewidth</li><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_SHADOW" class=LVariable id=link126 onMouseOver="ShowTip(event, 'tt85', 'link126')" onMouseOut="HideTip('tt85')">mxConstants.STYLE_SHADOW</a> =&gt; isShadow</li><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_DASHED" class=LVariable id=link127 onMouseOver="ShowTip(event, 'tt86', 'link127')" onMouseOut="HideTip('tt86')">mxConstants.STYLE_DASHED</a> =&gt; isDashed</li><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_SPACING" class=LVariable id=link128 onMouseOver="ShowTip(event, 'tt87', 'link128')" onMouseOut="HideTip('tt87')">mxConstants.STYLE_SPACING</a> =&gt; spacing</li><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_STARTSIZE" class=LVariable id=link129 onMouseOver="ShowTip(event, 'tt88', 'link129')" onMouseOut="HideTip('tt88')">mxConstants.STYLE_STARTSIZE</a> =&gt; startSize</li><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_ENDSIZE" class=LVariable id=link130 onMouseOver="ShowTip(event, 'tt89', 'link130')" onMouseOut="HideTip('tt89')">mxConstants.STYLE_ENDSIZE</a> =&gt; endSize</li><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_ROUNDED" class=LVariable id=link131 onMouseOver="ShowTip(event, 'tt90', 'link131')" onMouseOut="HideTip('tt90')">mxConstants.STYLE_ROUNDED</a> =&gt; isRounded</li><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_STARTARROW" class=LVariable id=link132 onMouseOver="ShowTip(event, 'tt91', 'link132')" onMouseOut="HideTip('tt91')">mxConstants.STYLE_STARTARROW</a> =&gt; startArrow</li><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_ENDARROW" class=LVariable id=link133 onMouseOver="ShowTip(event, 'tt92', 'link133')" onMouseOut="HideTip('tt92')">mxConstants.STYLE_ENDARROW</a> =&gt; endArrow</li><li><a href="../util/mxConstants-js.html#mxConstants.STYLE_ROTATION" class=LVariable id=link134 onMouseOver="ShowTip(event, 'tt93', 'link134')" onMouseOut="HideTip('tt93')">mxConstants.S
2012-05-21 20:32:26 +00:00
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.createSvgGroup"></a>createSvgGroup</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.createSvgGroup = function(</td><td class=PParameter nowrap>shape</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Creates a SVG group element and adds the given shape as a child of the element.&nbsp; The child is stored in <a href="#mxShape.innerNode" class=LVariable id=link139 onMouseOver="ShowTip(event, 'tt16', 'link139')" onMouseOut="HideTip('tt16')">innerNode</a> for later access.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.createSvgShadow"></a>createSvgShadow</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.createSvgShadow = function(</td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Creates a clone of the given node and configures the node&rsquo;s color to use <a href="../util/mxConstants-js.html#mxConstants.SHADOWCOLOR" class=LVariable id=link140 onMouseOver="ShowTip(event, 'tt37', 'link140')" onMouseOut="HideTip('tt37')">mxConstants.SHADOWCOLOR</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.configureHtmlShape"></a>configureHtmlShape</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.configureHtmlShape = function(</td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Configures the specified HTML node by applying the current color, bounds, shadow, opacity etc.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.updateVmlFill"></a>updateVmlFill</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.updateVmlFill = function(</td><td class=PParameter nowrap>node,</td></tr><tr><td></td><td class=PParameter nowrap>c1,</td></tr><tr><td></td><td class=PParameter nowrap>c2,</td></tr><tr><td></td><td class=PParameter nowrap>dir,</td></tr><tr><td></td><td class=PParameter nowrap>alpha</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Updates the given VML fill node.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.updateVmlStrokeNode"></a>updateVmlStrokeNode</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.updateVmlStrokeNode = function(</td><td class=PParameter nowrap>parent</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Creates the stroke node for VML.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.updateVmlStrokeColor"></a>updateVmlStrokeColor</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.updateVmlStrokeColor = function(</td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Updates the VML stroke color for the given node.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.configureVmlShape"></a>configureVmlShape</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.configureVmlShape = function(</td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Configures the specified VML node by applying the current color, bounds, shadow, opacity etc.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.createVmlShadow"></a>createVmlShadow</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.createVmlShadow = function(</td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Creates the VML shadow node.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.configureTransparentBackground"></a>configureTransparentBackground</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.configureTransparentBackground = function(</td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Hook to make the background of a shape transparent.&nbsp; This hook was added as a workaround for the &ldquo;display non secure items&rdquo; warning dialog in IE which appears if the background:url(transparent.gif) is used in the overlay pane of a diagram.&nbsp; Since only mxImageShapes currently exist in the overlay pane this function is only overridden in mxImageShape.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.configureSvgShape"></a>configureSvgShape</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.configureSvgShape = function(</td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Configures the specified SVG node by applying the current color, bounds, shadow, opacity etc.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.getGradientId"></a>getGradientId</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.getGradientId = function(</td><td class=PParameter nowrap>start,</td></tr><tr><td></td><td class=PParameter nowrap>end</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Creates a unique ID for the gradient of this shape.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.createSvgPipe"></a>createSvgPipe</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.createSvgPipe = function(</td><td class=PParameter nowrap>id,</td></tr><tr><td></td><td class=PParameter nowrap>start,</td></tr><tr><td></td><td class=PParameter nowrap>end,</td></tr><tr><td></td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Creates an invisible path which is used to increase the hit detection for edges in SVG.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.createSvgGradient"></a>createSvgGradient</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.createSvgGradient = function(</td><td class=PParameter nowrap>id,</td></tr><tr><td></td><td class=PParameter nowrap>start,</td></tr><tr><td></td><td class=PParameter nowrap>end,</td></tr><tr><td></td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Creates a gradient object for SVG using the specified startcolor, endcolor and opacity.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.createPoints"></a>createPoints</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.createPoints = function(</td><td class=PParameter nowrap>moveCmd,</td></tr><tr><td></td><td class=PParameter nowrap>lineCmd,</td></tr><tr><td></td><td class=PParameter nowrap>curveCmd,</td></tr><tr><td></td><td class=PParameter nowrap>isRelative</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Creates a path expression using the specified commands for this.points.&nbsp; If &lt;isRounded&gt; is true, then the path contains curves for the corners.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.updateHtmlShape"></a>updateHtmlShape</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.updateHtmlShape = function(</td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Updates the bounds or points of the specified HTML node and updates the inner children to reflect the changes.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.updateVmlDashStyle"></a>updateVmlDashStyle</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.updateVmlDashStyle = function()</td></tr></table></blockquote><p>Updates the dashstyle in the stroke node.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.updateVmlShape"></a>updateVmlShape</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.updateVmlShape = function(</td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Updates the bounds or points of the specified VML node and updates the inner children to reflect the changes.</p></div></div></div>
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.updateSvgBounds"></a>updateSvgBounds</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.updateSvgBounds = function(</td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Updates the bounds of the given node using <a href="#mxShape.bounds" class=LVariable id=link141 onMouseOver="ShowTip(event, 'tt10', 'link141')" onMouseOut="HideTip('tt10')">bounds</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.updateSvgPath"></a>updateSvgPath</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.updateSvgPath = function(</td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Updates the path of the given node using <a href="#mxShape.points" class=LVariable id=link142 onMouseOver="ShowTip(event, 'tt12', 'link142')" onMouseOut="HideTip('tt12')">points</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.updateSvgScale"></a>updateSvgScale</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.updateSvgScale = function(</td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Updates the properties of the given node that depend on the scale and checks the crisp rendering attribute.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.updateSvgShape"></a>updateSvgShape</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.updateSvgShape = function(</td><td class=PParameter nowrap>node</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Updates the bounds or points of the specified SVG node and updates the inner children to reflect the changes.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.getSvgShadowTransform"></a>getSvgShadowTransform</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.getSvgShadowTransform = function(</td><td class=PParameter nowrap>node,</td></tr><tr><td></td><td class=PParameter nowrap>shadow</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the current transformation for SVG shadows.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.updateSvgTransform"></a>updateSvgTransform</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.updateSvgTransform = function(</td><td class=PParameter nowrap>node,</td></tr><tr><td></td><td class=PParameter nowrap>shadow</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Updates the tranform of the given node.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.reconfigure"></a>reconfigure</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.reconfigure = function()</td></tr></table></blockquote><p>Reconfigures this shape.&nbsp; This will update the colors etc in addition to the bounds or points.</p></div></div></div>
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.redraw"></a>redraw</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.redraw = function()</td></tr></table></blockquote><p>Invokes <a href="#mxShape.redrawSvg" class=LFunction id=link143 onMouseOver="ShowTip(event, 'tt61', 'link143')" onMouseOut="HideTip('tt61')">redrawSvg</a>, <a href="#mxShape.redrawVml" class=LFunction id=link144 onMouseOver="ShowTip(event, 'tt62', 'link144')" onMouseOut="HideTip('tt62')">redrawVml</a> or <a href="#mxShape.redrawHtml" class=LFunction id=link145 onMouseOver="ShowTip(event, 'tt63', 'link145')" onMouseOut="HideTip('tt63')">redrawHtml</a> depending on the dialect of the shape.</p></div></div></div>
2012-05-30 16:26:17 +00:00
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.updateBoundingBox"></a>updateBoundingBox</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.updateBoundingBox = function()</td></tr></table></blockquote><p>Updates the <a href="#mxShape.boundingBox" class=LVariable id=link146 onMouseOver="ShowTip(event, 'tt20', 'link146')" onMouseOut="HideTip('tt20')">boundingBox</a> for this shape using <a href="#mxShape.createBoundingBox" class=LFunction id=link147 onMouseOver="ShowTip(event, 'tt65', 'link147')" onMouseOut="HideTip('tt65')">createBoundingBox</a> and <a href="#mxShape.augmentBoundingBox" class=LFunction id=link148 onMouseOver="ShowTip(event, 'tt66', 'link148')" onMouseOut="HideTip('tt66')">augmentBoundingBox</a> and stores the result in <a href="#mxShape.boundingBox" class=LVariable id=link149 onMouseOver="ShowTip(event, 'tt20', 'link149')" onMouseOut="HideTip('tt20')">boundingBox</a>.</p></div></div></div>
2012-05-30 16:26:17 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.createBoundingBox"></a>createBoundingBox</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.createBoundingBox = function()</td></tr></table></blockquote><p>Returns a new rectangle that represents the bounding box of the bare shape with no shadows or strokewidths.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.augmentBoundingBox"></a>augmentBoundingBox</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.augmentBoundingBox = function(</td><td class=PParameter nowrap>bbox</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Augments the bounding box with the strokewidth and shadow offsets.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.redrawSvg"></a>redrawSvg</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.redrawSvg = function()</td></tr></table></blockquote><p>Redraws this SVG shape by invoking <a href="#mxShape.updateSvgShape" class=LFunction id=link150 onMouseOver="ShowTip(event, 'tt56', 'link150')" onMouseOut="HideTip('tt56')">updateSvgShape</a> on this.node, this.innerNode and this.shadowNode.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.updateVmlGlassPane"></a>updateVmlGlassPane</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.updateVmlGlassPane = function()</td></tr></table></blockquote><p>Draws the glass overlay if mxConstants.STYLE_GLASS is 1.</p></div></div></div>
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.updateSvgGlassPane"></a>updateSvgGlassPane</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.updateSvgGlassPane = function()</td></tr></table></blockquote><p>Draws the glass overlay if mxConstants.STYLE_GLASS is 1.</p></div></div></div>
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.redrawVml"></a>redrawVml</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.redrawVml = function()</td></tr></table></blockquote><p>Redraws this VML shape by invoking <a href="#mxShape.updateVmlShape" class=LFunction id=link151 onMouseOver="ShowTip(event, 'tt52', 'link151')" onMouseOut="HideTip('tt52')">updateVmlShape</a> on this.node.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.redrawHtml"></a>redrawHtml</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.redrawHtml = function()</td></tr></table></blockquote><p>Redraws this HTML shape by invoking <a href="#mxShape.updateHtmlShape" class=LFunction id=link152 onMouseOver="ShowTip(event, 'tt50', 'link152')" onMouseOut="HideTip('tt50')">updateHtmlShape</a> on this.node.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.getRotation"></a>getRotation</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.getRotation = function()</td></tr></table></blockquote><p>Returns the current rotation including direction.</p></div></div></div>
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.createPath"></a>createPath</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.createPath = function(</td><td class=PParameter nowrap>arg</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Creates an <a href="../util/mxPath-js.html#mxPath" class=LClass id=link153 onMouseOver="ShowTip(event, 'tt71', 'link153')" onMouseOut="HideTip('tt71')">mxPath</a> for the specified format and origin.&nbsp; The path object is then passed to <a href="#mxShape.redrawPath" class=LFunction id=link154 onMouseOver="ShowTip(event, 'tt72', 'link154')" onMouseOut="HideTip('tt72')">redrawPath</a> and <a href="../util/mxPath-js.html#mxPath.getPath" class=LFunction id=link155 onMouseOver="ShowTip(event, 'tt95', 'link155')" onMouseOut="HideTip('tt95')">mxPath.getPath</a> is returned.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2012-07-16 15:36:48 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxShape.redrawPath"></a>redrawPath</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class=PBeforeParameters nowrap>mxShape.prototype.redrawPath = function(</td><td class=PParameter nowrap>path,</td></tr><tr><td></td><td class=PParameter nowrap>x,</td></tr><tr><td></td><td class=PParameter nowrap>y,</td></tr><tr><td></td><td class=PParameter nowrap>w,</td></tr><tr><td></td><td class=PParameter nowrap>h</td><td class=PAfterParameters nowrap>)</td></tr></table></td></tr></table></blockquote><p>Draws the path for this shape.&nbsp; This implementation is empty.&nbsp; See <a href="mxActor-js.html#mxActor" class=LClass id=link156 onMouseOver="ShowTip(event, 'tt75', 'link156')" onMouseOut="HideTip('tt75')">mxActor</a> and <a href="mxCylinder-js.html#mxCylinder" class=LClass id=link157 onMouseOver="ShowTip(event, 'tt76', 'link157')" onMouseOut="HideTip('tt76')">mxCylinder</a> for implementations.</p></div></div></div>
2012-05-21 20:32:26 +00:00
</div><!--Content-->
<div id=Footer><a href="http://www.naturaldocs.org">Generated by Natural Docs</a></div><!--Footer-->
<div id=Menu><div class=MEntry><div class=MFile><a href="../index-txt.html">API Specification</a></div></div><div class=MEntry><div class=MGroup><a href="javascript:ToggleMenu('MGroupContent1')">Editor</a><div class=MGroupContent id=MGroupContent1><div class=MEntry><div class=MFile><a href="../editor/mxDefaultKeyHandler-js.html">mxDefaultKeyHandler</a></div></div><div class=MEntry><div class=MFile><a href="../editor/mxDefaultPopupMenu-js.html">mxDefaultPopupMenu</a></div></div><div class=MEntry><div class=MFile><a href="../editor/mxDefaultToolbar-js.html">mxDefaultToolbar</a></div></div><div class=MEntry><div class=MFile><a href="../editor/mxEditor-js.html">mxEditor</a></div></div></div></div></div><div class=MEntry><div class=MGroup><a href="javascript:ToggleMenu('MGroupContent2')">Handler</a><div class=MGroupContent id=MGroupContent2><div class=MEntry><div class=MFile><a href="../handler/mxCellHighlight-js.html">mxCellHighlight</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxCellMarker-js.html">mxCellMarker</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxCellTracker-js.html">mxCellTracker</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxConnectionHandler-js.html">mxConnectionHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxConstraintHandler-js.html">mxConstraintHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxEdgeHandler-js.html">mxEdgeHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxEdgeSegmentHandler-js.html">mxEdgeSegmentHandler.js</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxElbowEdgeHandler-js.html">mxElbowEdgeHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxGraphHandler-js.html">mxGraphHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxKeyHandler-js.html">mxKeyHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxPanningHandler-js.html">mxPanningHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxRubberband-js.html">mxRubberband</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxSelectionCellsHandler-js.html">mxSelectionCellsHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxTooltipHandler-js.html">mxTooltipHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxVertexHandler-js.html">mxVertexHandler</a></div></div></div></div></div><div class=MEntry><div class=MGroup><a href="javascript:ToggleMenu('MGroupContent3')">Io</a><div class=MGroupContent id=MGroupContent3><div class=MEntry><div class=MFile><a href="../io/mxCellCodec-js.html">mxCellCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxChildChangeCodec-js.html">mxChildChangeCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxCodec-js.html">mxCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxCodecRegistry-js.html">mxCodecRegistry</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxDefaultKeyHandlerCodec-js.html">mxDefaultKeyHandlerCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxDefaultPopupMenuCodec-js.html">mxDefaultPopupMenuCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxDefaultToolbarCodec-js.html">mxDefaultToolbarCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxEditorCodec-js.html">mxEditorCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxGenericChangeCodec-js.html">mxGenericChangeCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxGraphCodec-js.html">mxGraphCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxGraphViewCodec-js.html">mxGraphViewCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxModelCodec-js.html">mxModelCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxObjectCodec-js.html">mxObjectCodec</a></div></div><div
var searchPanel = new SearchPanel("searchPanel", "HTML", "../../search");
--></script><div id=MSearchPanel class=MSearchPanelInactive><input type=text id=MSearchField value=Search onFocus="searchPanel.OnSearchFieldFocus(true)" onBlur="searchPanel.OnSearchFieldFocus(false)" onKeyUp="searchPanel.OnSearchFieldChange()"><select id=MSearchType onFocus="searchPanel.OnSearchTypeFocus(true)" onBlur="searchPanel.OnSearchTypeFocus(false)" onChange="searchPanel.OnSearchTypeChange()"><option id=MSearchEverything selected value="General">Everything</option><option value="Classes">Classes</option><option value="Cookies">Cookies</option><option value="Events">Events</option><option value="Files">Files</option><option value="Functions">Functions</option><option value="Variables">Variables</option></select></div><script language=JavaScript><!--
HideAllBut([9], 13);// --></script></div><!--Menu-->
<!--START_ND_TOOLTIPS-->
2012-07-16 15:36:48 +00:00
<div class=CToolTip id="tt1"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>function mxShape()</td></tr></table></blockquote>Constructs a new shape.</div></div><div class=CToolTip id="tt2"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.SVG_STROKE_TOLERANCE</td></tr></table></blockquote>Event-tolerance for SVG strokes (in px). </div></div><div class=CToolTip id="tt3"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.scale</td></tr></table></blockquote>Holds the scale in which the shape is being painted.</div></div><div class=CToolTip id="tt4"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.dialect</td></tr></table></blockquote>Holds the dialect in which the shape is to be painted. </div></div><div class=CToolTip id="tt5"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.crisp</td></tr></table></blockquote>Special attribute for SVG rendering to set the shape-rendering attribute to crispEdges in the output. </div></div><div class=CToolTip id="tt6"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.roundedCrispSvg</td></tr></table></blockquote>Specifies if crisp rendering should be enabled for rounded shapes. </div></div><div class=CToolTip id="tt7"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.mixedModeHtml</td></tr></table></blockquote>Specifies if createHtml should be used in mixed Html mode. </div></div><div class=CToolTip id="tt8"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.createHtml = function()</td></tr></table></blockquote>Creates and returns the HTML DOM node(s) to represent this shape. </div></div><div class=CToolTip id="tt9"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.preferModeHtml</td></tr></table></blockquote>Specifies if createHtml should be used in prefer Html mode. </div></div><div class=CToolTip id="tt10"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.bounds</td></tr></table></blockquote>Holds the mxRectangle that specifies the bounds of this shape.</div></div><div class=CToolTip id="tt11"><div class=CClass>Extends mxPoint to implement a 2-dimensional rectangle with double precision coordinates.</div></div><div class=CToolTip id="tt12"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.points</td></tr></table></blockquote>Holds the array of mxPoints that specify the points of this shape.</div></div><div class=CToolTip id="tt13"><div class=CClass>Implements a 2-dimensional vector with double precision coordinates.</div></div><div class=CToolTip id="tt14"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.node</td></tr></table></blockquote>Holds the outermost DOM node that represents this shape.</div></div><div class=CToolTip id="tt15"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.label</td></tr></table></blockquote>Reference to the DOM node that should contain the label. </div></div><div class=CToolTip id="tt16"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype prettyprint"><tr><td>mxShape.prototype.innerNode</td></tr></table></blockquote>Holds the DOM node that graphically represents this shape
2012-05-21 20:32:26 +00:00
<div id=MSearchResultsWindow><iframe src="" frameborder=0 name=MSearchResults id=MSearchResults></iframe><a href="javascript:searchPanel.CloseResultsWindow()" id=MSearchResultsWindowClose>Close</a></div>
<script language=JavaScript><!--
if (browserType) {if (browserVer) {document.write("</div>"); }document.write("</div>");}// --></script></body></html>