Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Pazderski2020-01-25 12:21:43 +0000
committerPaul Pazderski2020-01-25 12:21:43 +0000
commit6f075fa49f18eda277b49fd97bdcba8079b38a28 (patch)
treed14075e418ef88af18173a88e2cbe393ec6137ce /examples
parent023d007f7773a264857e5cc9500e6d35a52a2ae1 (diff)
downloadeclipse.platform.swt-6f075fa49f18eda277b49fd97bdcba8079b38a28.tar.gz
eclipse.platform.swt-6f075fa49f18eda277b49fd97bdcba8079b38a28.tar.xz
eclipse.platform.swt-6f075fa49f18eda277b49fd97bdcba8079b38a28.zip
Make color and cursor table in ControlExample scrollable
Change-Id: I94454b2367c0f1617a558a513ef55f7b4a74dc03 Signed-off-by: Paul Pazderski <paul-eclipse@ppazderski.de>
Diffstat (limited to 'examples')
-rw-r--r--examples/org.eclipse.swt.examples/src/org/eclipse/swt/examples/controlexample/ColorTab.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/examples/org.eclipse.swt.examples/src/org/eclipse/swt/examples/controlexample/ColorTab.java b/examples/org.eclipse.swt.examples/src/org/eclipse/swt/examples/controlexample/ColorTab.java
index 79979934d9..feb5e6e1cd 100644
--- a/examples/org.eclipse.swt.examples/src/org/eclipse/swt/examples/controlexample/ColorTab.java
+++ b/examples/org.eclipse.swt.examples/src/org/eclipse/swt/examples/controlexample/ColorTab.java
@@ -140,7 +140,8 @@ class ColorTab extends Tab {
/* Create the color table widget */
/* Compute the widget style */
int style = getDefaultStyle();
- colors = new Table (colorsGroup, style);
+ colors = new Table (colorsGroup, style | SWT.V_SCROLL);
+ colors.setLayoutData(new GridData (SWT.FILL, SWT.FILL, false, true));
colors.setHeaderVisible(true);
// fill in the table.
for (String columnTitle : columnTitles) {
@@ -183,7 +184,8 @@ class ColorTab extends Tab {
}
/* Create the cursor table widget */
- cursors = new Table (cursorsGroup, style);
+ cursors = new Table (cursorsGroup, style | SWT.V_SCROLL);
+ cursors.setLayoutData(new GridData (SWT.FILL, SWT.FILL, false, true));
cursors.setHeaderVisible(true);
// fill in the table.
TableColumn tableColumn = new TableColumn(cursors, SWT.NONE);

Back to the top