|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ICellStyleProvider
Interface for a cell style supplier. The cell style provider is responsible for storing the individual cell styles. It is possible to define a single style for a row, a column or a specific cell. A default cell style is used whenever no specific cell style has been set.
The interface operates on cell styles. In some cases this is quite inconvenient so som econvience methods have been added to support direct setting of the properties.
Method Summary | |
---|---|
void |
addCellStyleListener(ICellStyleListener csl)
Add a listener to listen on cell style changes. |
ICellStyle |
getCellSpecificStyle(IRow row,
IColumn column,
boolean create)
Get the cell style defined for a single cell. |
ICellStyle |
getCellStyle(IRow row,
IColumn column)
Retrieve the cell style for a cell. |
ICellStyle |
getColumnCellStyle(IColumn column,
boolean create)
Retrieve the cell style for a column. |
ICellStyle |
getDefaultCellStyle()
Retrieve the default cell style used for cells where no style has been set. |
ICellStyle |
getRowCellStyle(IRow row,
boolean create)
Retrieve the cell style for a row. |
IStyleStrategy |
getStyleStrategy()
Retrieve a style strategy if set. |
void |
remCellStyleListener(ICellStyleListener csl)
Remove a cell sytle listener. |
void |
setBackground(IColumn column,
org.eclipse.swt.graphics.RGB background)
Convenience method for setting the background of a column. |
void |
setBackground(IRow row,
IColumn column,
org.eclipse.swt.graphics.RGB background)
Convenience method for setting the background of a cell. |
void |
setBackground(IRow row,
org.eclipse.swt.graphics.RGB background)
Convenience method for setting the background of a row. |
void |
setCellStyle(IRow row,
IColumn column,
ICellStyle style)
Set the cell style to use for a specific cell. |
void |
setColumnCellStyle(IColumn column,
ICellStyle style)
Set the cell style for a column. |
void |
setDefaultCellStyle(ICellStyle cellStyle)
Set the default cell style that is used whenever no specific style has been set for a cell, column or row. |
void |
setFont(IColumn column,
org.eclipse.swt.graphics.FontData fontdata)
Convenience method for setting the font. |
void |
setFont(IRow row,
org.eclipse.swt.graphics.FontData fontdata)
Convenience method for setting the font. |
void |
setFont(IRow row,
IColumn column,
org.eclipse.swt.graphics.FontData fontdata)
Convenience method for setting the font. |
void |
setForeground(IColumn column,
org.eclipse.swt.graphics.RGB foreground)
Convenience method for setting the foreground of a column. |
void |
setForeground(IRow row,
IColumn column,
org.eclipse.swt.graphics.RGB foreground)
Convenience method for setting the foreground of a cell. |
void |
setForeground(IRow row,
org.eclipse.swt.graphics.RGB foreground)
Convenience method for setting the foreground of a row. |
void |
setHorizontalAlignment(IColumn column,
ITableViewState.HAlignment hAlignment)
Convenience method for setting the horizontal alignment. |
void |
setHorizontalAlignment(IRow row,
IColumn column,
ITableViewState.HAlignment hAlignment)
Convenience method for setting the horizontal alignment. |
void |
setHorizontalAlignment(IRow row,
ITableViewState.HAlignment hAlignment)
Convenience method for setting the horizontal alignment. |
void |
setRowCellStyle(IRow row,
ICellStyle style)
Set the cell style for a row. |
void |
setStyleStrategy(IStyleStrategy startegy)
Set a style strategy to be involved when delivering styles. |
void |
setVerticalAlignment(IColumn column,
ITableViewState.VAlignment vAlignment)
Convenience method for setting the vertical alignment. |
void |
setVerticalAlignment(IRow row,
IColumn column,
ITableViewState.VAlignment vAlignment)
Convenience method for setting the vertical alignment. |
void |
setVerticalAlignment(IRow row,
ITableViewState.VAlignment vAlignment)
Convenience method for setting the vertical alignment. |
Method Detail |
---|
void setStyleStrategy(IStyleStrategy startegy)
startegy
- strategy to useIStyleStrategy getStyleStrategy()
null
ICellStyle getCellStyle(IRow row, IColumn column)
row
- row of the cellcolumn
- col of the cell
ICellStyle getCellSpecificStyle(IRow row, IColumn column, boolean create)
row
- row of the cellcolumn
- column of the cellcreate
- true will signal to create a new style object if necessary
ICellStyle getColumnCellStyle(IColumn column, boolean create)
column
- columncreate
- if true and no style has been set for the column, create a copy of the default cell style
void setColumnCellStyle(IColumn column, ICellStyle style)
column
- columnstyle
- styleICellStyle getRowCellStyle(IRow row, boolean create)
row
- rowcreate
- if true and no style has been set for the row, create a copy of the default cell style
void setRowCellStyle(IRow row, ICellStyle style)
row
- rowstyle
- cell stylevoid setCellStyle(IRow row, IColumn column, ICellStyle style)
row
- row of the cellcolumn
- column of the cellstyle
- style to useICellStyle getDefaultCellStyle()
void setDefaultCellStyle(ICellStyle cellStyle)
cellStyle
- cell style to use as the default cell stylevoid addCellStyleListener(ICellStyleListener csl)
csl
- listenervoid remCellStyleListener(ICellStyleListener csl)
csl
- listener to removevoid setBackground(IRow row, org.eclipse.swt.graphics.RGB background)
row
- rowbackground
- background colorvoid setBackground(IColumn column, org.eclipse.swt.graphics.RGB background)
column
- columnbackground
- background colorvoid setBackground(IRow row, IColumn column, org.eclipse.swt.graphics.RGB background)
row
- row of th cellcolumn
- column of the cellbackground
- background colorvoid setForeground(IRow row, org.eclipse.swt.graphics.RGB foreground)
row
- rowforeground
- background colorvoid setForeground(IColumn column, org.eclipse.swt.graphics.RGB foreground)
column
- columnforeground
- foreground colorvoid setForeground(IRow row, IColumn column, org.eclipse.swt.graphics.RGB foreground)
row
- row of th cellcolumn
- column of the cellforeground
- foreground colorvoid setHorizontalAlignment(IRow row, ITableViewState.HAlignment hAlignment)
row
- rowhAlignment
- horizontal alignmentvoid setHorizontalAlignment(IColumn column, ITableViewState.HAlignment hAlignment)
column
- columnhAlignment
- horizontal alignmentvoid setHorizontalAlignment(IRow row, IColumn column, ITableViewState.HAlignment hAlignment)
row
- row of th cellcolumn
- column of the cellhAlignment
- horizontal alignmentvoid setVerticalAlignment(IRow row, ITableViewState.VAlignment vAlignment)
row
- rowvAlignment
- vertical alignmentvoid setVerticalAlignment(IColumn column, ITableViewState.VAlignment vAlignment)
column
- columnvAlignment
- vertical alignmentvoid setVerticalAlignment(IRow row, IColumn column, ITableViewState.VAlignment vAlignment)
row
- row of th cellcolumn
- column of the cellvAlignment
- vertical alignmentvoid setFont(IRow row, org.eclipse.swt.graphics.FontData fontdata)
row
- rowfontdata
- font data for the font to usevoid setFont(IColumn column, org.eclipse.swt.graphics.FontData fontdata)
column
- columnfontdata
- font data for the font to usevoid setFont(IRow row, IColumn column, org.eclipse.swt.graphics.FontData fontdata)
row
- row of th cellcolumn
- column of the cellfontdata
- font data for the font to use
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |