summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--xmerge/source/xmerge/java/org/openoffice/xmerge/converter/xml/sxc/SxcDocumentSerializer.java6
1 files changed, 5 insertions, 1 deletions
diff --git a/xmerge/source/xmerge/java/org/openoffice/xmerge/converter/xml/sxc/SxcDocumentSerializer.java b/xmerge/source/xmerge/java/org/openoffice/xmerge/converter/xml/sxc/SxcDocumentSerializer.java
index 2604bf706c08..4c573a7b6ef4 100644
--- a/xmerge/source/xmerge/java/org/openoffice/xmerge/converter/xml/sxc/SxcDocumentSerializer.java
+++ b/xmerge/source/xmerge/java/org/openoffice/xmerge/converter/xml/sxc/SxcDocumentSerializer.java
@@ -537,16 +537,20 @@ public abstract class SxcDocumentSerializer implements OfficeConstants,
styleName = tableStyleNode.getNodeValue();
}
+ CellStyle cStyle = null;
+
if(styleName.equalsIgnoreCase("Default")) {
Debug.log(Debug.TRACE, "No defined Style Attribute was found");
} else if(styleName.length()!=0) {
- CellStyle cStyle = (CellStyle)styleCat.lookup(styleName,
+ cStyle = (CellStyle)styleCat.lookup(styleName,
SxcConstants.TABLE_CELL_STYLE_FAMILY, null,
CellStyle.class);
+ }
+ if (cStyle != null) {
Format definedFormat = cStyle.getFormat();
fmt = new Format(definedFormat);
}