CellStyle cs = cell.getCellStyle();
final Color srcColor = cs.getFillForegroundColorColor();
if (Objects.equals(srcColor, bsColor)) {
continue;
}
CellStyle newCellStyle = book.createCellStyle();
newCellStyle.cloneStyleFrom(cs);
//bug#ZSS-34: cell background color does not show in excel
//20110819, henrichen@zkoss.org: set color to a cell shall change its fillPattern to "solid" automatically
final short patternType = cs.getFillPattern();