Java Doc for HSSFCellStyle.java in  » Collaboration » poi-3.0.2-beta2 » org » apache » poi » hssf » usermodel » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Collaboration » poi 3.0.2 beta2 » org.apache.poi.hssf.usermodel 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.apache.poi.hssf.usermodel.HSSFCellStyle

HSSFCellStyle
public class HSSFCellStyle (Code)
High level representation of the style of a cell in a sheet of a workbook.
version:
   1.0-pre
author:
   Andrew C. Oliver (acoliver at apache dot org)
author:
   Jason Height (jheight at chariot dot net dot au)
See Also:   org.apache.poi.hssf.usermodel.HSSFWorkbook.createCellStyle
See Also:   org.apache.poi.hssf.usermodel.HSSFWorkbook.getCellStyleAt(short)
See Also:   org.apache.poi.hssf.usermodel.HSSFCell.setCellStyle(HSSFCellStyle)


Field Summary
final public static  shortALIGN_CENTER
    
final public static  shortALIGN_CENTER_SELECTION
    
final public static  shortALIGN_FILL
    
final public static  shortALIGN_GENERAL
    
final public static  shortALIGN_JUSTIFY
    
final public static  shortALIGN_LEFT
    
final public static  shortALIGN_RIGHT
    
final public static  shortALT_BARS
    
final public static  shortBIG_SPOTS
    
final public static  shortBORDER_DASHED
    
final public static  shortBORDER_DASH_DOT
    
final public static  shortBORDER_DASH_DOT_DOT
    
final public static  shortBORDER_DOTTED
    
final public static  shortBORDER_DOUBLE
    
final public static  shortBORDER_HAIR
    
final public static  shortBORDER_MEDIUM
    
final public static  shortBORDER_MEDIUM_DASHED
    
final public static  shortBORDER_MEDIUM_DASH_DOT
    
final public static  shortBORDER_MEDIUM_DASH_DOT_DOT
    
final public static  shortBORDER_NONE
    
final public static  shortBORDER_SLANTED_DASH_DOT
    
final public static  shortBORDER_THICK
    
final public static  shortBORDER_THIN
    
final public static  shortBRICKS
    
final public static  shortDIAMONDS
    
final public static  shortFINE_DOTS
    
final public static  shortLEAST_DOTS
    
final public static  shortLESS_DOTS
    
final public static  shortNO_FILL
    
final public static  shortSOLID_FOREGROUND
    
final public static  shortSPARSE_DOTS
    
final public static  shortSQUARES
    
final public static  shortTHICK_BACKWARD_DIAG
    
final public static  shortTHICK_FORWARD_DIAG
    
final public static  shortTHICK_HORZ_BANDS
    
final public static  shortTHICK_VERT_BANDS
    
final public static  shortTHIN_BACKWARD_DIAG
    
final public static  shortTHIN_FORWARD_DIAG
    
final public static  shortTHIN_HORZ_BANDS
    
final public static  shortTHIN_VERT_BANDS
    
final public static  shortVERTICAL_BOTTOM
    
final public static  shortVERTICAL_CENTER
    
final public static  shortVERTICAL_JUSTIFY
    
final public static  shortVERTICAL_TOP
    

Constructor Summary
protected  HSSFCellStyle(short index, ExtendedFormatRecord rec)
    

Method Summary
public  shortgetAlignment()
    
public  shortgetBorderBottom()
    
public  shortgetBorderLeft()
    
public  shortgetBorderRight()
    
public  shortgetBorderTop()
    
public  shortgetBottomBorderColor()
    
public  shortgetDataFormat()
    
public  StringgetDataFormatString(Workbook workbook)
    
public  shortgetFillBackgroundColor()
    
public  shortgetFillForegroundColor()
    
public  shortgetFillPattern()
    
public  HSSFFontgetFont(HSSFWorkbook parentWorkbook)
    
public  shortgetFontIndex()
    
public  booleangetHidden()
    
public  shortgetIndention()
    
public  shortgetIndex()
    
public  shortgetLeftBorderColor()
    
public  booleangetLocked()
    
public  shortgetRightBorderColor()
    
public  shortgetRotation()
    
public  shortgetTopBorderColor()
    
public  shortgetVerticalAlignment()
    
