return calculator.getResult();
}
protected CSSNumericValue computeRowHeight(final String rowStyle)
{
final OfficeStylesCollection contentStyles = getContentStylesCollection();
final OfficeStyle style = contentStyles.getStyle(OfficeToken.TABLE_ROW, rowStyle);
if (style != null)
{
final Element element = style.getTableRowProperties();
if (element != null)
{
final String height = (String) element.getAttribute(OfficeNamespaces.STYLE_NS, "row-height");
if (height != null)
{
return parseLength(height);
}
}
final String styleParent = style.getStyleParent();
if (styleParent != null)
{
return computeRowHeight(styleParent);
}
}
final OfficeStylesCollection globalStyles = getGlobalStylesCollection();
final OfficeStyle globalStyle = globalStyles.getStyle(OfficeToken.TABLE_ROW, rowStyle);
if (globalStyle != null)
{
final Element element = globalStyle.getTableRowProperties();
if (element != null)
{
final String height = (String) element.getAttribute(OfficeNamespaces.STYLE_NS, "row-height");
if (height != null)
{
return parseLength(height);
}
}
final String styleParent = globalStyle.getStyleParent();
if (styleParent != null)
{
return computeRowHeight(styleParent);
}
}
final OfficeStylesCollection predefStyles = getPredefinedStylesCollection();
final OfficeStyle predefStyle = predefStyles.getStyle(OfficeToken.TABLE_ROW, rowStyle);
if (predefStyle != null)
{
final Element element = predefStyle.getTableRowProperties();
if (element != null)
{