if (getShade() == 1) { //TODO: change to constant when upgrade to new HSSF
//solid w/foreground, bg doesn't matter
getLogger().debug("shade = 1");
HSSFColor color = (HSSFColor) colorhash.get(getBackgroundColor().toString());
if (color == null) {
getLogger().debug("s1 BG couldn't find color for "+ getBackgroundColor().toString());
color = new HSSFColor.WHITE();
}
style.setFillForegroundColor(color.getIndex());
color = (HSSFColor) colorhash.get(getPatternColor().toString());
if (color == null) {
getLogger().debug("s1 PC couldn't find color for "+ getPatternColor().toString());
color = new HSSFColor.BLACK();
}
style.setFillBackgroundColor(color.getIndex());
} else {
HSSFColor color = (HSSFColor) colorhash.get(getBackgroundColor().toString());
if (color == null) {
getLogger().debug("BG couldn't find color for "+ getBackgroundColor().toString());
color = new HSSFColor.BLACK();
}
style.setFillBackgroundColor(color.getIndex());
color = (HSSFColor) colorhash.get(getPatternColor().toString());
if (color == null) {
getLogger().debug("PC couldn't find color for "+ getPatternColor().toString());
color = new HSSFColor.WHITE();
}
style.setFillForegroundColor(color.getIndex());
}
style.setWrapText(getWrapText());
style.setLocked(true);
String format = null;