java.lang.ObjectHigh level representation of the style of a cell in a sheet of a workbook.org.apache.poi.hssf.usermodel.HSSFCellStyle
1.0-pre - Andrew - C. Oliver (acoliver at apache dot org)Jason - Height (jheight at chariot dot net dot au)| Field Summary | ||
|---|---|---|
| public static final short | ALIGN_GENERAL | general (normal) horizontal alignment |
| public static final short | ALIGN_LEFT | left-justified horizontal alignment |
| public static final short | ALIGN_CENTER | center horizontal alignment |
| public static final short | ALIGN_RIGHT | right-justified horizontal alignment |
| public static final short | ALIGN_FILL | fill? horizontal alignment |
| public static final short | ALIGN_JUSTIFY | justified horizontal alignment |
| public static final short | ALIGN_CENTER_SELECTION | center-selection? horizontal alignment |
| public static final short | VERTICAL_TOP | top-aligned vertical alignment |
| public static final short | VERTICAL_CENTER | center-aligned vertical alignment |
| public static final short | VERTICAL_BOTTOM | bottom-aligned vertical alignment |
| public static final short | VERTICAL_JUSTIFY | vertically justified vertical alignment |
| public static final short | BORDER_NONE | No border |
| public static final short | BORDER_THIN | Thin border |
| public static final short | BORDER_MEDIUM | Medium border |
| public static final short | BORDER_DASHED | dash border |
| public static final short | BORDER_HAIR | dot border |
| public static final short | BORDER_THICK | Thick border |
| public static final short | BORDER_DOUBLE | double-line border |
| public static final short | BORDER_DOTTED | hair-line border |
| public static final short | BORDER_MEDIUM_DASHED | Medium dashed border |
| public static final short | BORDER_DASH_DOT | dash-dot border |
| public static final short | BORDER_MEDIUM_DASH_DOT | medium dash-dot border |
| public static final short | BORDER_DASH_DOT_DOT | dash-dot-dot border |
| public static final short | BORDER_MEDIUM_DASH_DOT_DOT | medium dash-dot-dot border |
| public static final short | BORDER_SLANTED_DASH_DOT | slanted dash-dot border |
| public static final short | NO_FILL | No background |
| public static final short | SOLID_FOREGROUND | Solidly filled |
| public static final short | FINE_DOTS | Small fine dots |
| public static final short | ALT_BARS | Wide dots |
| public static final short | SPARSE_DOTS | Sparse dots |
| public static final short | THICK_HORZ_BANDS | Thick horizontal bands |
| public static final short | THICK_VERT_BANDS | Thick vertical bands |
| public static final short | THICK_BACKWARD_DIAG | Thick backward facing diagonals |
| public static final short | THICK_FORWARD_DIAG | Thick forward facing diagonals |
| public static final short | BIG_SPOTS | Large spots |
| public static final short | BRICKS | Brick-like layout |
| public static final short | THIN_HORZ_BANDS | Thin horizontal bands |
| public static final short | THIN_VERT_BANDS | Thin vertical bands |
| public static final short | THIN_BACKWARD_DIAG | Thin backward diagonal |
| public static final short | THIN_FORWARD_DIAG | Thin forward diagonal |
| public static final short | SQUARES | Squares |
| public static final short | DIAMONDS | Diamonds |
| public static final short | LESS_DOTS | Less Dots |
| public static final short | LEAST_DOTS | Least Dots |
| Constructor: |
|---|
|
|
| Methods from java.lang.Object: |
|---|
| equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method from org.apache.poi.hssf.usermodel.HSSFCellStyle Detail: |
|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
For example: cs.setFillPattern(HSSFCellStyle.FINE_DOTS ); cs.setFillBackgroundColor(new HSSFColor.RED().getIndex());optionally a Foreground and background fill can be applied: Note: Ensure Foreground color is set prior to background cs.setFillPattern(HSSFCellStyle.FINE_DOTS ); cs.setFillForegroundColor(new HSSFColor.BLUE().getIndex()); cs.setFillBackgroundColor(new HSSFColor.RED().getIndex());or, for the special case of SOLID_FILL: cs.setFillPattern(HSSFCellStyle.SOLID_FOREGROUND ); cs.setFillForegroundColor(new HSSFColor.RED().getIndex());It is necessary to set the fill style in order for the color to be shown in the cell. |
|
|
|
|
|
|
|
|
|
|
|
|