LibreOffice Module xmerge (master) 1
|
Represents a text Style
in an OpenOffice document.
More...
Public Member Functions | |
RowStyle (Node node, StyleCatalog sc) | |
Constructor for use when going from DOM to client device format. More... | |
RowStyle (String name, String family, String parent, int rowHeight, StyleCatalog sc) | |
Constructor for use when going from client device format to DOM. More... | |
int | getRowHeight () |
Returns the height of this row. More... | |
Style | getResolved () |
Return a Style object corresponding to this one, but with all of the inherited information from parent Style objects filled in. More... | |
Node | createNode (org.w3c.dom.Document parentDoc, String name) |
Create a new Node in the Document , and write this Style to it. More... | |
boolean | isSubset (Style style) |
Return true if style specifies as much or less than this Style , and nothing it specifies contradicts this Style . More... | |
Public Member Functions inherited from org.openoffice.xmerge.converter.xml.Style | |
Style (Node node, StyleCatalog sc) | |
Constructor for use when going from DOM to client device format. More... | |
Style (String name, String family, String parent, StyleCatalog sc) | |
Constructor for use when going from client device format to DOM. More... | |
void | setCatalog (StyleCatalog sc) |
Set the StyleCatalog to be used when looking up the Style parent. More... | |
String | getName () |
Returns the name of this Style . More... | |
void | setName (String newName) |
Sets the name of this Style . More... | |
String | getFamily () |
Return the family of this Style . More... | |
String | getParent () |
Return the name of the parent of this Style . More... | |
Style | getResolved () |
Return a Style object corresponding to this one, but with all of the inherited information from parent Style objects filled in. More... | |
Node | createNode (org.w3c.dom.Document parentDoc, String name) |
Write a Node in parentDoc representing this Style . More... | |
boolean | isSubset (Style style) |
Return true if Style is a subset of this one. More... | |
Private Member Functions | |
void | setRowHeight (int RowHeight) |
Sets the height of this row. More... | |
int | parseRowHeight (String value) |
Parse a rowheight in the form "1.234cm" to twips. More... | |
void | handleAttribute (String attr, String value) |
Set an attribute. More... | |
void | writeAttributes (Element node) |
Write this Style object's attributes to a Node in the Document . More... | |
Private Attributes | |
int | rowHeight = 255 |
Additional Inherited Members | |
Protected Attributes inherited from org.openoffice.xmerge.converter.xml.Style | |
String | name = null |
Name of the Style . More... | |
String | family = null |
Family of the Style . More... | |
String | parent = null |
Parent of the Style . More... | |
StyleCatalog | sc |
A reference to the StyleCatalog to be used for looking up ancestor Style objects. More... | |
Represents a text Style
in an OpenOffice document.
Definition at line 34 of file RowStyle.java.
|
inline |
Constructor for use when going from DOM to client device format.
node | The style:style Node containing the Style . (This Node is assumed have a family attribute of text). |
sc | The StyleCatalog , which is used for looking up ancestor Style objects. |
Definition at line 46 of file RowStyle.java.
References org.openoffice.xmerge.converter.xml.sxc.RowStyle.handleAttribute(), i, and String.
Referenced by org.openoffice.xmerge.converter.xml.sxc.RowStyle.getResolved(), and org.openoffice.xmerge.converter.xml.sxc.RowStyle.isSubset().
|
inline |
Constructor for use when going from client device format to DOM.
name | Name of text Style . Can be null . |
family | Family of text Style (usually text). Can be null . |
parent | Name of parent text Style , or null for none. |
rowHeight | The height of this row. |
sc | The StyleCatalog , which is used for looking up ancestor Style objects. |
Definition at line 97 of file RowStyle.java.
References org.openoffice.xmerge.converter.xml.Style.family, org.openoffice.xmerge.converter.xml.Style.name, org.openoffice.xmerge.converter.xml.Style.parent, and org.openoffice.xmerge.converter.xml.sxc.RowStyle.rowHeight.
|
inline |
Create a new Node
in the Document
, and write this Style
to it.
parentDoc | Parent Document of the Node to create. |
name | Name to use for the new Node (e.g. style:style) |
Node
. Definition at line 207 of file RowStyle.java.
References org.openoffice.xmerge.converter.xml.Style.name, and org.openoffice.xmerge.converter.xml.sxc.RowStyle.writeAttributes().
|
inline |
Return a Style
object corresponding to this one, but with all of the inherited information from parent Style
objects filled in.
The object returned will be a new object, not a reference to this object, even if it does not need any information added.
StyleCatalog
in which to look up ancestors. Reimplemented from org.openoffice.xmerge.converter.xml.Style.
Definition at line 157 of file RowStyle.java.
References clone(), org.openoffice.xmerge.util.Debug.ERROR, Exception, org.openoffice.xmerge.converter.xml.Style.family, org.openoffice.xmerge.converter.xml.sxc.RowStyle.getResolved(), org.openoffice.xmerge.converter.xml.sxc.RowStyle.getRowHeight(), org.openoffice.xmerge.util.Debug.log(), org.openoffice.xmerge.converter.xml.Style.name, org.openoffice.xmerge.converter.xml.Style.parent, org.openoffice.xmerge.converter.xml.sxc.RowStyle.rowHeight, org.openoffice.xmerge.converter.xml.sxc.RowStyle.RowStyle(), and org.openoffice.xmerge.converter.xml.sxc.RowStyle.setRowHeight().
Referenced by org.openoffice.xmerge.converter.xml.sxc.RowStyle.getResolved().
|
inline |
Returns the height of this row.
Definition at line 107 of file RowStyle.java.
References org.openoffice.xmerge.converter.xml.sxc.RowStyle.rowHeight.
Referenced by org.openoffice.xmerge.converter.xml.sxc.RowStyle.getResolved(), org.openoffice.xmerge.converter.xml.sxc.RowStyle.isSubset(), and org.openoffice.xmerge.converter.xml.sxc.SxcDocumentSerializer.traverseTableRow().
|
inlineprivate |
Set an attribute.
attr | The attribute to set. |
value | The attribute value to set. |
Definition at line 137 of file RowStyle.java.
References org.openoffice.xmerge.util.Debug.INFO, org.openoffice.xmerge.util.Debug.log(), org.openoffice.xmerge.converter.xml.sxc.RowStyle.parseRowHeight(), org.openoffice.xmerge.converter.xml.sxc.RowStyle.rowHeight, and value.
Referenced by org.openoffice.xmerge.converter.xml.sxc.RowStyle.RowStyle().
|
inline |
Return true if style
specifies as much or less than this Style
, and nothing it specifies contradicts this Style
.
style | The Style to check. |
true
if style
is a subset, false
otherwise. Reimplemented from org.openoffice.xmerge.converter.xml.Style.
Definition at line 223 of file RowStyle.java.
References org.openoffice.xmerge.converter.xml.sxc.RowStyle.getRowHeight(), org.openoffice.xmerge.converter.xml.sxc.RowStyle.rowHeight, and org.openoffice.xmerge.converter.xml.sxc.RowStyle.RowStyle().
|
inlineprivate |
Parse a rowheight in the form "1.234cm" to twips.
value | String specification to parse. |
Definition at line 127 of file RowStyle.java.
References org.openoffice.xmerge.util.TwipsConverter.convert2twips(), and value.
Referenced by org.openoffice.xmerge.converter.xml.sxc.RowStyle.handleAttribute().
|
inlineprivate |
Sets the height of this row.
RowHeight | The height of this row. |
Definition at line 116 of file RowStyle.java.
Referenced by org.openoffice.xmerge.converter.xml.sxc.RowStyle.getResolved().
|
inlineprivate |
Write this Style
object's attributes to a Node
in the Document
.
node | The Node to add Style attributes. |
Definition at line 237 of file RowStyle.java.
References org.openoffice.xmerge.converter.xml.sxc.RowStyle.rowHeight, String, and org.openoffice.xmerge.util.TwipsConverter.twips2cm().
Referenced by org.openoffice.xmerge.converter.xml.sxc.RowStyle.createNode().
|
private |
Definition at line 36 of file RowStyle.java.
Referenced by org.openoffice.xmerge.converter.xml.sxc.RowStyle.getResolved(), org.openoffice.xmerge.converter.xml.sxc.RowStyle.getRowHeight(), org.openoffice.xmerge.converter.xml.sxc.RowStyle.handleAttribute(), org.openoffice.xmerge.converter.xml.sxc.RowStyle.isSubset(), org.openoffice.xmerge.converter.xml.sxc.RowStyle.RowStyle(), and org.openoffice.xmerge.converter.xml.sxc.RowStyle.writeAttributes().