Author: DartPeng
Date: 2008-09-08 02:50:49 -0400 (Mon, 08 Sep 2008)
New Revision: 10133
Modified:
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/ui/ConnectionPropertySection.java
Log:
modify the controls layout
Modified:
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/ui/ConnectionPropertySection.java
===================================================================
---
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/ui/ConnectionPropertySection.java 2008-09-08
06:43:34 UTC (rev 10132)
+++
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/ui/ConnectionPropertySection.java 2008-09-08
06:50:49 UTC (rev 10133)
@@ -25,6 +25,7 @@
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.events.SelectionListener;
import org.eclipse.swt.graphics.Image;
+import org.eclipse.swt.layout.FillLayout;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Button;
@@ -54,11 +55,19 @@
}
@Override
- public void createControls(Composite parent,
+ public void createControls(Composite rootParent,
TabbedPropertySheetPage tabbedPropertySheetPage) {
- super.createControls(parent, tabbedPropertySheetPage);
+ super.createControls(rootParent, tabbedPropertySheetPage);
TabbedPropertySheetWidgetFactory factory = this.getWidgetFactory();
-
+ Composite parent = factory.createComposite(rootParent);
+ FillLayout fill = new FillLayout();
+ fill.marginHeight = 8;
+ fill.marginWidth = 8;
+ parent.setLayout(fill);
+ GridData pgd = new GridData(GridData.FILL_BOTH);
+ pgd.grabExcessHorizontalSpace = true;
+ pgd.grabExcessVerticalSpace = true;
+ rootParent.setLayoutData(pgd);
Section section = factory.createSection(parent, Section.TITLE_BAR);
section.setText("Mapping Properties");
@@ -201,12 +210,12 @@
}
});
- gd = new GridData(GridData.FILL_VERTICAL);
+ gd = new GridData(GridData.FILL_HORIZONTAL);
button1.setLayoutData(gd);
Button button2 = factory.createButton(buttonComposite, "Delete ",
SWT.NONE);
- gd = new GridData(GridData.FILL_VERTICAL);
+ gd = new GridData(GridData.FILL_HORIZONTAL);
button2.setLayoutData(gd);
button2.addSelectionListener(new SelectionAdapter() {
Show replies by date