当前位置: 首页>>代码示例>>Java>>正文


Java GridData.BEGINNING属性代码示例

本文整理汇总了Java中org.eclipse.swt.layout.GridData.BEGINNING属性的典型用法代码示例。如果您正苦于以下问题:Java GridData.BEGINNING属性的具体用法?Java GridData.BEGINNING怎么用?Java GridData.BEGINNING使用的例子?那么恭喜您, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在org.eclipse.swt.layout.GridData的用法示例。


在下文中一共展示了GridData.BEGINNING属性的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: createCombo

/**
 * This method initializes combo	
 *
 */
private void createCombo() {
	GridData gridData1 = new GridData();
	gridData1.grabExcessHorizontalSpace = false;
	gridData1.verticalAlignment = GridData.CENTER;
	gridData1.horizontalAlignment = GridData.BEGINNING;
	combo = new Combo(this, SWT.NONE);
	combo.setLayoutData(gridData1);
	combo.add("*");
	combo.add("Screen class");
	combo.add("Criteria");
	combo.add("Extraction rule");
	combo.add("Sheet");
	combo.add("Transaction");
	combo.add("Statement");
	combo.add("Sequence");
	combo.add("Step");
}
 
开发者ID:convertigo,项目名称:convertigo-eclipse,代码行数:21,代码来源:DatabaseObjectFindDialogComposite.java

示例2: createStandardCombo

public void createStandardCombo ( final Composite parent, final String attributeName, final String label, final String[] items, final IObservableMap data, final Object valueType )
{
    this.toolkit.createLabel ( parent, label + ":" );

    final Combo combo = new Combo ( parent, SWT.DROP_DOWN );

    combo.setItems ( items );
    this.toolkit.adapt ( combo );

    final GridData gd = new GridData ( GridData.FILL, GridData.BEGINNING, true, true );
    gd.horizontalSpan = 2;
    combo.setLayoutData ( gd );

    final IObservableValue value = Observables.observeMapEntry ( data, attributeName, valueType );
    this.dbc.bindValue ( WidgetProperties.text ().observe ( combo ), value );
}
 
开发者ID:eclipse,项目名称:neoscada,代码行数:16,代码来源:ConfigurationFormToolkit.java

示例3: createGroup

/**
 * This method initializes group	
 *
 */
private void createGroup() {
	GridData gridData1 = new GridData();
	gridData1.horizontalAlignment = GridData.BEGINNING;
	gridData1.grabExcessHorizontalSpace = true;
	gridData1.verticalAlignment = GridData.CENTER;
	GridData gridData = new GridData();
	gridData.horizontalAlignment = GridData.FILL;
	gridData.verticalAlignment = GridData.CENTER;
	GridLayout gridLayout1 = new GridLayout();
	gridLayout1.numColumns = 2;
	GridData gridData3 = new GridData();
	gridData3.horizontalAlignment = GridData.FILL;
	gridData3.horizontalSpan = 2;
	gridData3.grabExcessHorizontalSpace = true;
	gridData3.grabExcessVerticalSpace = false;
	gridData3.verticalAlignment = GridData.FILL;
	group = new Group(this, SWT.NONE);
	group.setText("Target Server");
	group.setLayoutData(gridData3);
	group.setLayout(gridLayout1);
	label = new Label(group, SWT.NONE);
	label.setText("HTTP Server");
	httpServer = new Text(group, SWT.BORDER);
	httpServer.setLayoutData(gridData);
	
	label2 = new Label(group, SWT.NONE);
	label2.setText("HTTP Port");
	httpPort = new Text(group, SWT.BORDER);
	httpPort.setLayoutData(gridData1);
	label3 = new Label(group, SWT.NONE);
	label3.setText("SSL");
	ssl = new Button(group, SWT.CHECK);
	
	httpServer.addModifyListener(modifyListener);
       httpPort.addModifyListener(modifyListener);
       ssl.addSelectionListener(selectionListener);
}
 
开发者ID:convertigo,项目名称:convertigo-eclipse,代码行数:41,代码来源:NewProjectWizardComposite6.java

示例4: buildLeftColumn

