use of org.apache.pivot.wtk.Theme in project pivot by apache.
the class ColorPaletteTest method startup.
@SuppressWarnings("unused")
@Override
public void startup(Display display, Map<String, String> properties) throws Exception {
Theme theme = Theme.getTheme();
TablePane tablePane = new TablePane();
new TablePane.Column(tablePane, 1, true);
new TablePane.Column(tablePane, 1, true);
new TablePane.Column(tablePane, 1, true);
int numberOfPaletteColors = theme.getNumberOfPaletteColors();
// ArrayList<String> colors = new ArrayList<>(numberOfPaletteColors);
for (int i = 0; i < numberOfPaletteColors; i++) {
TablePane.Row row = new TablePane.Row(tablePane, 1, true);
row.add(createCell(i * 3));
row.add(createCell(i * 3 + 1));
row.add(createCell(i * 3 + 2));
}
tablePane.getStyles().put(Style.horizontalSpacing, 4);
tablePane.getStyles().put(Style.verticalSpacing, 4);
Border border = new Border(tablePane);
border.getStyles().put(Style.padding, 6);
this.window = new Window(border);
this.window.setTitle("Color Palette");
this.window.setMaximized(true);
this.window.open(display);
}
use of org.apache.pivot.wtk.Theme in project pivot by apache.
the class TerraTableViewHeaderSkin method setColor.
public final void setColor(int color) {
Theme theme = Theme.getTheme();
setColor(theme.getColor(color));
}
use of org.apache.pivot.wtk.Theme in project pivot by apache.
the class TerraTableViewHeaderSkin method setDisabledColor.
public final void setDisabledColor(int disabledColor) {
Theme theme = Theme.getTheme();
setDisabledColor(theme.getColor(disabledColor));
}
use of org.apache.pivot.wtk.Theme in project pivot by apache.
the class TerraTableViewHeaderSkin method setBackgroundColor.
public final void setBackgroundColor(int backgroundColor) {
Theme theme = Theme.getTheme();
setBackgroundColor(theme.getColor(backgroundColor));
}
use of org.apache.pivot.wtk.Theme in project pivot by apache.
the class TerraTableViewSkin method setAlternateRowBackgroundColor.
public final void setAlternateRowBackgroundColor(int alternateRowBackgroundColor) {
Theme theme = Theme.getTheme();
setAlternateRowBackgroundColor(theme.getColor(alternateRowBackgroundColor));
}
Aggregations