Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric Williams2019-10-29 14:09:31 +0000
committerAndrey Loskutov2019-10-31 08:27:00 +0000
commitdb0c00d90b53ed912b658ee2682ce40cacdf7e96 (patch)
tree5d1c0c4e65949fe6f8ff965c5d08d41d59bcfff3
parentd739929343a0d9d6fa71be508a734361b452352a (diff)
downloadeclipse.pde.ui-db0c00d90b53ed912b658ee2682ce40cacdf7e96.tar.gz
eclipse.pde.ui-db0c00d90b53ed912b658ee2682ce40cacdf7e96.tar.xz
eclipse.pde.ui-db0c00d90b53ed912b658ee2682ce40cacdf7e96.zip
Bug 552519: Plugin configuration dialog run level Spinner truncated on GTKI20191103-1800I20191102-1800I20191101-1800I20191101-0300I20191031-1800I20191031-1325
Set the column width for the plugin start level column to be the width of the Spinner that will occupy it (on GTK). Otherwise the column will be too small and may truncate the Spinner, rendering it unusable. Tested on GTK3.24 and Fedora 30 with a child Eclipse. The run level Spinner behaves as expected. Change-Id: Ic69b20f0ff012097256f9f7d69ae3f13e3ea18d5 Signed-off-by: Eric Williams <ericwill@redhat.com>
-rw-r--r--ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/launcher/AbstractPluginBlock.java9
1 files changed, 9 insertions, 0 deletions
diff --git a/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/launcher/AbstractPluginBlock.java b/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/launcher/AbstractPluginBlock.java
index aeb0317d3f..7ddb0fa59d 100644
--- a/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/launcher/AbstractPluginBlock.java
+++ b/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/launcher/AbstractPluginBlock.java
@@ -55,6 +55,7 @@ import org.eclipse.swt.custom.TreeEditor;
import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.graphics.Image;
+import org.eclipse.swt.graphics.Point;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.*;
@@ -507,6 +508,14 @@ public abstract class AbstractPluginBlock {
fTab.updateLaunchConfigurationDialog();
}
});
+ // Resize column with on GTK to ensure the Spinner widget will
+ // fit. See bug 552519.
+ if (Util.isGtk()) {
+ Point spinnerSize = spinner.computeSize(SWT.DEFAULT, SWT.DEFAULT);
+ levelColumnEditor.minimumWidth = spinnerSize.x;
+ TreeColumn levelColumn = tree.getColumn(1);
+ levelColumn.setWidth(spinnerSize.x);
+ }
levelColumnEditor.setEditor(spinner, item, 1);
final CCombo combo = new CCombo(tree, SWT.BORDER | SWT.READ_ONLY);

Back to the top