use of org.eclipse.ui.forms.widgets.ColumnLayout in project hale by halestudio.
the class MismatchDetailsPage method createReasonSection.
private void createReasonSection(Composite parent) {
// create "Reason" Section
Section sectionReason = toolkit.createSection(parent, Section.DESCRIPTION | Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED);
ColumnLayoutData cd = new ColumnLayoutData();
sectionReason.setLayoutData(cd);
sectionReason.addExpansionListener(new ExpansionAdapter() {
public void expansionStateChanged(ExpansionEvent e) {
overviewForm.reflow(true);
}
});
sectionReason.setText("Reason");
sectionReason.setDescription("Why this mismatch occurs.");
Composite sectionReasonClient = toolkit.createComposite(sectionReason);
ColumnLayout reasonColumnLayout = new ColumnLayout();
reasonColumnLayout.maxNumColumns = 1;
sectionReasonClient.setLayout(reasonColumnLayout);
Tree treeReason = toolkit.createTree(sectionReasonClient, SWT.NULL);
treeReason.setLayout(new ColumnLayout());
ColumnLayoutData treeLayoutData = new ColumnLayoutData(50, 123);
treeReason.setLayoutData(treeLayoutData);
toolkit.paintBordersFor(sectionReasonClient);
sectionReason.setClient(sectionReasonClient);
this.reasonTreeViewer = new TreeViewer(treeReason);
this.reasonTreeViewer.setContentProvider(new ReasonContentProvider());
this.reasonTreeViewer.setLabelProvider(new ReasonLabelProvider());
}
use of org.eclipse.ui.forms.widgets.ColumnLayout in project linuxtools by eclipse.
the class RangeFilterWizardPage method createControl.
@Override
public void createControl(Composite parent) {
super.createControl(parent);
Composite comp = new Composite(parent, SWT.NULL);
comp.setLayout(new FormLayout());
FormData data1 = new FormData();
data1.left = new FormAttachment(0, 0);
data1.top = new FormAttachment(0, 0);
data1.right = new FormAttachment(40, 0);
data1.bottom = new FormAttachment(100, 0);
Composite cmpFilterOpts = new Composite(comp, SWT.NONE);
cmpFilterOpts.setLayoutData(data1);
ColumnLayout colLayout = new ColumnLayout();
colLayout.maxNumColumns = 1;
cmpFilterOpts.setLayout(colLayout);
// Column
Label lblColumn = new Label(cmpFilterOpts, SWT.NONE);
// $NON-NLS-1$
lblColumn.setText(Localization.getString("RangeFilterWizardPage.Column"));
cboColumn = new Combo(cmpFilterOpts, SWT.DROP_DOWN | SWT.READ_ONLY);
cboColumn.addSelectionListener(selectionListener);
for (int i = 0; i < wizard.series.length; i++) {
cboColumn.add(wizard.series[i]);
}
// Spacer
new Label(cmpFilterOpts, SWT.NONE);
// Low
Label lblLow = new Label(cmpFilterOpts, SWT.NONE);
// $NON-NLS-1$
lblLow.setText(Localization.getString("RangeFilterWizardPage.LowerBound"));
txtLow = new Text(cmpFilterOpts, SWT.BORDER);
txtLow.addModifyListener(modifyListener);
txtLow.addKeyListener(numberKeyListener);
// High
Label lblHigh = new Label(cmpFilterOpts, SWT.NONE);
// $NON-NLS-1$
lblHigh.setText(Localization.getString("RangeFilterWizardPage.UpperBound"));
txtHigh = new Text(cmpFilterOpts, SWT.BORDER);
txtHigh.addModifyListener(modifyListener);
txtHigh.addKeyListener(numberKeyListener);
// Spacer
new Label(cmpFilterOpts, SWT.NONE);
// Style
radInside = new Button(cmpFilterOpts, SWT.RADIO);
// $NON-NLS-1$
radInside.setText(Localization.getString("RangeFilterWizardPage.InsideBounds"));
radInside.addSelectionListener(selectionListener);
radInside.setSelection(true);
radOutside = new Button(cmpFilterOpts, SWT.RADIO);
// $NON-NLS-1$
radOutside.setText(Localization.getString("RangeFilterWizardPage.OutsideBounds"));
radOutside.addSelectionListener(selectionListener);
chkInclusive = new Button(cmpFilterOpts, SWT.CHECK);
// $NON-NLS-1$
chkInclusive.setText(Localization.getString("RangeFilterWizardPage.Inclusive"));
chkInclusive.addSelectionListener(selectionListener);
// Spacer
new Label(cmpFilterOpts, SWT.NONE);
cboColumn.select(0);
createFilter();
setControl(comp);
}
use of org.eclipse.ui.forms.widgets.ColumnLayout in project linuxtools by eclipse.
the class SortFilterWizardPage method createControl.
@Override
public void createControl(Composite parent) {
super.createControl(parent);
Composite comp = new Composite(parent, SWT.NULL);
comp.setLayout(new FormLayout());
FormData data1 = new FormData();
data1.left = new FormAttachment(0, 0);
data1.top = new FormAttachment(0, 0);
data1.right = new FormAttachment(40, 0);
data1.bottom = new FormAttachment(100, 0);
Composite cmpFilterOpts = new Composite(comp, SWT.NONE);
cmpFilterOpts.setLayoutData(data1);
ColumnLayout colLayout = new ColumnLayout();
colLayout.maxNumColumns = 1;
cmpFilterOpts.setLayout(colLayout);
// Column
Label lblColumn = new Label(cmpFilterOpts, SWT.NONE);
// $NON-NLS-1$
lblColumn.setText(Localization.getString("SortFilterWizardPage.Column"));
cboColumn = new Combo(cmpFilterOpts, SWT.DROP_DOWN | SWT.READ_ONLY);
cboColumn.addSelectionListener(selectionListener);
for (int i = 0; i < wizard.series.length; i++) {
cboColumn.add(wizard.series[i]);
}
// Spacer
new Label(cmpFilterOpts, SWT.NONE);
// Style
radAscending = new Button(cmpFilterOpts, SWT.RADIO);
// $NON-NLS-1$
radAscending.setText(Localization.getString("SortFilterWizardPage.Ascending"));
radAscending.addSelectionListener(selectionListener);
radAscending.setSelection(true);
radDescending = new Button(cmpFilterOpts, SWT.RADIO);
// $NON-NLS-1$
radDescending.setText(Localization.getString("SortFilterWizardPage.Descending"));
radDescending.addSelectionListener(selectionListener);
cboColumn.select(0);
createFilter();
setControl(comp);
}
use of org.eclipse.ui.forms.widgets.ColumnLayout in project jbosstools-hibernate by jbosstools.
the class RevEngOverviewPage method createFormContent.
public void createFormContent(IManagedForm parent) {
ScrolledForm form = parent.getForm();
ColumnLayout layout = new ColumnLayout();
layout.maxNumColumns = 2;
form.getBody().setLayout(layout);
createConsoleConfigName();
createContentsSection();
getManagedForm().setInput(reditor.getReverseEngineeringDefinition());
}
use of org.eclipse.ui.forms.widgets.ColumnLayout in project hale by halestudio.
the class MismatchDetailsPage method createConsequenceSection.
private void createConsequenceSection(Composite parent) {
// create "Consequence" Section
Section sectionConsequence = toolkit.createSection(parent, Section.DESCRIPTION | Section.TITLE_BAR | Section.TWISTIE | Section.EXPANDED);
ColumnLayoutData cd = new ColumnLayoutData();
sectionConsequence.setLayoutData(cd);
sectionConsequence.addExpansionListener(new ExpansionAdapter() {
public void expansionStateChanged(ExpansionEvent e) {
overviewForm.reflow(true);
}
});
sectionConsequence.setText("Consequence(s)");
sectionConsequence.setDescription("What impacts this mismatch has.");
Composite sectionConsequenceClient = toolkit.createComposite(sectionConsequence);
ColumnLayout consequenceColumnLayout = new ColumnLayout();
consequenceColumnLayout.maxNumColumns = 1;
sectionConsequenceClient.setLayout(consequenceColumnLayout);
Tree treeConsequence = toolkit.createTree(sectionConsequenceClient, SWT.NULL);
treeConsequence.setLayout(new ColumnLayout());
ColumnLayoutData treeLayoutData = new ColumnLayoutData(50, 123);
treeConsequence.setLayoutData(treeLayoutData);
toolkit.paintBordersFor(sectionConsequenceClient);
sectionConsequence.setClient(sectionConsequenceClient);
this.consequenceTreeViewer = new TreeViewer(treeConsequence);
this.consequenceTreeViewer.setContentProvider(new ConsequenceContentProvider());
this.consequenceTreeViewer.setLabelProvider(new ConsequenceLabelProvider());
}
Aggregations