From d5efa37a9b6c8dfc269be6ab5652abc2579c21d0 Mon Sep 17 00:00:00 2001 From: Serge Rider Date: Mon, 30 Sep 2019 00:28:47 +0300 Subject: [PATCH] Stream consumer settings page layout fix Former-commit-id: 9aa7c9a02e898f9f18e0c1c01cc6eddba7d81363 --- .../stream/StreamConsumerPageSettings.java | 17 ++++++++++++----- .../task/TaskConfigurationWizardPageTask.java | 5 ++++- .../src/org/jkiss/dbeaver/ui/UIUtils.java | 4 +++- 3 files changed, 19 insertions(+), 7 deletions(-) diff --git a/plugins/org.jkiss.dbeaver.data.transfer.ui/src/org/jkiss/dbeaver/tools/transfer/ui/pages/stream/StreamConsumerPageSettings.java b/plugins/org.jkiss.dbeaver.data.transfer.ui/src/org/jkiss/dbeaver/tools/transfer/ui/pages/stream/StreamConsumerPageSettings.java index 31014374a4..266fced928 100644 --- a/plugins/org.jkiss.dbeaver.data.transfer.ui/src/org/jkiss/dbeaver/tools/transfer/ui/pages/stream/StreamConsumerPageSettings.java +++ b/plugins/org.jkiss.dbeaver.data.transfer.ui/src/org/jkiss/dbeaver/tools/transfer/ui/pages/stream/StreamConsumerPageSettings.java @@ -21,6 +21,7 @@ import org.eclipse.swt.SWT; import org.eclipse.swt.events.SelectionAdapter; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.layout.GridData; +import org.eclipse.swt.layout.GridLayout; import org.eclipse.swt.widgets.Combo; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Label; @@ -74,7 +75,9 @@ public class StreamConsumerPageSettings extends ActiveWizardPage { taskDescription = taskDescriptionText.getText(); diff --git a/plugins/org.jkiss.dbeaver.ui/src/org/jkiss/dbeaver/ui/UIUtils.java b/plugins/org.jkiss.dbeaver.ui/src/org/jkiss/dbeaver/ui/UIUtils.java index f7d727636e..ee99a4cc26 100644 --- a/plugins/org.jkiss.dbeaver.ui/src/org/jkiss/dbeaver/ui/UIUtils.java +++ b/plugins/org.jkiss.dbeaver.ui/src/org/jkiss/dbeaver/ui/UIUtils.java @@ -532,7 +532,9 @@ public class UIUtils { public static Label createControlLabel(Composite parent, String label, int hSpan) { Label textLabel = new Label(parent, SWT.NONE); textLabel.setText(label + ": "); //$NON-NLS-1$ - GridData gd = new GridData(GridData.VERTICAL_ALIGN_BEGINNING /*| GridData.HORIZONTAL_ALIGN_END*/); + // Vert align center. Because height of single line control may differ from label height. This makes form ugly. + // For multiline texts we need to set vert align manually. + GridData gd = new GridData(GridData.VERTICAL_ALIGN_CENTER /*| GridData.HORIZONTAL_ALIGN_END*/); gd.horizontalSpan = hSpan; textLabel.setLayoutData(gd); return textLabel; -- GitLab