|
JGraph X 1.0.2.8 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.mxgraph.view.mxStylesheet
public class mxStylesheet
Defines the appearance of the cells in a graph.
Field Summary | |
---|---|
static Hashtable |
EMPTY_STYLE
Shared immutable empty hashtable (for undefined cell styles). |
protected Hashtable |
styles
Maps from names to styles. |
Constructor Summary | |
---|---|
mxStylesheet()
Constructs a new stylesheet and assigns default styles. |
Method Summary | |
---|---|
protected Hashtable |
createDefaultEdgeStyle()
Creates and returns the default edge style. |
protected Hashtable |
createDefaultVertexStyle()
Creates and returns the default vertex style. |
Hashtable |
getCellStyle(String name,
Hashtable defaultStyle)
Returns the cell style for the specified cell or the given defaultStyle if no style can be found for the given stylename. |
Hashtable |
getDefaultEdgeStyle()
Returns the default style for edges. |
Hashtable |
getDefaultVertexStyle()
Returns the default style for vertices. |
Hashtable |
getStyles()
Returns all styles as map of name, hashtable pairs. |
void |
putCellStyle(String name,
Hashtable style)
Stores the specified style under the given name. |
void |
setDefaultEdgeStyle(Hashtable value)
Sets the default style for edges. |
void |
setDefaultVertexStyle(Hashtable value)
Sets the default style for vertices. |
void |
setStyles(Hashtable styles)
Sets all styles in the stylesheet. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final Hashtable EMPTY_STYLE
protected Hashtable styles
Constructor Detail |
---|
public mxStylesheet()
Method Detail |
---|
public Hashtable getStyles()
public void setStyles(Hashtable styles)
protected Hashtable createDefaultVertexStyle()
protected Hashtable createDefaultEdgeStyle()
public Hashtable getDefaultVertexStyle()
public void setDefaultVertexStyle(Hashtable value)
value
- Style to be used for vertices.public Hashtable getDefaultEdgeStyle()
public void setDefaultEdgeStyle(Hashtable value)
value
- Style to be used for edges.public void putCellStyle(String name, Hashtable style)
name
- Name for the style to be stored.style
- Key, value pairs that define the style.public Hashtable getCellStyle(String name, Hashtable defaultStyle)
name
- String of the form stylename[;key=value] that represents the
style.defaultStyle
- Default style to be returned if no style can be found.
|
JGraph X 1.0.2.8 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |