Cell Painter [message #1057712] |
Wed, 08 May 2013 07:52 |
Saket M Messages: 3 Registered: April 2013 |
Junior Member |
|
|
Hi,
I want to add styling to my commented cells. The labels are added correctly but check box and combo box cells arent displaying the style. The same style is working for text boxes. Here is the styling code that I use
private ICellPainter checkBoxCellPainter;
@Override
public void configureRegistry(IConfigRegistry configRegistry) {
checkBoxCellPainter = new CheckBoxPainter();
registerCheckBoxEditor(configRegistry, checkBoxCellPainter, new CheckBoxCellEditor());
configRegistry.registerConfigAttribute(CellConfigAttributes.CELL_PAINTER,
new LineBorderDecorator(checkBoxCellPainter, new BorderStyle(2, ColorConstants.lightBlue, BorderStyle.LineStyleEnum.SOLID )),
DisplayMode.NORMAL, DecisionTableSWTFormViewer.CHECK_BOX_COMMENT_LABEL);
super.configureRegistry(configR[/ALIGN]egistry);
}
private void registerCheckBoxEditor(IConfigRegistry configRegistry, ICellPainter checkBoxCellPainter, ICellEditor checkBoxCellEditor) {
configRegistry.registerConfigAttribute(CellConfigAttributes.CELL_PAINTER, checkBoxCellPainter, DisplayMode.NORMAL, DecisionTableSWTFormViewer.CHECK_BOX_CONFIG_LABEL);
configRegistry.registerConfigAttribute(CellConfigAttributes.DISPLAY_CONVERTER, new StringToBooleanDisplayConverter(), DisplayMode.NORMAL, DecisionTableSWTFormViewer.CHECK_BOX_CONFIG_LABEL);
configRegistry.registerConfigAttribute(EditConfigAttributes.CELL_EDITOR, checkBoxCellEditor, DisplayMode.NORMAL, DecisionTableSWTFormViewer.CHECK_BOX_EDITOR_CONFIG_LABEL);
}
Am I doing soemthing wrong?
|
|
|
|
Powered by
FUDForum. Page generated in 0.03743 seconds