private void buildLeftColumn() {
	final Composite composite = new Composite(this.shell, SWT.NONE);
	final GridData gd = new GridData(GridData.FILL, GridData.BEGINNING, false,
			true, 1, 1);
	composite.setLayoutData(gd);
	final FillLayout compositeLayout = new FillLayout();
	compositeLayout.marginWidth = 2;
	composite.setLayout(compositeLayout);
	final Label label = new Label(composite, SWT.NONE);
	if (this.image == null) {
		this.image = new Image(display, this.getClass().getClassLoader()
				.getResourceAsStream("images/document_wrench_color.png"));
		shell.addListener(SWT.Close, new Listener() {
			@Override
			public void handleEvent(Event event) {
				image.dispose();
			}
		});

	}
	label.setImage(this.image);
}
 
开发者ID:sergueik,项目名称:SWET,代码行数:22,代码来源:TipDayEx.java

示例5: buildLeftColumn

private void buildLeftColumn() {
	final Composite composite = new Composite(this.shell, SWT.NONE);
	final GridData gd = new GridData(GridData.FILL, GridData.BEGINNING, false,
			true, 1, 1);
	composite.setLayoutData(gd);
	final FillLayout compositeLayout = new FillLayout();
	compositeLayout.marginWidth = 2;
	composite.setLayout(compositeLayout);
	final Label label = new Label(composite, SWT.NONE);
	if (this.image == null) {
		this.image = new Image(display, this.getClass().getClassLoader()
				.getResourceAsStream("images/light1.png"));
		shell.addListener(SWT.Close, new Listener() {
			@Override
			public void handleEvent(Event event) {
				image.dispose();
			}
		});

	}
	label.setImage(this.image);
}
 
开发者ID:sergueik,项目名称:SWET,代码行数:22,代码来源:TipDayEx.java

示例6: createFieldEditors

@Override
protected void createFieldEditors() {

	createJenkinsCLIFieldEditors();

	Label spacer2 = new Label(getFieldEditorParent(), SWT.LEFT);
	GridData gd2 = new GridData(GridData.HORIZONTAL_ALIGN_FILL);
	gd2.horizontalSpan = 2;
	gd2.heightHint = convertHeightInCharsToPixels(1) / 2;
	spacer2.setLayoutData(gd2);

	/* -------------------------------------------------------------- */
	/* ------------------------ APPEARANCE -------------------------- */
	/* -------------------------------------------------------------- */
	GridData appearanceLayoutData = new GridData();
	appearanceLayoutData.horizontalAlignment = GridData.FILL;
	appearanceLayoutData.verticalAlignment = GridData.BEGINNING;
	appearanceLayoutData.grabExcessHorizontalSpace = true;
	appearanceLayoutData.grabExcessVerticalSpace = false;
	appearanceLayoutData.verticalSpan = 2;
	appearanceLayoutData.horizontalSpan = 3;

	Composite appearanceComposite = new Composite(getFieldEditorParent(), SWT.NONE);
	GridLayout layout = new GridLayout();
	layout.numColumns = 2;
	appearanceComposite.setLayout(layout);
	appearanceComposite.setLayoutData(appearanceLayoutData);

	createOtherFieldEditors(appearanceComposite);

	createBracketsFieldEditors(appearanceComposite);
}
 
开发者ID:de-jcup,项目名称:eclipse-jenkins-editor,代码行数:32,代码来源:JenkinsEditorPreferencePage.java

示例7: createStandardText

public void createStandardText ( final Composite parent, final String attributeName, final int style, final String label, final String textMessage, final IObservableMap data, final Object valueType )
{
    final Label labelControl = this.toolkit.createLabel ( parent, label + ":" );

    final boolean multi = ( style & SWT.MULTI ) > 0;

    if ( multi )
    {
        labelControl.setLayoutData ( new GridData ( SWT.FILL, SWT.FILL, false, false ) );
    }

    final Text text = this.toolkit.createText ( parent, "", style );
    text.setMessage ( textMessage );
    final GridData gd = new GridData ( GridData.FILL, multi ? GridData.FILL : GridData.BEGINNING, true, true );
    gd.horizontalSpan = 2;
    text.setLayoutData ( gd );
    text.setToolTipText ( textMessage );

    final IObservableValue value = Observables.observeMapEntry ( data, attributeName, String.class );

    if ( valueType != null && valueType != String.class )
    {
        final WritableValue conversionValue = new WritableValue ( null, valueType );
        this.dbc.bindValue ( WidgetProperties.text ( SWT.Modify ).observe ( text ), conversionValue );
        this.dbc.bindValue ( conversionValue, value );
    }
    else
    {
        this.dbc.bindValue ( WidgetProperties.text ( SWT.Modify ).observe ( text ), value );
    }
}
 