public  booleangetWrapText()
    
public  voidsetAlignment(short align)
    
public  voidsetBorderBottom(short border)
    
public  voidsetBorderLeft(short border)
    
public  voidsetBorderRight(short border)
    
public  voidsetBorderTop(short border)
    
public  voidsetBottomBorderColor(short color)
    
public  voidsetDataFormat(short fmt)
    
public  voidsetFillBackgroundColor(short bg)
     set the background fill color.
public  voidsetFillForegroundColor(short bg)
    
public  voidsetFillPattern(short fp)
     setting to one fills the cell with the foreground color...
public  voidsetFont(HSSFFont font)
    
public  voidsetHidden(boolean hidden)
    
public  voidsetIndention(short indent)
    
public  voidsetLeftBorderColor(short color)
    
public  voidsetLocked(boolean locked)
    
public  voidsetRightBorderColor(short color)
    
public  voidsetRotation(short rotation)
    
public  voidsetTopBorderColor(short color)
    
public  voidsetVerticalAlignment(short align)
    
public  voidsetWrapText(boolean wrapped)
    

Field Detail
ALIGN_CENTER
final public static short ALIGN_CENTER(Code)
center horizontal alignment



ALIGN_CENTER_SELECTION
final public static short ALIGN_CENTER_SELECTION(Code)
center-selection? horizontal alignment



ALIGN_FILL
final public static short ALIGN_FILL(Code)
fill? horizontal alignment



ALIGN_GENERAL
final public static short ALIGN_GENERAL(Code)
general (normal) horizontal alignment



ALIGN_JUSTIFY
final public static short ALIGN_JUSTIFY(Code)
justified horizontal alignment



ALIGN_LEFT
final public static short ALIGN_LEFT(Code)
left-justified horizontal alignment



ALIGN_RIGHT
final public static short ALIGN_RIGHT(Code)
right-justified horizontal alignment



ALT_BARS
final public static short ALT_BARS(Code)
Wide dots



BIG_SPOTS
final public static short BIG_SPOTS(Code)
Large spots



BORDER_DASHED
final public static short BORDER_DASHED(Code)
dash border



BORDER_DASH_DOT
final public static short BORDER_DASH_DOT(Code)
dash-dot border



BORDER_DASH_DOT_DOT
final public static short BORDER_DASH_DOT_DOT(Code)
dash-dot-dot border



BORDER_DOTTED
final public static short BORDER_DOTTED(Code)
hair-line border



BORDER_DOUBLE
final public static short BORDER_DOUBLE(Code)
double-line border



BORDER_HAIR
final public static short BORDER_HAIR(Code)
dot border



BORDER_MEDIUM
final public static short BORDER_MEDIUM(Code)
Medium border



BORDER_MEDIUM_DASHED
final public static short BORDER_MEDIUM_DASHED(Code)
Medium dashed border



BORDER_MEDIUM_DASH_DOT
final public static short BORDER_MEDIUM_DASH_DOT(Code)
medium dash-dot border



BORDER_MEDIUM_DASH_DOT_DOT
final public static short BORDER_MEDIUM_DASH_DOT_DOT(Code)
medium dash-dot-dot border



BORDER_NONE
final public static short BORDER_NONE(Code)
No border



BORDER_SLANTED_DASH_DOT
final public static short BORDER_SLANTED_DASH_DOT(Code)
slanted dash-dot border



BORDER_THICK
final public static short BORDER_THICK(Code)
Thick border



BORDER_THIN
final public static short BORDER_THIN(Code)
Thin border



BRICKS
final public static short BRICKS(Code)
Brick-like layout



DIAMONDS
final public static short DIAMONDS(Code)
Diamonds



FINE_DOTS
final public static short FINE_DOTS(Code)
Small fine dots



LEAST_DOTS
final public static short LEAST_DOTS(Code)
Least Dots



LESS_DOTS
final public static short LESS_DOTS(Code)
Less Dots



NO_FILL
final public static short NO_FILL(Code)
No background



SOLID_FOREGROUND
final public static short SOLID_FOREGROUND(Code)
Solidly filled



SPARSE_DOTS
final public static short SPARSE_DOTS(Code)
Sparse dots



SQUARES
final public static short SQUARES(Code)
Squares



