<li><ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true"title="class or interface in java.lang">java.lang.Object</a></li>
<li>
<ulclass="inheritance">
<li>com.mxgraph.util.mxStyleUtils</li>
</ul>
</li>
</ul>
<divclass="description">
<ulclass="blockList">
<liclass="blockList">
<hr>
<br>
<pre>public class <spanclass="strong">mxStyleUtils</span>
extends <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true"title="class or interface in java.lang">Object</a></pre>
<divclass="block">Contains various style helper methods for use with mxGraph.</div>
<thclass="colFirst"scope="col">Modifier and Type</th>
<thclass="colLast"scope="col">Method and Description</th>
</tr>
<trclass="altColor">
<tdclass="colFirst"><code>static <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a></code></td>
<tdclass="colLast"><code><strong><ahref="../../../com/mxgraph/util/mxStyleUtils.html#addStylename(java.lang.String, java.lang.String)">addStylename</a></strong>(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> stylename)</code>
<divclass="block">Adds the specified stylename to the given style if it does not already
contain the stylename.</div>
</td>
</tr>
<trclass="rowColor">
<tdclass="colFirst"><code>static <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a></code></td>
<tdclass="colLast"><code><strong><ahref="../../../com/mxgraph/util/mxStyleUtils.html#getStylename(java.lang.String)">getStylename</a></strong>(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style)</code>
<divclass="block">Returns the stylename in a style of the form stylename[;key=value] or an
empty string if the given style does not contain a stylename.</div>
</td>
</tr>
<trclass="altColor">
<tdclass="colFirst"><code>static <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a>[]</code></td>
<tdclass="colLast"><code><strong><ahref="../../../com/mxgraph/util/mxStyleUtils.html#getStylenames(java.lang.String)">getStylenames</a></strong>(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style)</code>
<divclass="block">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.</div>
</td>
</tr>
<trclass="rowColor">
<tdclass="colFirst"><code>static int</code></td>
<tdclass="colLast"><code><strong><ahref="../../../com/mxgraph/util/mxStyleUtils.html#indexOfStylename(java.lang.String, java.lang.String)">indexOfStylename</a></strong>(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> stylename)</code>
<divclass="block">Returns the index of the given stylename in the given style.</div>
</td>
</tr>
<trclass="altColor">
<tdclass="colFirst"><code>static <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a></code></td>
<tdclass="colLast"><code><strong><ahref="../../../com/mxgraph/util/mxStyleUtils.html#removeAllStylenames(java.lang.String)">removeAllStylenames</a></strong>(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style)</code>
<divclass="block">Removes all stylenames from the given style and returns the updated
style.</div>
</td>
</tr>
<trclass="rowColor">
<tdclass="colFirst"><code>static <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a></code></td>
<tdclass="colLast"><code><strong><ahref="../../../com/mxgraph/util/mxStyleUtils.html#removeStylename(java.lang.String, java.lang.String)">removeStylename</a></strong>(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> stylename)</code>
<divclass="block">Removes all occurrences of the specified stylename in the given style and
returns the updated style.</div>
</td>
</tr>
<trclass="altColor">
<tdclass="colFirst"><code>static void</code></td>
<tdclass="colLast"><code><strong><ahref="../../../com/mxgraph/util/mxStyleUtils.html#setCellStyleFlags(com.mxgraph.model.mxIGraphModel, java.lang.Object[], java.lang.String, int, java.lang.Boolean)">setCellStyleFlags</a></strong>(<ahref="../../../com/mxgraph/model/mxIGraphModel.html"title="interface in com.mxgraph.model">mxIGraphModel</a> model,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true"title="class or interface in java.lang">Object</a>[] cells,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> key,
int flag,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Boolean.html?is-external=true"title="class or interface in java.lang">Boolean</a> value)</code>
<divclass="block">Sets or toggles the flag bit for the given key in the cell's styles.</div>
</td>
</tr>
<trclass="rowColor">
<tdclass="colFirst"><code>static void</code></td>
<tdclass="colLast"><code><strong><ahref="../../../com/mxgraph/util/mxStyleUtils.html#setCellStyles(com.mxgraph.model.mxIGraphModel, java.lang.Object[], java.lang.String, java.lang.String)">setCellStyles</a></strong>(<ahref="../../../com/mxgraph/model/mxIGraphModel.html"title="interface in com.mxgraph.model">mxIGraphModel</a> model,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true"title="class or interface in java.lang">Object</a>[] cells,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> key,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> value)</code>
<divclass="block">Assigns the value for the given key in the styles of the given cells, or
removes the key from the styles if the value is null.</div>
</td>
</tr>
<trclass="altColor">
<tdclass="colFirst"><code>static <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a></code></td>
<tdclass="colLast"><code><strong><ahref="../../../com/mxgraph/util/mxStyleUtils.html#setStyle(java.lang.String, java.lang.String, java.lang.String)">setStyle</a></strong>(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> key,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> value)</code>
<divclass="block">Adds or removes the given key, value pair to the style and returns the
new style.</div>
</td>
</tr>
<trclass="rowColor">
<tdclass="colFirst"><code>static <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a></code></td>
<tdclass="colLast"><code><strong><ahref="../../../com/mxgraph/util/mxStyleUtils.html#setStyleFlag(java.lang.String, java.lang.String, int, java.lang.Boolean)">setStyleFlag</a></strong>(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> key,
int flag,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Boolean.html?is-external=true"title="class or interface in java.lang">Boolean</a> value)</code>
<divclass="block">Sets or removes the given key from the specified style and returns the
<h3>Methods inherited from class java.lang.<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true"title="class or interface in java.lang">Object</a></h3>
<code><ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#clone()"title="class or interface in java.lang">clone</a>, <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)"title="class or interface in java.lang">equals</a>, <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#finalize()"title="class or interface in java.lang">finalize</a>, <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#getClass()"title="class or interface in java.lang">getClass</a>, <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#hashCode()"title="class or interface in java.lang">hashCode</a>, <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#notify()"title="class or interface in java.lang">notify</a>, <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#notifyAll()"title="class or interface in java.lang">notifyAll</a>, <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#toString()"title="class or interface in java.lang">toString</a>, <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait()"title="class or interface in java.lang">wait</a>, <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long)"title="class or interface in java.lang">wait</a>, <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)"title="class or interface in java.lang">wait</a></code></li>
<pre>public static <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> getStylename(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style)</pre>
<divclass="block">Returns the stylename in a style of the form stylename[;key=value] or an
empty string if the given style does not contain a stylename.</div>
<dl><dt><spanclass="strong">Parameters:</span></dt><dd><code>style</code> - String of the form stylename[;key=value].</dd>
<dt><spanclass="strong">Returns:</span></dt><dd>Returns the stylename from the given formatted string.</dd></dl>
</li>
</ul>
<aname="getStylenames(java.lang.String)">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>getStylenames</h4>
<pre>public static <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a>[] getStylenames(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style)</pre>
<divclass="block">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.</div>
<dl><dt><spanclass="strong">Parameters:</span></dt><dd><code>style</code> - String of the form stylename[;stylename][;key=value].</dd>
<dt><spanclass="strong">Returns:</span></dt><dd>Returns the stylename from the given formatted string.</dd></dl>
<pre>public static int indexOfStylename(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> stylename)</pre>
<divclass="block">Returns the index of the given stylename in the given style. This returns
<pre>public static <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> addStylename(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> stylename)</pre>
<divclass="block">Adds the specified stylename to the given style if it does not already
<pre>public static <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> removeStylename(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> stylename)</pre>
<divclass="block">Removes all occurrences of the specified stylename in the given style and
returns the updated style. Trailing semicolons are preserved.</div>
</li>
</ul>
<aname="removeAllStylenames(java.lang.String)">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>removeAllStylenames</h4>
<pre>public static <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> removeAllStylenames(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style)</pre>
<divclass="block">Removes all stylenames from the given style and returns the updated
<pre>public static void setCellStyles(<ahref="../../../com/mxgraph/model/mxIGraphModel.html"title="interface in com.mxgraph.model">mxIGraphModel</a> model,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true"title="class or interface in java.lang">Object</a>[] cells,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> key,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> value)</pre>
<divclass="block">Assigns the value for the given key in the styles of the given cells, or
removes the key from the styles if the value is null.</div>
<dl><dt><spanclass="strong">Parameters:</span></dt><dd><code>model</code> - Model to execute the transaction in.</dd><dd><code>cells</code> - Array of cells to be updated.</dd><dd><code>key</code> - Key of the style to be changed.</dd><dd><code>value</code> - New value for the given key.</dd></dl>
<pre>public static <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> setStyle(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> key,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> value)</pre>
<divclass="block">Adds or removes the given key, value pair to the style and returns the
<dl><dt><spanclass="strong">Parameters:</span></dt><dd><code>style</code> - String of the form <code>stylename[;key=value]</code>.</dd><dd><code>key</code> - Key of the style to be changed.</dd><dd><code>value</code> - New value for the given key.</dd>
<dt><spanclass="strong">Returns:</span></dt><dd>Returns the new style.</dd></dl>
<pre>public static void setCellStyleFlags(<ahref="../../../com/mxgraph/model/mxIGraphModel.html"title="interface in com.mxgraph.model">mxIGraphModel</a> model,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true"title="class or interface in java.lang">Object</a>[] cells,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> key,
int flag,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Boolean.html?is-external=true"title="class or interface in java.lang">Boolean</a> value)</pre>
<divclass="block">Sets or toggles the flag bit for the given key in the cell's styles. If
<dl><dt><spanclass="strong">Parameters:</span></dt><dd><code>model</code> - Model that contains the cells.</dd><dd><code>cells</code> - Array of cells to change the style for.</dd><dd><code>key</code> - Key of the style to be changed.</dd><dd><code>flag</code> - Integer for the bit to be changed.</dd><dd><code>value</code> - Optional boolean value for the flag.</dd></dl>
<pre>public static <ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> setStyleFlag(<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> style,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</a> key,
int flag,
<ahref="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Boolean.html?is-external=true"title="class or interface in java.lang">Boolean</a> value)</pre>
<divclass="block">Sets or removes the given key from the specified style and returns the
new style. If value is null then the flag is toggled.</div>
<dl><dt><spanclass="strong">Parameters:</span></dt><dd><code>style</code> - String of the form stylename[;key=value].</dd><dd><code>key</code> - Key of the style to be changed.</dd><dd><code>flag</code> - Integer for the bit to be changed.</dd><dd><code>value</code> - Optional boolean value for the given flag.</dd></dl>