开发者ID:eclipse,项目名称:neoscada,代码行数:31,代码来源:ConfigurationFormToolkit.java

示例8: initialize

protected void initialize() {
	GridData gridData3 = new GridData();
	gridData3.grabExcessHorizontalSpace = false;
	GridData gridData2 = new GridData();
	gridData2.horizontalAlignment = GridData.BEGINNING;
	gridData2.grabExcessHorizontalSpace = false;
	gridData2.horizontalSpan = 2;
	gridData2.verticalAlignment = GridData.CENTER;
	GridData gridData = new GridData();
	label1 = new Label(this, SWT.NONE);
	label1.setText("Object type");
	label1.setLayoutData(gridData);
	createCombo();
	label2 = new Label(this, SWT.NONE);
	label2.setText("Substring");
	text = new Text(this, SWT.BORDER);
	text.setLayoutData(gridData3);
	checkBox = new Button(this, SWT.CHECK);
	checkBox.setText("Match case");
	checkBox.setLayoutData(gridData2);
	GridLayout gridLayout = new GridLayout();
	gridLayout.numColumns = 2;
	this.setLayout(gridLayout);
	setSize(new Point(226, 125));
	
	combo.select(0);
	text.setText("");
}
 
开发者ID:convertigo,项目名称:convertigo-eclipse,代码行数:28,代码来源:DatabaseObjectFindDialogComposite.java

示例9: createAdvancedControls

/**
 * Creates the widget for advanced options.
 * 
 * @param parent
 *            the parent composite
 */
protected void createAdvancedControls(Composite parent) {
	Preferences preferences = ResourcesPlugin.getPlugin()
			.getPluginPreferences();

	if (preferences.getBoolean(ResourcesPlugin.PREF_DISABLE_LINKING) == false) {
		linkedResourceParent = new Composite(parent, SWT.NONE);
		linkedResourceParent.setFont(parent.getFont());
		linkedResourceParent.setLayoutData(new GridData(
				GridData.FILL_HORIZONTAL));
		GridLayout layout = new GridLayout();
		layout.marginHeight = 0;
		layout.marginWidth = 0;
		linkedResourceParent.setLayout(layout);

		advancedButton = new Button(linkedResourceParent, SWT.PUSH);
		advancedButton.setFont(linkedResourceParent.getFont());
		advancedButton.setText(IDEWorkbenchMessages.showAdvanced);
		GridData data = setButtonLayoutData(advancedButton);
		data.horizontalAlignment = GridData.BEGINNING;
		advancedButton.setLayoutData(data);
		advancedButton.addSelectionListener(new SelectionAdapter() {
			public void widgetSelected(SelectionEvent e) {
				handleAdvancedButtonSelect();
			}
		});
	}
	linkedResourceGroup = new CreateLinkedResourceGroup(IResource.FILE,
			new Listener() {
				public void handleEvent(Event e) {
					setPageComplete(validatePage());
					firstLinkCheck = false;
				}
			}, new CreateLinkedResourceGroup.IStringValue() {
				public void setValue(String string) {
					resourceGroup.setResource(string);
				}

				public String getValue() {
					return resourceGroup.getResource();
				}

				public IResource getResource() {
					IPath path = resourceGroup.getContainerFullPath();
					IWorkspaceRoot root = ResourcesPlugin.getWorkspace()
							.getRoot();
					IResource resource = root.findMember(path);
					if (resource != null && resource instanceof IContainer) {
						String resourceName = resourceGroup.getResource();
						if (resourceName.length() > 0) {
							try {
								return ((IContainer) resource).getFile(Path
										.fromOSString(resourceName));
							} catch (IllegalArgumentException e) {
								// continue below.
							}
						}
						return resource;
					}
					return resource;
				}
			});
}
 
开发者ID:bsteker,项目名称:bdf2,代码行数:68,代码来源:WizardNewFileCreationPage.java


注:本文中的org.eclipse.swt.layout.GridData.BEGINNING属性示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。