THICK_BACKWARD_DIAG
final public static short THICK_BACKWARD_DIAG(Code)
Thick backward facing diagonals



THICK_FORWARD_DIAG
final public static short THICK_FORWARD_DIAG(Code)
Thick forward facing diagonals



THICK_HORZ_BANDS
final public static short THICK_HORZ_BANDS(Code)
Thick horizontal bands



THICK_VERT_BANDS
final public static short THICK_VERT_BANDS(Code)
Thick vertical bands



THIN_BACKWARD_DIAG
final public static short THIN_BACKWARD_DIAG(Code)
Thin backward diagonal



THIN_FORWARD_DIAG
final public static short THIN_FORWARD_DIAG(Code)
Thin forward diagonal



THIN_HORZ_BANDS
final public static short THIN_HORZ_BANDS(Code)
Thin horizontal bands



THIN_VERT_BANDS
final public static short THIN_VERT_BANDS(Code)
Thin vertical bands



VERTICAL_BOTTOM
final public static short VERTICAL_BOTTOM(Code)
bottom-aligned vertical alignment



VERTICAL_CENTER
final public static short VERTICAL_CENTER(Code)
center-aligned vertical alignment



VERTICAL_JUSTIFY
final public static short VERTICAL_JUSTIFY(Code)
vertically justified vertical alignment



VERTICAL_TOP
final public static short VERTICAL_TOP(Code)
top-aligned vertical alignment




Constructor Detail
HSSFCellStyle
protected HSSFCellStyle(short index, ExtendedFormatRecord rec)(Code)
Creates new HSSFCellStyle why would you want to do this??




Method Detail
getAlignment
public short getAlignment()(Code)
get the type of horizontal alignment for the cell align - the type of alignment
See Also:   HSSFCellStyle.ALIGN_GENERAL
See Also:   HSSFCellStyle.ALIGN_LEFT
See Also:   HSSFCellStyle.ALIGN_CENTER
See Also:   HSSFCellStyle.ALIGN_RIGHT
See Also:   HSSFCellStyle.ALIGN_FILL
See Also:   HSSFCellStyle.ALIGN_JUSTIFY
See Also:   HSSFCellStyle.ALIGN_CENTER_SELECTION



getBorderBottom
public short getBorderBottom()(Code)
get the type of border to use for the bottom border of the cell border type
See Also:   HSSFCellStyle.BORDER_NONE
See Also:   HSSFCellStyle.BORDER_THIN
See Also:   HSSFCellStyle.BORDER_MEDIUM
See Also:   HSSFCellStyle.BORDER_DASHED
See Also:   HSSFCellStyle.BORDER_DOTTED
See Also:   HSSFCellStyle.BORDER_THICK
See Also:   HSSFCellStyle.BORDER_DOUBLE
See Also:   HSSFCellStyle.BORDER_HAIR
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASHED
See Also:   HSSFCellStyle.BORDER_DASH_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT
See Also:   HSSFCellStyle.BORDER_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_SLANTED_DASH_DOT



getBorderLeft
public short getBorderLeft()(Code)
get the type of border to use for the left border of the cell border type
See Also:   HSSFCellStyle.BORDER_NONE
See Also:   HSSFCellStyle.BORDER_THIN
See Also:   HSSFCellStyle.BORDER_MEDIUM
See Also:   HSSFCellStyle.BORDER_DASHED
See Also:   HSSFCellStyle.BORDER_DOTTED
See Also:   HSSFCellStyle.BORDER_THICK
See Also:   HSSFCellStyle.BORDER_DOUBLE
See Also:   HSSFCellStyle.BORDER_HAIR
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASHED
See Also:   HSSFCellStyle.BORDER_DASH_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT
See Also:   HSSFCellStyle.BORDER_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_SLANTED_DASH_DOT



getBorderRight
public short getBorderRight()(Code)
get the type of border to use for the right border of the cell border type
See Also:   HSSFCellStyle.BORDER_NONE
See Also:   HSSFCellStyle.BORDER_THIN
See Also:   HSSFCellStyle.BORDER_MEDIUM
See Also:   HSSFCellStyle.BORDER_DASHED
See Also:   HSSFCellStyle.BORDER_DOTTED
See Also:   HSSFCellStyle.BORDER_THICK
See Also:   HSSFCellStyle.BORDER_DOUBLE
See Also:   HSSFCellStyle.BORDER_HAIR
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASHED
See Also:   HSSFCellStyle.BORDER_DASH_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT
See Also:   HSSFCellStyle.BORDER_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_SLANTED_DASH_DOT



