/** * Get the fill pattern * @return fill pattern, default value is {@link org.apache.poi.ss.usermodel.CellStyle#NO_FILL} * * @see org.apache.poi.ss.usermodel.CellStyle#NO_FILL * @see org.apache.poi.ss.usermodel.CellStyle#SOLID_FOREGROUND * @see org.apache.poi.ss.usermodel.CellStyle#FINE_DOTS * @see org.apache.poi.ss.usermodel.CellStyle#ALT_BARS * @see org.apache.poi.ss.usermodel.CellStyle#SPARSE_DOTS * @see org.apache.poi.ss.usermodel.CellStyle#THICK_HORZ_BANDS * @see org.apache.poi.ss.usermodel.CellStyle#THICK_VERT_BANDS * @see org.apache.poi.ss.usermodel.CellStyle#THICK_BACKWARD_DIAG * @see org.apache.poi.ss.usermodel.CellStyle#THICK_FORWARD_DIAG * @see org.apache.poi.ss.usermodel.CellStyle#BIG_SPOTS * @see org.apache.poi.ss.usermodel.CellStyle#BRICKS * @see org.apache.poi.ss.usermodel.CellStyle#THIN_HORZ_BANDS * @see org.apache.poi.ss.usermodel.CellStyle#THIN_VERT_BANDS * @see org.apache.poi.ss.usermodel.CellStyle#THIN_BACKWARD_DIAG * @see org.apache.poi.ss.usermodel.CellStyle#THIN_FORWARD_DIAG * @see org.apache.poi.ss.usermodel.CellStyle#SQUARES * @see org.apache.poi.ss.usermodel.CellStyle#DIAMONDS */ public short getFillPattern() { if(!_cellXf.getApplyFill()) return 0; int fillIndex = (int)_cellXf.getFillId(); XSSFCellFill fill = _stylesSource.getFillAt(fillIndex); STPatternType.Enum ptrn = fill.getPatternType(); if(ptrn == null) return CellStyle.NO_FILL; return (short)(ptrn.intValue() - 1); }
public short getFillPattern(){ if(!_fill.isSetPatternFill() || !_fill.getPatternFill().isSetPatternType()) return NO_FILL; return (short)(_fill.getPatternFill().getPatternType().intValue() - 1); }
public short getFillPattern() { if(!_fill.isSetPatternFill() || !_fill.getPatternFill().isSetPatternType()) return NO_FILL; return (short)(_fill.getPatternFill().getPatternType().intValue() - 1); }
@Override public FillPatternType getFillPattern() { // bug 56295: handle missing applyFill attribute as "true" because Excel does as well if(_cellXf.isSetApplyFill() && !_cellXf.getApplyFill()) return FillPatternType.NO_FILL; int fillIndex = (int)_cellXf.getFillId(); XSSFCellFill fill = _stylesSource.getFillAt(fillIndex); STPatternType.Enum ptrn = fill.getPatternType(); if(ptrn == null) return FillPatternType.NO_FILL; return FillPatternType.forInt(ptrn.intValue() - 1); }
public short getFillPattern() { if(!_fill.isSetPatternFill() || !_fill.getPatternFill().isSetPatternType()) return NO_FILL; return (short)(_fill.getPatternFill().getPatternType().intValue() - 1); }
@Override public FillPatternType getFillPattern() { // bug 56295: handle missing applyFill attribute as "true" because Excel does as well if(_cellXf.isSetApplyFill() && !_cellXf.getApplyFill()) return FillPatternType.NO_FILL; int fillIndex = (int)_cellXf.getFillId(); XSSFCellFill fill = _stylesSource.getFillAt(fillIndex); STPatternType.Enum ptrn = fill.getPatternType(); if(ptrn == null) return FillPatternType.NO_FILL; return FillPatternType.forInt(ptrn.intValue() - 1); }