Java Code Examples for org.eclipse.jface.dialogs.IDialogConstants#HORIZONTAL_MARGIN
The following examples show how to use
org.eclipse.jface.dialogs.IDialogConstants#HORIZONTAL_MARGIN .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: JarImportWizardPage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 6 votes |
/** * Creates the rename group. * * @param parent * the parent control */ protected void createRenameGroup(final Composite parent) { Assert.isNotNull(parent); final JarImportData data= fWizard.getImportData(); final Button button= new Button(parent, SWT.CHECK); button.setText(JarImportMessages.JarImportWizardPage_replace_jar_file); button.setSelection(!data.isRenameJarFile()); button.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(final SelectionEvent event) { data.setRenameJarFile(!button.getSelection()); } }); if (fImportWizard && !fTreeViewer.getControl().isEnabled()) button.setEnabled(false); if (!fImportWizard) { final GridData gd= new GridData(); gd.horizontalIndent= IDialogConstants.HORIZONTAL_MARGIN; button.setLayoutData(gd); } }
Example 2
Source File: TermDbManagerDialog.java From translationstudio8 with GNU General Public License v2.0 | 5 votes |
/** * Create contents of the dialog. * @param parent */ @Override protected Control createDialogArea(Composite parent) { final Composite composite = (Composite) super.createDialogArea(parent); GridLayout parentLayout = ((GridLayout) composite.getLayout()); parentLayout.numColumns = 4; parentLayout.marginHeight = 0; parentLayout.marginWidth = 0; parentLayout.marginTop = 0; parentLayout.verticalSpacing = 0; parentLayout.horizontalSpacing = 0; Control treeControl = createTreeAreaContents(composite); createSash(composite, treeControl); Label versep = new Label(composite, SWT.SEPARATOR | SWT.VERTICAL); GridData verGd = new GridData(GridData.FILL_VERTICAL | GridData.GRAB_VERTICAL); versep.setLayoutData(verGd); versep.setLayoutData(new GridData(SWT.LEFT, SWT.FILL, false, true)); Composite pageAreaComposite = new Composite(composite, SWT.NONE); pageAreaComposite.setLayoutData(new GridData(GridData.FILL_BOTH)); GridLayout layout = new GridLayout(1, true); layout.marginHeight = 0; layout.marginWidth = 0; layout.verticalSpacing = 0; pageAreaComposite.setLayout(layout); // Build the Page container Composite pageContainer = createPageContainer(pageAreaComposite); GridData pageContainerData = new GridData(GridData.FILL_BOTH); pageContainerData.horizontalIndent = IDialogConstants.HORIZONTAL_MARGIN; pageContainer.setLayoutData(pageContainerData); // Build the separator line Label bottomSeparator = new Label(parent, SWT.HORIZONTAL | SWT.SEPARATOR); bottomSeparator.setLayoutData(new GridData(GridData.FILL_HORIZONTAL | GridData.GRAB_HORIZONTAL)); return composite; }
Example 3
Source File: TmDbManagerDialog.java From translationstudio8 with GNU General Public License v2.0 | 5 votes |
/** * Create contents of the dialog. * @param parent */ @Override protected Control createDialogArea(Composite parent) { final Composite composite = (Composite) super.createDialogArea(parent); GridLayout parentLayout = ((GridLayout) composite.getLayout()); parentLayout.numColumns = 4; parentLayout.marginHeight = 0; parentLayout.marginWidth = 0; parentLayout.marginTop = 0; parentLayout.verticalSpacing = 0; parentLayout.horizontalSpacing = 0; Control treeControl = createTreeAreaContents(composite); createSash(composite, treeControl); Label versep = new Label(composite, SWT.SEPARATOR | SWT.VERTICAL); GridData verGd = new GridData(GridData.FILL_VERTICAL | GridData.GRAB_VERTICAL); versep.setLayoutData(verGd); versep.setLayoutData(new GridData(SWT.LEFT, SWT.FILL, false, true)); Composite pageAreaComposite = new Composite(composite, SWT.NONE); pageAreaComposite.setLayoutData(new GridData(GridData.FILL_BOTH)); GridLayout layout = new GridLayout(1, true); layout.marginHeight = 0; layout.marginWidth = 0; layout.verticalSpacing = 0; pageAreaComposite.setLayout(layout); // Build the Page container Composite pageContainer = createPageContainer(pageAreaComposite); GridData pageContainerData = new GridData(GridData.FILL_BOTH); pageContainerData.horizontalIndent = IDialogConstants.HORIZONTAL_MARGIN; pageContainer.setLayoutData(pageContainerData); // Build the separator line Label bottomSeparator = new Label(parent, SWT.HORIZONTAL | SWT.SEPARATOR); bottomSeparator.setLayoutData(new GridData(GridData.FILL_HORIZONTAL | GridData.GRAB_HORIZONTAL)); return composite; }
Example 4
Source File: TmDbManagerDialog.java From tmxeditor8 with GNU General Public License v2.0 | 5 votes |
/** * Create contents of the dialog. * @param parent */ @Override protected Control createDialogArea(Composite parent) { final Composite composite = (Composite) super.createDialogArea(parent); GridLayout parentLayout = ((GridLayout) composite.getLayout()); parentLayout.numColumns = 4; parentLayout.marginHeight = 0; parentLayout.marginWidth = 0; parentLayout.marginTop = 0; parentLayout.verticalSpacing = 0; parentLayout.horizontalSpacing = 0; Control treeControl = createTreeAreaContents(composite); createSash(composite, treeControl); Label versep = new Label(composite, SWT.SEPARATOR | SWT.VERTICAL); GridData verGd = new GridData(GridData.FILL_VERTICAL | GridData.GRAB_VERTICAL); versep.setLayoutData(verGd); versep.setLayoutData(new GridData(SWT.LEFT, SWT.FILL, false, true)); Composite pageAreaComposite = new Composite(composite, SWT.NONE); pageAreaComposite.setLayoutData(new GridData(GridData.FILL_BOTH)); GridLayout layout = new GridLayout(1, true); layout.marginHeight = 0; layout.marginWidth = 0; layout.verticalSpacing = 0; pageAreaComposite.setLayout(layout); // Build the Page container Composite pageContainer = createPageContainer(pageAreaComposite); GridData pageContainerData = new GridData(GridData.FILL_BOTH); pageContainerData.horizontalIndent = IDialogConstants.HORIZONTAL_MARGIN; pageContainer.setLayoutData(pageContainerData); // Build the separator line Label bottomSeparator = new Label(parent, SWT.HORIZONTAL | SWT.SEPARATOR); bottomSeparator.setLayoutData(new GridData(GridData.FILL_HORIZONTAL | GridData.GRAB_HORIZONTAL)); return composite; }
Example 5
Source File: TermDbManagerDialog.java From tmxeditor8 with GNU General Public License v2.0 | 5 votes |
/** * Create contents of the dialog. * @param parent */ @Override protected Control createDialogArea(Composite parent) { final Composite composite = (Composite) super.createDialogArea(parent); GridLayout parentLayout = ((GridLayout) composite.getLayout()); parentLayout.numColumns = 4; parentLayout.marginHeight = 0; parentLayout.marginWidth = 0; parentLayout.marginTop = 0; parentLayout.verticalSpacing = 0; parentLayout.horizontalSpacing = 0; Control treeControl = createTreeAreaContents(composite); createSash(composite, treeControl); Label versep = new Label(composite, SWT.SEPARATOR | SWT.VERTICAL); GridData verGd = new GridData(GridData.FILL_VERTICAL | GridData.GRAB_VERTICAL); versep.setLayoutData(verGd); versep.setLayoutData(new GridData(SWT.LEFT, SWT.FILL, false, true)); Composite pageAreaComposite = new Composite(composite, SWT.NONE); pageAreaComposite.setLayoutData(new GridData(GridData.FILL_BOTH)); GridLayout layout = new GridLayout(1, true); layout.marginHeight = 0; layout.marginWidth = 0; layout.verticalSpacing = 0; pageAreaComposite.setLayout(layout); // Build the Page container Composite pageContainer = createPageContainer(pageAreaComposite); GridData pageContainerData = new GridData(GridData.FILL_BOTH); pageContainerData.horizontalIndent = IDialogConstants.HORIZONTAL_MARGIN; pageContainer.setLayoutData(pageContainerData); // Build the separator line Label bottomSeparator = new Label(parent, SWT.HORIZONTAL | SWT.SEPARATOR); bottomSeparator.setLayoutData(new GridData(GridData.FILL_HORIZONTAL | GridData.GRAB_HORIZONTAL)); return composite; }
Example 6
Source File: TmDbManagerDialog.java From tmxeditor8 with GNU General Public License v2.0 | 5 votes |
/** * Create contents of the dialog. * @param parent */ @Override protected Control createDialogArea(Composite parent) { final Composite composite = (Composite) super.createDialogArea(parent); GridLayout parentLayout = ((GridLayout) composite.getLayout()); parentLayout.numColumns = 4; parentLayout.marginHeight = 0; parentLayout.marginWidth = 0; parentLayout.marginTop = 0; parentLayout.verticalSpacing = 0; parentLayout.horizontalSpacing = 0; Control treeControl = createTreeAreaContents(composite); createSash(composite, treeControl); Label versep = new Label(composite, SWT.SEPARATOR | SWT.VERTICAL); GridData verGd = new GridData(GridData.FILL_VERTICAL | GridData.GRAB_VERTICAL); versep.setLayoutData(verGd); versep.setLayoutData(new GridData(SWT.LEFT, SWT.FILL, false, true)); Composite pageAreaComposite = new Composite(composite, SWT.NONE); pageAreaComposite.setLayoutData(new GridData(GridData.FILL_BOTH)); GridLayout layout = new GridLayout(1, true); layout.marginHeight = 0; layout.marginWidth = 0; layout.verticalSpacing = 0; pageAreaComposite.setLayout(layout); // Build the Page container Composite pageContainer = createPageContainer(pageAreaComposite); GridData pageContainerData = new GridData(GridData.FILL_BOTH); pageContainerData.horizontalIndent = IDialogConstants.HORIZONTAL_MARGIN; pageContainer.setLayoutData(pageContainerData); // Build the separator line Label bottomSeparator = new Label(parent, SWT.HORIZONTAL | SWT.SEPARATOR); bottomSeparator.setLayoutData(new GridData(GridData.FILL_HORIZONTAL | GridData.GRAB_HORIZONTAL)); return composite; }
Example 7
Source File: AbstractPropertyDialog.java From birt with Eclipse Public License 1.0 | 5 votes |
private final Composite createPropertyPane( Composite parent ) { // If the title is visible // create the title area. Composite propertyContainer = new Composite( parent, SWT.NONE ); GridLayout layout = new GridLayout( ); layout.marginWidth = 0; layout.marginHeight = 0; propertyContainer.setLayout( layout ); Composite titleComposite = new Composite( propertyContainer, SWT.NONE ); layout = new GridLayout( ); layout.marginHeight = 0; layout.marginWidth = 0; layout.verticalSpacing = 0; layout.horizontalSpacing = 0; titleComposite.setLayout( layout ); GridData titleLayoutData = new GridData( GridData.FILL_HORIZONTAL ); titleLayoutData.horizontalIndent = IDialogConstants.HORIZONTAL_MARGIN; titleComposite.setLayoutData( titleLayoutData ); if ( isTitleVisible( ) ) { createTitleArea( titleComposite ); Label separator = new Label( propertyContainer, SWT.HORIZONTAL | SWT.SEPARATOR ); separator.setLayoutData( new GridData( GridData.FILL_HORIZONTAL | GridData.GRAB_HORIZONTAL ) ); } GridData data = new GridData( GridData.FILL_BOTH ); propertyPane = new Composite( propertyContainer, SWT.NONE ); propertyPane.setLayout( propertyPaneLayout ); propertyPane.setLayoutData( data ); return propertyContainer; }
Example 8
Source File: HsPreferenceDialog.java From translationstudio8 with GNU General Public License v2.0 | 4 votes |
protected Control createDialogArea(Composite parent) { Composite composite = new Composite(parent, SWT.NONE); GridLayout parentcomLayout = new GridLayout(); parentcomLayout.marginHeight = convertVerticalDLUsToPixels(IDialogConstants.VERTICAL_MARGIN); parentcomLayout.marginWidth = convertHorizontalDLUsToPixels(IDialogConstants.HORIZONTAL_MARGIN); parentcomLayout.verticalSpacing = convertVerticalDLUsToPixels(IDialogConstants.VERTICAL_SPACING); parentcomLayout.horizontalSpacing = convertHorizontalDLUsToPixels(IDialogConstants.HORIZONTAL_SPACING); composite.setLayout(parentcomLayout); composite.setLayoutData(new GridData(GridData.FILL_BOTH)); applyDialogFont(composite); GridLayout parentLayout = ((GridLayout) composite.getLayout()); parentLayout.numColumns = 4; parentLayout.marginHeight = 0; parentLayout.marginWidth = 0; parentLayout.verticalSpacing = 0; parentLayout.horizontalSpacing = 0; composite.setBackground(parent.getDisplay().getSystemColor(SWT.COLOR_LIST_BACKGROUND)); Control treeControl = createTreeAreaContents(composite); createSash(composite, treeControl); Label versep = new Label(composite, SWT.SEPARATOR | SWT.VERTICAL); GridData verGd = new GridData(GridData.FILL_VERTICAL | GridData.GRAB_VERTICAL); versep.setLayoutData(verGd); versep.setLayoutData(new GridData(SWT.LEFT, SWT.FILL, false, true)); Composite pageAreaComposite = new Composite(composite, SWT.NONE); pageAreaComposite.setLayoutData(new GridData(GridData.FILL_BOTH)); GridLayout layout = new GridLayout(1, true); layout.marginHeight = 0; layout.marginWidth = 0; layout.verticalSpacing = 0; pageAreaComposite.setLayout(layout); // Build the Page container Composite pageContainer = createPageContainer(pageAreaComposite); GridData pageContainerData = new GridData(GridData.FILL_BOTH); pageContainerData.horizontalIndent = IDialogConstants.HORIZONTAL_MARGIN; pageContainer.setLayoutData(pageContainerData); super.setPageContainer(pageContainer); // Build the separator line Label bottomSeparator = new Label(parent, SWT.HORIZONTAL | SWT.SEPARATOR); bottomSeparator.setLayoutData(new GridData(GridData.FILL_HORIZONTAL | GridData.GRAB_HORIZONTAL)); return composite; }
Example 9
Source File: HsPreferenceDialog.java From tmxeditor8 with GNU General Public License v2.0 | 4 votes |
protected Control createDialogArea(Composite parent) { Composite composite = new Composite(parent, SWT.NONE); GridLayout parentcomLayout = new GridLayout(); parentcomLayout.marginHeight = convertVerticalDLUsToPixels(IDialogConstants.VERTICAL_MARGIN); parentcomLayout.marginWidth = convertHorizontalDLUsToPixels(IDialogConstants.HORIZONTAL_MARGIN); parentcomLayout.verticalSpacing = convertVerticalDLUsToPixels(IDialogConstants.VERTICAL_SPACING); parentcomLayout.horizontalSpacing = convertHorizontalDLUsToPixels(IDialogConstants.HORIZONTAL_SPACING); composite.setLayout(parentcomLayout); composite.setLayoutData(new GridData(GridData.FILL_BOTH)); applyDialogFont(composite); GridLayout parentLayout = ((GridLayout) composite.getLayout()); parentLayout.numColumns = 4; parentLayout.marginHeight = 0; parentLayout.marginWidth = 0; parentLayout.verticalSpacing = 0; parentLayout.horizontalSpacing = 0; composite.setBackground(parent.getDisplay().getSystemColor(SWT.COLOR_LIST_BACKGROUND)); Control treeControl = createTreeAreaContents(composite); createSash(composite, treeControl); Label versep = new Label(composite, SWT.SEPARATOR | SWT.VERTICAL); GridData verGd = new GridData(GridData.FILL_VERTICAL | GridData.GRAB_VERTICAL); versep.setLayoutData(verGd); versep.setLayoutData(new GridData(SWT.LEFT, SWT.FILL, false, true)); Composite pageAreaComposite = new Composite(composite, SWT.NONE); pageAreaComposite.setLayoutData(new GridData(GridData.FILL_BOTH)); GridLayout layout = new GridLayout(1, true); layout.marginHeight = 0; layout.marginWidth = 0; layout.verticalSpacing = 0; pageAreaComposite.setLayout(layout); // Build the Page container Composite pageContainer = createPageContainer(pageAreaComposite); GridData pageContainerData = new GridData(GridData.FILL_BOTH); pageContainerData.horizontalIndent = IDialogConstants.HORIZONTAL_MARGIN; pageContainer.setLayoutData(pageContainerData); super.setPageContainer(pageContainer); // Build the separator line Label bottomSeparator = new Label(parent, SWT.HORIZONTAL | SWT.SEPARATOR); bottomSeparator.setLayoutData(new GridData(GridData.FILL_HORIZONTAL | GridData.GRAB_HORIZONTAL)); return composite; }