getBorderTop
public short getBorderTop()(Code)
get the type of border to use for the top border of the cell border type
See Also:   HSSFCellStyle.BORDER_NONE
See Also:   HSSFCellStyle.BORDER_THIN
See Also:   HSSFCellStyle.BORDER_MEDIUM
See Also:   HSSFCellStyle.BORDER_DASHED
See Also:   HSSFCellStyle.BORDER_DOTTED
See Also:   HSSFCellStyle.BORDER_THICK
See Also:   HSSFCellStyle.BORDER_DOUBLE
See Also:   HSSFCellStyle.BORDER_HAIR
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASHED
See Also:   HSSFCellStyle.BORDER_DASH_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT
See Also:   HSSFCellStyle.BORDER_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_SLANTED_DASH_DOT



getBottomBorderColor
public short getBottomBorderColor()(Code)
get the color to use for the left border
See Also:   org.apache.poi.hssf.usermodel.HSSFPalette.getColor(short)
Parameters:
  color - The index of the color definition



getDataFormat
public short getDataFormat()(Code)
get the index of the format
See Also:   org.apache.poi.hssf.usermodel.HSSFDataFormat



getDataFormatString
public String getDataFormatString(Workbook workbook)(Code)
Get the contents of the format string, by looking up the DataFormat against the supplied workbook
See Also:   org.apache.poi.hssf.usermodel.HSSFDataFormat



getFillBackgroundColor
public short getFillBackgroundColor()(Code)
get the background fill color
See Also:   org.apache.poi.hssf.usermodel.HSSFPalette.getColor(short) fill color



getFillForegroundColor
public short getFillForegroundColor()(Code)
get the foreground fill color
See Also:   org.apache.poi.hssf.usermodel.HSSFPalette.getColor(short) fill color



getFillPattern
public short getFillPattern()(Code)
get the fill pattern (??) - set to 1 to fill with foreground color fill pattern



getFont
public HSSFFont getFont(HSSFWorkbook parentWorkbook)(Code)
gets the font for this style
Parameters:
  parentWorkbook - The HSSFWorkbook that this style belongs to
See Also:   org.apache.poi.hssf.usermodel.HSSFCellStyle.getFontIndex
See Also:   org.apache.poi.hssf.usermodel.HSSFWorkbook.getFontAt(short)



getFontIndex
public short getFontIndex()(Code)
gets the index of the font for this style
See Also:   org.apache.poi.hssf.usermodel.HSSFWorkbook.getFontAt(short)



getHidden
public boolean getHidden()(Code)
get whether the cell's using this style are to be hidden hidden - whether the cell using this style should be hidden



getIndention
public short getIndention()(Code)
get the number of spaces to indent the text in the cell indent - number of spaces



getIndex
public short getIndex()(Code)
get the index within the HSSFWorkbook (sequence within the collection of ExtnededFormat objects) unique index number of the underlying record this style represents (probably you don't careunless you're comparing which one is which)



getLeftBorderColor
public short getLeftBorderColor()(Code)
get the color to use for the left border
See Also:   org.apache.poi.hssf.usermodel.HSSFPalette.getColor(short)
Parameters:
  color - The index of the color definition



getLocked
public boolean getLocked()(Code)
get whether the cell's using this style are to be locked hidden - whether the cell using this style should be locked



getRightBorderColor
public short getRightBorderColor()(Code)
get the color to use for the left border
See Also:   org.apache.poi.hssf.usermodel.HSSFPalette.getColor(short)
Parameters:
  color - The index of the color definition



getRotation
public short getRotation()(Code)
get the degree of rotation for the text in the cell rotation degrees (between -90 and 90 degrees)



getTopBorderColor
public short getTopBorderColor()(Code)
get the color to use for the top border
See Also:   org.apache.poi.hssf.usermodel.HSSFPalette.getColor(short)
Parameters:
  color - The index of the color definition



