Class LabeledControl
The LabeledControl.Series inner class allows creating a series of labeled controls, each automatically attached the its
preceding control. E.g.
+--------+
|Label1 |
+--------+
|Control1|
+--------+
|Label2 |
+--------+
|Control2|
+--------+
|Label3 |
+--------+
|Control3|
+--------+
or if using LabeledControl.Series.layout(int height, int width, int numcols), labeled controls will be layed
out top down / left right with mechanics similar to GridLayout. E.g.
+--------+--------+--------+ |Wide Label1 |Label4 | +--------+--------+--------+ |Wide Control |Control4| +--------+--------+--------+ |Label2 |Label3 |Label5 | +--------+--------+--------+ |Control2|Control3|Control5| +--------+--------+--------+
LabeledControl.Series.hideAll() and LabeledControl.Series.show(Control) will update attachments automatically to
shift paired labels/controls up when preceding controls are hidden.
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionvoidattachBelow(org.eclipse.swt.widgets.Control control) Attaches this LabeledControl below control.voidattachBelow(org.eclipse.swt.widgets.Control control, int left) static LabeledControllabeledControl(org.eclipse.swt.widgets.Composite parentComp, String labelText, org.eclipse.swt.widgets.Control control, int controlWidth, PropsUI props)
-
Method Details
-
labeledControl
public static LabeledControl labeledControl(org.eclipse.swt.widgets.Composite parentComp, String labelText, org.eclipse.swt.widgets.Control control, int controlWidth, PropsUI props) -
attachBelow
public void attachBelow(org.eclipse.swt.widgets.Control control) Attaches this LabeledControl below control. If null, attaches to the top of the container. -
attachBelow
public void attachBelow(org.eclipse.swt.widgets.Control control, int left)
-