public class OfficeStyleFamily
extends java.lang.Object
Constructor and Description |
---|
OfficeStyleFamily(java.lang.Class styleClass)
Create a new OfficeStyleFamily based on a class
|
Modifier and Type | Method and Description |
---|---|
OfficeStyle |
getDefaultStyle()
Get the default style for this family
|
java.lang.String |
getDisplayName(java.lang.String sName)
Get the display name for the style with the specified name.
|
OfficeStyle |
getStyle(java.lang.String sName)
Get a style by name
|
OfficeStyle |
getStyleByDisplayName(java.lang.String sDisplayName)
Get a style by display name.
|
java.util.Enumeration<java.lang.Object> |
getStylesEnumeration()
Get all named styles in the family (ie. excluding the default style)
|
void |
loadStyleFromDOM(org.w3c.dom.Node node,
boolean bAutomatic)
Load a style from a DOM representation
|
void |
setDefaultStyle(OfficeStyle style)
Define the default style for this family, ie. an unnamed style providing
defaults for some style properties.
|
public OfficeStyleFamily(java.lang.Class styleClass)
styleClass
- the subclass of OfficeStyle used to represent styles
in this familypublic void setDefaultStyle(OfficeStyle style)
style
- the new default stylepublic OfficeStyle getDefaultStyle()
public OfficeStyle getStyle(java.lang.String sName)
sName
- the name of the stylepublic OfficeStyle getStyleByDisplayName(java.lang.String sDisplayName)
sDisplayName
- the display name of the stylepublic java.lang.String getDisplayName(java.lang.String sName)
sName
- the style namepublic java.util.Enumeration<java.lang.Object> getStylesEnumeration()
public void loadStyleFromDOM(org.w3c.dom.Node node, boolean bAutomatic)
node
- the style:... node representing the stylebAutomatic
- if true, the style is an automatic style