getVerticalAlignment
public short getVerticalAlignment()(Code)
get the type of vertical alignment for the cell align the type of alignment
See Also:   HSSFCellStyle.VERTICAL_TOP
See Also:   HSSFCellStyle.VERTICAL_CENTER
See Also:   HSSFCellStyle.VERTICAL_BOTTOM
See Also:   HSSFCellStyle.VERTICAL_JUSTIFY



getWrapText
public boolean getWrapText()(Code)
get whether the text should be wrapped wrap text or not



setAlignment
public void setAlignment(short align)(Code)
set the type of horizontal alignment for the cell
Parameters:
  align - - the type of alignment
See Also:   HSSFCellStyle.ALIGN_GENERAL
See Also:   HSSFCellStyle.ALIGN_LEFT
See Also:   HSSFCellStyle.ALIGN_CENTER
See Also:   HSSFCellStyle.ALIGN_RIGHT
See Also:   HSSFCellStyle.ALIGN_FILL
See Also:   HSSFCellStyle.ALIGN_JUSTIFY
See Also:   HSSFCellStyle.ALIGN_CENTER_SELECTION



setBorderBottom
public void setBorderBottom(short border)(Code)
set the type of border to use for the bottom border of the cell
Parameters:
  border - type
See Also:   HSSFCellStyle.BORDER_NONE
See Also:   HSSFCellStyle.BORDER_THIN
See Also:   HSSFCellStyle.BORDER_MEDIUM
See Also:   HSSFCellStyle.BORDER_DASHED
See Also:   HSSFCellStyle.BORDER_DOTTED
See Also:   HSSFCellStyle.BORDER_THICK
See Also:   HSSFCellStyle.BORDER_DOUBLE
See Also:   HSSFCellStyle.BORDER_HAIR
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASHED
See Also:   HSSFCellStyle.BORDER_DASH_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT
See Also:   HSSFCellStyle.BORDER_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_SLANTED_DASH_DOT



setBorderLeft
public void setBorderLeft(short border)(Code)
set the type of border to use for the left border of the cell
Parameters:
  border - type
See Also:   HSSFCellStyle.BORDER_NONE
See Also:   HSSFCellStyle.BORDER_THIN
See Also:   HSSFCellStyle.BORDER_MEDIUM
See Also:   HSSFCellStyle.BORDER_DASHED
See Also:   HSSFCellStyle.BORDER_DOTTED
See Also:   HSSFCellStyle.BORDER_THICK
See Also:   HSSFCellStyle.BORDER_DOUBLE
See Also:   HSSFCellStyle.BORDER_HAIR
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASHED
See Also:   HSSFCellStyle.BORDER_DASH_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT
See Also:   HSSFCellStyle.BORDER_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_SLANTED_DASH_DOT



setBorderRight
public void setBorderRight(short border)(Code)
set the type of border to use for the right border of the cell
Parameters:
  border - type
See Also:   HSSFCellStyle.BORDER_NONE
See Also:   HSSFCellStyle.BORDER_THIN
See Also:   HSSFCellStyle.BORDER_MEDIUM
See Also:   HSSFCellStyle.BORDER_DASHED
See Also:   HSSFCellStyle.BORDER_DOTTED
See Also:   HSSFCellStyle.BORDER_THICK
See Also:   HSSFCellStyle.BORDER_DOUBLE
See Also:   HSSFCellStyle.BORDER_HAIR
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASHED
See Also:   HSSFCellStyle.BORDER_DASH_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT
See Also:   HSSFCellStyle.BORDER_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_SLANTED_DASH_DOT



setBorderTop
public void setBorderTop(short border)(Code)
set the type of border to use for the top border of the cell
Parameters:
  border - type
See Also:   HSSFCellStyle.BORDER_NONE
See Also:   HSSFCellStyle.BORDER_THIN
See Also:   HSSFCellStyle.BORDER_MEDIUM
See Also:   HSSFCellStyle.BORDER_DASHED
See Also:   HSSFCellStyle.BORDER_DOTTED
See Also:   HSSFCellStyle.BORDER_THICK
See Also:   HSSFCellStyle.BORDER_DOUBLE
See Also:   HSSFCellStyle.BORDER_HAIR
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASHED
See Also:   HSSFCellStyle.BORDER_DASH_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT
See Also:   HSSFCellStyle.BORDER_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_MEDIUM_DASH_DOT_DOT
See Also:   HSSFCellStyle.BORDER_SLANTED_DASH_DOT



