com::mxgraph::mxStylesheet Class Reference

Defines the appearance of the cells in a graph. More...

List of all members.

Public Member Functions

 mxStylesheet ()
 Constructs a new stylesheet and assigns default styles.
void PutCellStyle (string name, Dictionary< string, Object > style)
 Stores the specified style under the given name.
Dictionary< string, Object > GetCellStyle (string name, Dictionary< string, Object > defaultStyle)
 Returns the cell style for the specified cell or the given defaultStyle if no style can be found for the given stylename.

Static Public Attributes

static Dictionary< string, Object > EMPTY_STYLE = new Dictionary<string, Object>()
 Shared immutable empty dictionary (for undefined cell styles).

Protected Member Functions

Dictionary< string, Object > CreateDefaultVertexStyle ()
 Creates and returns the default vertex style.
Dictionary< string, Object > CreateDefaultEdgeStyle ()
 Creates and returns the default edge style.

Protected Attributes

Dictionary< string, Dictionary
< string, Object > > 
styles
 Maps from names to styles.

Properties

Dictionary< string, Dictionary
< string, Object > > 
Styles [get, set]
 Sets or returns the map that contains the styles.
Dictionary< string, Object > DefaultVertexStyle [get, set]
 Sets or returns the default style for vertices.
Dictionary< string, Object > DefaultEdgeStyle [get, set]
 Sets or returns the default style for edges.

Detailed Description

Defines the appearance of the cells in a graph.


Constructor & Destructor Documentation

com::mxgraph::mxStylesheet::mxStylesheet (  )  [inline]

Constructs a new stylesheet and assigns default styles.


Member Function Documentation

Dictionary<string, Object> com::mxgraph::mxStylesheet::CreateDefaultEdgeStyle (  )  [inline, protected]

Creates and returns the default edge style.

Returns:
Returns the default edge style.
Dictionary<string, Object> com::mxgraph::mxStylesheet::CreateDefaultVertexStyle (  )  [inline, protected]

Creates and returns the default vertex style.

Returns:
Returns the default vertex style.
Dictionary<string, Object> com::mxgraph::mxStylesheet::GetCellStyle ( string  name,
Dictionary< string, Object >  defaultStyle 
) [inline]

Returns the cell style for the specified cell or the given defaultStyle if no style can be found for the given stylename.

Parameters:
name String of the form [(stylename|key=value);] that represents the style.
defaultStyle Default style to be returned if no style can be found.
Returns:
Returns the style for the given formatted cell style.
void com::mxgraph::mxStylesheet::PutCellStyle ( string  name,
Dictionary< string, Object >  style 
) [inline]

Stores the specified style under the given name.

Parameters:
name Name for the style to be stored.
style Key, value pairs that define the style.

Member Data Documentation

Dictionary<string, Object> com::mxgraph::mxStylesheet::EMPTY_STYLE = new Dictionary<string, Object>() [static]

Shared immutable empty dictionary (for undefined cell styles).

Dictionary<string, Dictionary<string, Object> > com::mxgraph::mxStylesheet::styles [protected]
Initial value:
            new Dictionary<string, Dictionary<string, Object>>()

Maps from names to styles.


Property Documentation

Dictionary<string, Object> com::mxgraph::mxStylesheet::DefaultEdgeStyle [get, set]

Sets or returns the default style for edges.

Dictionary<string, Object> com::mxgraph::mxStylesheet::DefaultVertexStyle [get, set]

Sets or returns the default style for vertices.

Dictionary<string, Dictionary<string, Object> > com::mxgraph::mxStylesheet::Styles [get, set]

Sets or returns the map that contains the styles.


The documentation for this class was generated from the following file:
Generated on Mon Oct 29 20:11:50 2012 for mxGraph by  doxygen 1.6.3