<divid=Content><divclass="CClass"><divclass=CTopicid=MainTopic><h1class=CTitle><aname="mxStackLayout"></a>mxStackLayout</h1><divclass=CBody><p>Extends <ahref="mxGraphLayout-js.html#mxGraphLayout"class=LClassid=link28onMouseOver="ShowTip(event, 'tt1', 'link28')"onMouseOut="HideTip('tt1')">mxGraphLayout</a> to create a horizontal or vertical stack of the child vertices. The children do not need to be connected for this layout to work.</p><h4class=CHeading>Example</h4><blockquote><preclass="prettyprint">var layout = new mxStackLayout(graph, true);
layout.execute(graph.getDefaultParent());</pre></blockquote><!--START_ND_SUMMARY--><divclass=Summary><divclass=STitle>Summary</div><divclass=SBorder><tableborder=0cellspacing=0cellpadding=0class=STable><trclass="SMain"><tdclass=SEntry><ahref="#mxStackLayout">mxStackLayout</a></td><tdclass=SDescription>Extends <ahref="mxGraphLayout-js.html#mxGraphLayout"class=LClassid=link1onMouseOver="ShowTip(event, 'tt1', 'link1')"onMouseOut="HideTip('tt1')">mxGraphLayout</a> to create a horizontal or vertical stack of the child vertices. </td></tr><trclass="SGroup SIndent1"><tdclass=SEntry><ahref="#mxStackLayout.Functions">Functions</a></td><tdclass=SDescription></td></tr><trclass="SFunction SIndent2 SMarked"><tdclass=SEntry><ahref="#mxStackLayout.mxStackLayout"id=link2onMouseOver="ShowTip(event, 'tt2', 'link2')"onMouseOut="HideTip('tt2')">mxStackLayout</a></td><tdclass=SDescription>Constructs a new stack layout layout for the specified graph, spacing, orientation and offset.</td></tr><trclass="SGroup SIndent1"><tdclass=SEntry><ahref="#mxStackLayout.Variables">Variables</a></td><tdclass=SDescription></td></tr><trclass="SVariable SIndent2 SMarked"><tdclass=SEntry><ahref="#mxStackLayout.horizontal"id=link3onMouseOver="ShowTip(event, 'tt3', 'link3')"onMouseOut="HideTip('tt3')">horizontal</a></td><tdclass=SDescription>Specifies the orientation of the layout. </td></tr><trclass="SVariable SIndent2"><tdclass=SEntry><ahref="#mxStackLayout.spacing"id=link4onMouseOver="ShowTip(event, 'tt4', 'link4')"onMouseOut="HideTip('tt4')">spacing</a></td><tdclass=SDescription>Specifies the spacing between the cells. </td></tr><trclass="SVariable SIndent2 SMarked"><tdclass=SEntry><ahref="#mxStackLayout.x0"id=link5onMouseOver="ShowTip(event, 'tt5', 'link5')"onMouseOut="HideTip('tt5')">x0</a></td><tdclass=SDescription>Specifies the horizontal origin of the layout. </td></tr><trclass="SVariable SIndent2"><tdclass=SEntry><ahref="#mxStackLayout.y0"id=link6onMouseOver="ShowTip(event, 'tt6', 'link6')"onMouseOut="HideTip('tt6')">y0</a></td><tdclass=SDescription>Specifies the vertical origin of the layout. </td></tr><trclass="SVariable SIndent2 SMarked"><tdclass=SEntry><ahref="#mxStackLayout.border"id=link7onMouseOver="ShowTip(event, 'tt7', 'link7')"onMouseOut="HideTip('tt7')">border</a></td><tdclass=SDescription>Border to be added if fill is true. </td></tr><trclass="SVariable SIndent2"><tdclass=SEntry><ahref="#mxStackLayout.marginTop"id=link8onMouseOver="ShowTip(event, 'tt8', 'link8')"onMouseOut="HideTip('tt8')">marginTop</a></td><tdclass=SDescription>Top margin for the child area. </td></tr><trclass="SVariable SIndent2 SMarked"><tdclass=SEntry><ahref="#mxStackLayout.marginLeft"id=link9onMouseOver="ShowTip(event, 'tt9', 'link9')"onMouseOut="HideTip('tt9')">marginLeft</a></td><tdclass=SDescription>Top margin for the child area. </td></tr><trclass="SVariable SIndent2"><tdclass=SEntry><ahref="#mxStackLayout.marginRight"id=link10onMouseOver="ShowTip(event, 'tt10', 'link10')"onMouseOut="HideTip('tt10')">marginRight</a></td><tdclass=SDescription>Top margin for the child area. </td></tr><trclass="SVariable SIndent2 SMarked"><tdclass=SEntry><ahref="#mxStackLayout.marginBottom"id=link11onMouseOver="ShowTip(event, 'tt11', 'link11')"onMouseOut="HideTip('tt11')">marginBottom</a></td><tdclass=SDescription>Top margin for the child area. </td></tr><trclass="SVariable SIndent2"><tdclass=SEntry><ahref="#mxStackLayout.keepFirstLocation"id=link12onMouseOver="ShowTip(event, 'tt12', 'link12')"onMouseOut="HideTip('tt12')">keepFirstLocation</a></td><tdclass=SDescription>Boolean indicating if the location of the first cell should be kept, that is, it will not be moved to x0 or y0.</td></tr><trclass="SVariable SIndent2 SMarked"><tdclass=SEntry><ahref="#mxStackLayout.fill"id=link13onMouseOver="ShowTip(event, 'tt13', 'link13')"onMouseOut="HideTip('tt13')">fill</a></td><tdclass=SDescription>Boolean indicating if dimension should be changed to fill out the parent cell. </td></tr><tr
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.mxStackLayout"></a>mxStackLayout</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass=PBeforeParametersnowrap>function mxStackLayout(</td><tdclass=PParameternowrap>graph,</td></tr><tr><td></td><tdclass=PParameternowrap>horizontal,</td></tr><tr><td></td><tdclass=PParameternowrap>spacing,</td></tr><tr><td></td><tdclass=PParameternowrap>x0,</td></tr><tr><td></td><tdclass=PParameternowrap>y0,</td></tr><tr><td></td><tdclass=PParameternowrap>border</td><tdclass=PAfterParametersnowrap>)</td></tr></table></td></tr></table></blockquote><p>Constructs a new stack layout layout for the specified graph, spacing, orientation and offset.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.horizontal"></a>horizontal</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.horizontal</td></tr></table></blockquote><p>Specifies the orientation of the layout. Default is true.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.spacing"></a>spacing</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.spacing</td></tr></table></blockquote><p>Specifies the spacing between the cells. Default is 0.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.x0"></a>x0</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.x0</td></tr></table></blockquote><p>Specifies the horizontal origin of the layout. Default is 0.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.y0"></a>y0</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.y0</td></tr></table></blockquote><p>Specifies the vertical origin of the layout. Default is 0.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.border"></a>border</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.border</td></tr></table></blockquote><p>Border to be added if fill is true. Default is 0.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.marginTop"></a>marginTop</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.marginTop</td></tr></table></blockquote><p>Top margin for the child area. Default is 0.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.marginLeft"></a>marginLeft</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.marginLeft</td></tr></table></blockquote><p>Top margin for the child area. Default is 0.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.marginRight"></a>marginRight</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.marginRight</td></tr></table></blockquote><p>Top margin for the child area. Default is 0.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.marginBottom"></a>marginBottom</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.marginBottom</td></tr></table></blockquote><p>Top margin for the child area. Default is 0.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.keepFirstLocation"></a>keepFirstLocation</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.keepFirstLocation</td></tr></table></blockquote><p>Boolean indicating if the location of the first cell should be kept, that is, it will not be moved to x0 or y0.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.fill"></a>fill</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.fill</td></tr></table></blockquote><p>Boolean indicating if dimension should be changed to fill out the parent cell. Default is false.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.resizeParent"></a>resizeParent</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.resizeParent</td></tr></table></blockquote><p>If the parent should be resized to match the width/height of the stack. Default is false.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.resizeParentMax"></a>resizeParentMax</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.resizeParentMax</td></tr></table></blockquote><p>Use maximum of existing value and new value for resize of parent. Default is false.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.resizeLast"></a>resizeLast</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.resizeLast</td></tr></table></blockquote><p>If the last element should be resized to fill out the parent. Default is false. If <ahref="#mxStackLayout.resizeParent"class=LVariableid=link29onMouseOver="ShowTip(event, 'tt14', 'link29')"onMouseOut="HideTip('tt14')">resizeParent</a> is true then this is ignored.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.wrap"></a>wrap</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.wrap</td></tr></table></blockquote><p>Value at which a new column or row should be created. Default is null.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.borderCollapse"></a>borderCollapse</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.borderCollapse</td></tr></table></blockquote><p>If the strokeWidth should be ignored. Default is true.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.getParentSize"></a>getParentSize</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass=PBeforeParametersnowrap>mxStackLayout.prototype.getParentSize = function(</td><tdclass=PParameternowrap>parent</td><tdclass=PAfterParametersnowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the size for the parent container or the size of the graph container if the parent is a layer or the root of the model.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.execute"></a>execute</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass=PBeforeParametersnowrap>mxStackLayout.prototype.execute = function(</td><tdclass=PParameternowrap>parent</td><tdclass=PAfterParametersnowrap>)</td></tr></table></td></tr></table></blockquote><p>Implements <ahref="mxGraphLayout-js.html#mxGraphLayout.execute"class=LFunctionid=link32onMouseOver="ShowTip(event, 'tt24', 'link32')"onMouseOut="HideTip('tt24')">mxGraphLayout.execute</a>.</p><p>Only children where <isVertexIgnored> returns false are taken into account.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.execute"></a>execute</h3><divclass=CBody><p>Implements <ahref="mxGraphLayout-js.html#mxGraphLayout.execute"class=LFunctionid=link33onMouseOver="ShowTip(event, 'tt24', 'link33')"onMouseOut="HideTip('tt24')">mxGraphLayout.execute</a>.</p><p>Only children where <isVertexIgnored> returns false are taken into account.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxStackLayout.execute"></a>execute</h3><divclass=CBody><p>Implements <ahref="mxGraphLayout-js.html#mxGraphLayout.execute"class=LFunctionid=link34onMouseOver="ShowTip(event, 'tt24', 'link34')"onMouseOut="HideTip('tt24')">mxGraphLayout.execute</a>.</p><p>Only children where <isVertexIgnored> returns false are taken into account.</p></div></div></div>
<divclass=CToolTipid="tt1"><divclass=CClass>Base class for all layout algorithms in mxGraph. </div></div><divclass=CToolTipid="tt2"><divclass=CFunction><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass=PBeforeParametersnowrap>function mxStackLayout(</td><tdclass=PParameternowrap>graph,</td></tr><tr><td></td><tdclass=PParameternowrap>horizontal,</td></tr><tr><td></td><tdclass=PParameternowrap>spacing,</td></tr><tr><td></td><tdclass=PParameternowrap>x0,</td></tr><tr><td></td><tdclass=PParameternowrap>y0,</td></tr><tr><td></td><tdclass=PParameternowrap>border</td><tdclass=PAfterParametersnowrap>)</td></tr></table></td></tr></table></blockquote>Constructs a new stack layout layout for the specified graph, spacing, orientation and offset.</div></div><divclass=CToolTipid="tt3"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.horizontal</td></tr></table></blockquote>Specifies the orientation of the layout. </div></div><divclass=CToolTipid="tt4"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.spacing</td></tr></table></blockquote>Specifies the spacing between the cells. </div></div><divclass=CToolTipid="tt5"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.x0</td></tr></table></blockquote>Specifies the horizontal origin of the layout. </div></div><divclass=CToolTipid="tt6"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.y0</td></tr></table></blockquote>Specifies the vertical origin of the layout. </div></div><divclass=CToolTipid="tt7"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.border</td></tr></table></blockquote>Border to be added if fill is true. </div></div><divclass=CToolTipid="tt8"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.marginTop</td></tr></table></blockquote>Top margin for the child area. </div></div><divclass=CToolTipid="tt9"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.marginLeft</td></tr></table></blockquote>Top margin for the child area. </div></div><divclass=CToolTipid="tt10"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.marginRight</td></tr></table></blockquote>Top margin for the child area. </div></div><divclass=CToolTipid="tt11"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.marginBottom</td></tr></table></blockquote>Top margin for the child area. </div></div><divclass=CToolTipid="tt12"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.keepFirstLocation</td></tr></table></blockquote>Boolean indicating if the location of the first cell should be kept, that is, it will not be moved to x0 or y0.</div></div><divclass=CToolTipid="tt13"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.fill</td></tr></table></blockquote>Boolean indicating if dimension should be changed to fill out the parent cell. </div></div><divclass=CToolTipid="tt14"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype prettyprint"><tr><td>mxStackLayout.prototype.resizeParent</td></tr></table></blockquote>If the parent should be resized to match the width/height of the s