setBottomBorderColor
public void setBottomBorderColor(short color)(Code)
set the color to use for the bottom border
Parameters:
  color - The index of the color definition



setDataFormat
public void setDataFormat(short fmt)(Code)
set the data format (must be a valid format)
See Also:   org.apache.poi.hssf.usermodel.HSSFDataFormat



setFillBackgroundColor
public void setFillBackgroundColor(short bg)(Code)
set the background fill color.

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.
Parameters:
  bg - color



setFillForegroundColor
public void setFillForegroundColor(short bg)(Code)
set the foreground fill color Note: Ensure Foreground color is set prior to background color.
Parameters:
  bg - color



setFillPattern
public void setFillPattern(short fp)(Code)
setting to one fills the cell with the foreground color... No idea about other values
See Also:   HSSFCellStyle.NO_FILL
See Also:   HSSFCellStyle.SOLID_FOREGROUND
See Also:   HSSFCellStyle.FINE_DOTS
See Also:   HSSFCellStyle.ALT_BARS
See Also:   HSSFCellStyle.SPARSE_DOTS
See Also:   HSSFCellStyle.THICK_HORZ_BANDS
See Also:   HSSFCellStyle.THICK_VERT_BANDS
See Also:   HSSFCellStyle.THICK_BACKWARD_DIAG
See Also:   HSSFCellStyle.THICK_FORWARD_DIAG
See Also:   HSSFCellStyle.BIG_SPOTS
See Also:   HSSFCellStyle.BRICKS
See Also:   HSSFCellStyle.THIN_HORZ_BANDS
See Also:   HSSFCellStyle.THIN_VERT_BANDS
See Also:   HSSFCellStyle.THIN_BACKWARD_DIAG
See Also:   HSSFCellStyle.THIN_FORWARD_DIAG
See Also:   HSSFCellStyle.SQUARES
See Also:   HSSFCellStyle.DIAMONDS
Parameters:
  fp - fill pattern (set to 1 to fill w/foreground color)



setFont
public void setFont(HSSFFont font)(Code)
set the font for this style
Parameters:
  font - a font object created or retreived from the HSSFWorkbook object
See Also:   org.apache.poi.hssf.usermodel.HSSFWorkbook.createFont
See Also:   org.apache.poi.hssf.usermodel.HSSFWorkbook.getFontAt(short)



setHidden
public void setHidden(boolean hidden)(Code)
set the cell's using this style to be hidden
Parameters:
  hidden - - whether the cell using this style should be hidden



setIndention
public void setIndention(short indent)(Code)
set the number of spaces to indent the text in the cell
Parameters:
  indent - - number of spaces



setLeftBorderColor
public void setLeftBorderColor(short color)(Code)
set the color to use for the left border
Parameters:
  color - The index of the color definition



setLocked
public void setLocked(boolean locked)(Code)
set the cell's using this style to be locked
Parameters:
  locked - - whether the cell using this style should be locked



setRightBorderColor
public void setRightBorderColor(short color)(Code)
set the color to use for the right border
Parameters:
  color - The index of the color definition



setRotation
public void setRotation(short rotation)(Code)
set the degree of rotation for the text in the cell
Parameters:
  rotation - degrees (between -90 and 90 degrees)



setTopBorderColor
public void setTopBorderColor(short color)(Code)
set the color to use for the top border
Parameters:
  color - The index of the color definition



setVerticalAlignment
public void setVerticalAlignment(short align)(Code)
set the type of vertical alignment for the cell
Parameters:
  align - the type of alignment
See Also:   HSSFCellStyle.VERTICAL_TOP
See Also:   HSSFCellStyle.VERTICAL_CENTER
See Also:   HSSFCellStyle.VERTICAL_BOTTOM
See Also:   HSSFCellStyle.VERTICAL_JUSTIFY



setWrapText
public void setWrapText(boolean wrapped)(Code)
set whether the text should be wrapped
Parameters:
  wrapped - wrap text or not



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.