Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
Nebula CSS TableCombo
Introduction
This page explains how to use the CSS theming for the TableCombo widget.
Contents
Installation
In you e4 application you can install :
- The plugin org.eclipse.nebula.widgets.tablecombo.css OR
- The feature org.eclipse.nebula.widgets.tablecombo.css.feature
Properties
General Properties
SWT Method | Impact | CSS Property Name | CSS Example |
---|---|---|---|
setShowTableLines(boolean) | If true , the lines are displayed in the table |
tablecombo-show-table-lines | TableCombo { tablecombo-show-table-lines: true; } |
setShowTableHeader(boolean) | If true , the headers are displayed in the table |
tablecombo-show-table-header | TableCombo { tablecombo-show-table-header: false; } |
setBorderColor(Color) | Change the border's color of the widget | tablecombo-border-color | TableCombo { tablecombo-border-color: red; } |
Text part Properties
These properties allow the developer to customize the "text" part of the widget.
SWT Method | Impact | CSS Property Name | CSS Example |
---|---|---|---|
setBackground(Color) | Set the bacgkround color of the text part | tablecombo-text-background-color | TableCombo { tablecombo-text-background-color: #cccccc; } |
setForeground(Color) | Set the foreground color of the text part | tablecombo-text-color | TableCombo { tablecombo-text-color: black; } |
setFont(Font) | tablecombo-text-font | Set the font of the text part | TableCombo { tablecombo-text-font: italic 12 bold "Terminal"; } |
tablecombo-text-font-style tablecombo-text-font-size |
TableCombo { tablecombo-font-style: italic; tablecombo-text-font-size: 12; |
Button part Properties
These properties allow the developer to customize the "button" part of the widget. This is a hint, because the OS can override these methods.
SWT Method | Impact | CSS Property Name | CSS Example |
---|---|---|---|
setBackground(Color) | Set the bacgkround color of the button part | tablecombo-button-background-color | TableCombo { tablecombo-button-background-color: #cccccc; } |
setForeground(Color) | Set the foreground color of the button part | tablecombo-button-color | TableCombo { tablecombo-button-color: black; } |
Table part Properties
These properties allow the developer to customize the "table" part of the widget.
SWT Method | Impact | CSS Property Name | CSS Example |
---|---|---|---|
setBackground(Color) | Set the bacgkround color of the table part | tablecombo-table-background-color | TableCombo { tablecombo-table-background-color: #cccccc; } |
setForeground(Color) | Set the foreground color of the table part | tablecombo-table-color | TableCombo { tablecombo-table-color: black; } |
setFont(Font) | tablecombo-table-font | Set the font of the table part | TableCombo { tablecombo-table-font: italic 12 bold "Terminal"; } |
tablecombo-table-font-style tablecombo-table-font-size |
TableCombo { font-style: italic; tablecombo-table-font-size: 12; |
||
setTableWidthPercentage(int) | tablecombo-table-width-percentage | Set the table width percentage | TableCombo { tablecombo-table-width-percentage: 56; } |
Odd lines Properties
These properties allow the developer to customize the odd lines displayed in the widget.
SWT Method | Impact | CSS Property Name | CSS Example |
---|---|---|---|
setOddLinesForegroundColor(Color) | Set the bacgkround color of the odd lines | tablecombo-table-odd-lines-background-color | TableCombo { tablecombo-table-odd-lines-background-color: #ffffcc; } |
setOddLinesBackgroundColor(Color) | Set the background color of the odd lines | tablecombo-table-odd-lines-color | TableCombo { tablecombo-table-odd-lines-color: black; } |
Even lines Properties
These properties allow the developer to customize the even lines displayed in the widget.
SWT Method | Impact | CSS Property Name | CSS Example |
---|---|---|---|
setEvenLinesForegroundColor(Color) | Set the bacgkround color of the even lines | tablecombo-table-even-lines-background-color | TableCombo { tablecombo-table-even-lines-background-color: #ffffcc; } |
setEvenLinesBackgroundColor(Color) | Set the background color of the even lines | tablecombo-table-even-lines-color | TableCombo { tablecombo-table-even-lines-color: black; } |
Examples
An e4 example application called org.eclipse.nebula.widgets.tablecombo.example.e4 shows how to customize TableCombo widget.
This example is also available here : org.eclipse.nebula.widgets.tablecombo.example.e4