Skip to content

Commit 80eab26

Browse files
committed
DP-5502 - Add "underline" support to ExcelFont
1 parent 90aec9b commit 80eab26

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/main/java/com/northconcepts/datapipeline/examples/cookbook/WriteExcelFormattingAndStyles.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,13 @@ public static void main(String[] args) {
2626
writer.addHeaderCellStyle(FieldLocationPredicate.all(), ExcelCellStyleDecorator.bold()
2727
.and(ExcelCellStyleDecorator.backgroundColor(ExcelColorPalette.DARK_YELLOW))
2828
.and(ExcelCellStyleDecorator.fontColor(ExcelColorPalette.LIGHT_GREEN))
29+
.and(ExcelCellStyleDecorator.underline())
2930
);
3031

3132
// Add Formatting & Cell Style for Data
3233
writer.addDataCellStyle(FieldLocationPredicate.negativeNumber(), ExcelCellStyleDecorator.fontColor(ExcelColorPalette.RED)
33-
.and(ExcelCellStyleDecorator.italic()));
34+
.and(ExcelCellStyleDecorator.italic())
35+
.and(ExcelCellStyleDecorator.underline()));
3436
writer.addDataCellStyle(FieldLocationPredicate.evenRowIndex(), ExcelCellStyleDecorator.backgroundColor(ExcelColorPalette.GREY_25_PERCENT));
3537

3638
Job.run(reader, writer);

0 commit comments

Comments
 (0)