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


Java TableWrapData类代码示例

本文整理汇总了Java中org.eclipse.ui.forms.widgets.TableWrapData的典型用法代码示例。如果您正苦于以下问题:Java TableWrapData类的具体用法?Java TableWrapData怎么用?Java TableWrapData使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


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

示例1: createClient

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
/**
 * @see nexcore.tool.uml.ui.core.editor.section.AbstractSection#createClient(org.eclipse.ui.forms.widgets.Section,
 *      org.eclipse.ui.forms.widgets.FormToolkit)
 */
@Override
protected void createClient(Section section, FormToolkit toolkit) {
    section.setText(UMLMessage.LABEL_DOCUMENT_INFORMATION);
    section.setDescription(UMLMessage.MESSAGE_DOCUMENT_OVERVIEW);

    TableWrapData td = new TableWrapData(TableWrapData.FILL, TableWrapData.TOP);
    td.grabHorizontal = true;

    Composite client = toolkit.createComposite(section);
    client.setLayout(new GridLayout(1, false));

    createTextControl(toolkit, client);

    initializeSection();

    section.setClient(client);
}
 
开发者ID:SK-HOLDINGS-CC,项目名称:NEXCORE-UML-Modeler,代码行数:22,代码来源:OverviewDocumentSection.java

示例2: createSection

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
/**
 * @see org.yakindu.sct.editor.sgen.extensions.IFeatureConfigurationSection#getSection()
 */
@Override
public Section createSection(final FormToolkit toolkit, final Composite parent) {
	this.section = toolkit.createSection(parent, ExpandableComposite.TITLE_BAR | ExpandableComposite.TWISTIE);
	this.section.setText(convertCamelCaseName(getFeatureType().getName(), !getFeatureType().isOptional()));
	this.section.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB, TableWrapData.FILL_GRAB));

	final Composite composite = toolkit.createComposite(this.section);
	final TableWrapLayout layout = new TableWrapLayout();
	layout.numColumns = 2;
	composite.setLayout(layout);

	for (final FeatureParameter parameter : getFeatureType().getParameters()) {
		final Control control = createParameterControl(toolkit, composite, parameter);
		this.controls.put(parameter, control);
	}

	this.section.setClient(composite);

	return this.section;
}
 
开发者ID:wendehals,项目名称:arduino_sct_tools,代码行数:24,代码来源:GenericFeatureConfigurationSection.java

示例3: createGeneralInformationSection

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
private void createGeneralInformationSection(Composite parent) {
	FormToolkit toolkit = super.getToolkit();
	Section section = toolkit.createSection(parent, Section.DESCRIPTION | Section.TITLE_BAR);
	section.setDescription(AngularCLIMessages.AngularCLIEditor_OverviewPage_GeneralInformationSection_desc);
	section.setText(AngularCLIMessages.AngularCLIEditor_OverviewPage_GeneralInformationSection_title);
	TableWrapData data = new TableWrapData(TableWrapData.FILL_GRAB);
	section.setLayoutData(data);

	Composite body = createBody(section);

	// Project name
	createText(body, AngularCLIMessages.AngularCLIEditor_OverviewPage_projectName_label, new JSONPath("project.name"));
	// project version
	createText(body, AngularCLIMessages.AngularCLIEditor_OverviewPage_projectVersion_label, new JSONPath("project.version"));

}
 
开发者ID:angelozerr,项目名称:angular-eclipse,代码行数:17,代码来源:OverviewPage.java

示例4: createGeneralInformationSection

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
private void createGeneralInformationSection(Composite parent) {
	FormToolkit toolkit = super.getToolkit();
	Section section = toolkit.createSection(parent, Section.DESCRIPTION | Section.TITLE_BAR);
	section.setDescription(TsconfigEditorMessages.OverviewPage_GeneralInformationSection_desc);
	section.setText(TsconfigEditorMessages.OverviewPage_GeneralInformationSection_title);
	TableWrapData data = new TableWrapData(TableWrapData.FILL_GRAB);
	section.setLayoutData(data);

	Composite body = createBody(section);

	// Target/Module
	createCombo(body, TsconfigEditorMessages.OverviewPage_target_label, new JSONPath("compilerOptions.target"),
			TsconfigJson.getAvailableTargets(), TsconfigJson.getDefaultTarget());
	createCombo(body, TsconfigEditorMessages.OverviewPage_module_label, new JSONPath("compilerOptions.module"),
			TsconfigJson.getAvailableModules());
	createCombo(body, TsconfigEditorMessages.OverviewPage_moduleResolution_label,
			new JSONPath("compilerOptions.moduleResolution"), TsconfigJson.getAvailableModuleResolutions(),
			TsconfigJson.getDefaultModuleResolution());
	// Others....
	createCheckbox(body, TsconfigEditorMessages.OverviewPage_experimentalDecorators_label,
			new JSONPath("compilerOptions.experimentalDecorators"));

}
 
开发者ID:angelozerr,项目名称:typescript.java,代码行数:24,代码来源:OverviewPage.java

示例5: createDebuggingSection

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
private void createDebuggingSection(Composite parent) {
	FormToolkit toolkit = super.getToolkit();
	Section section = toolkit.createSection(parent, Section.DESCRIPTION | Section.TITLE_BAR);
	section.setDescription(TsconfigEditorMessages.OutputPage_DebuggingSection_desc);
	section.setText(TsconfigEditorMessages.OutputPage_DebuggingSection_title);
	TableWrapData data = new TableWrapData(TableWrapData.FILL_GRAB);
	section.setLayoutData(data);
	Composite body = createBody(section);

	createCheckbox(body, TsconfigEditorMessages.OutputPage_sourceMap_label,
			new JSONPath("compilerOptions.sourceMap"));
	createTextAndBrowseButton(body, TsconfigEditorMessages.OutputPage_sourceRoot_label,
			new JSONPath("compilerOptions.sourceRoot"), false);
	createTextAndBrowseButton(body, TsconfigEditorMessages.OutputPage_mapRoot_label,
			new JSONPath("compilerOptions.mapRoot"), false);
	createCheckbox(body, TsconfigEditorMessages.OutputPage_inlineSourceMap_label,
			new JSONPath("compilerOptions.inlineSourceMap"));
	createCheckbox(body, TsconfigEditorMessages.OutputPage_inlineSources_label,
			new JSONPath("compilerOptions.inlineSources"));
}
 
开发者ID:angelozerr,项目名称:typescript.java,代码行数:21,代码来源:OutputPage.java

示例6: createReportingSection

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
private void createReportingSection(Composite parent) {
	FormToolkit toolkit = super.getToolkit();
	Section section = toolkit.createSection(parent, Section.DESCRIPTION | Section.TITLE_BAR);
	section.setDescription(TsconfigEditorMessages.OutputPage_ReportingSection_desc);
	section.setText(TsconfigEditorMessages.OutputPage_ReportingSection_title);
	TableWrapData data = new TableWrapData(TableWrapData.FILL_GRAB);
	section.setLayoutData(data);

	Composite body = createBody(section);

	createCheckbox(body, TsconfigEditorMessages.OutputPage_diagnostics_label,
			new JSONPath("compilerOptions.diagnostics"));
	createCheckbox(body, TsconfigEditorMessages.OutputPage_pretty_label, new JSONPath("compilerOptions.pretty"));
	createCheckbox(body, TsconfigEditorMessages.OutputPage_traceResolution_label,
			new JSONPath("compilerOptions.traceResolution"));
	createCheckbox(body, TsconfigEditorMessages.OutputPage_listEmittedFiles_label,
			new JSONPath("compilerOptions.listEmittedFiles"));
}
 
开发者ID:angelozerr,项目名称:typescript.java,代码行数:19,代码来源:OutputPage.java

示例7: createScopeSection

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
private void createScopeSection(Composite parent) {
	FormToolkit toolkit = super.getToolkit();
	Section section = toolkit.createSection(parent, Section.DESCRIPTION | Section.TITLE_BAR);
	section.setDescription(TsconfigEditorMessages.FilesPage_ScopeSection_desc);
	section.setText(TsconfigEditorMessages.FilesPage_ScopeSection_title);
	TableWrapData data = new TableWrapData(TableWrapData.FILL_GRAB);
	section.setLayoutData(data);

	Composite client = toolkit.createComposite(section);
	section.setClient(client);
	GridLayout layout = new GridLayout();
	layout.numColumns = 1;
	layout.marginWidth = 2;
	layout.marginHeight = 2;
	client.setLayout(layout);

	Table table = toolkit.createTable(client, SWT.NONE);
	GridData gd = new GridData(GridData.FILL_BOTH);
	gd.heightHint = 200;
	gd.widthHint = 100;
	table.setLayoutData(gd);
}
 
开发者ID:angelozerr,项目名称:typescript.java,代码行数:23,代码来源:FilesPage.java

示例8: createClient

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
/**
 * @see nexcore.tool.uml.ui.core.editor.section.AbstractSection#createClient(org.eclipse.ui.forms.widgets.Section,
 *      org.eclipse.ui.forms.widgets.FormToolkit)
 */
@Override
protected void createClient(Section section, FormToolkit toolkit) {
    section.setText(UMLMessage.LABEL_MODEL_LIBRARY);
    section.setDescription(UMLMessage.MESSAGE_MODEL_LIBRARY_OVERVIEW);

    TableWrapData td = new TableWrapData(TableWrapData.FILL, TableWrapData.TOP);
    td.grabHorizontal = true;

    Composite client = toolkit.createComposite(section);
    FillLayout layout = new FillLayout(SWT.VERTICAL);
    layout.marginWidth = toolkit.getBorderStyle() != SWT.NULL ? 0 : 2;
    client.setLayout(layout);

    Composite composite = toolkit.createComposite(client);
    GridLayout compositeLayout = new GridLayout();
    compositeLayout.numColumns = 2;
    composite.setLayout(compositeLayout);

    initializeSection();

    createLibraryControl(toolkit, composite);

    section.setClient(client);
}
 
开发者ID:SK-HOLDINGS-CC,项目名称:NEXCORE-UML-Modeler,代码行数:29,代码来源:DetailsModelLibrarySection.java

示例9: initialize

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
@Override
public void initialize(IManagedForm mform) {
	super.initialize(mform);
	
	FormToolkit toolkit = mform.getToolkit();
	ScrolledForm sform = mform.getForm();
	
	titleComposite = toolkit.createComposite(sform.getBody());
	titleComposite.setLayout(new GridLayout(getNumTitleComponents(), false));
       titleComposite.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB));
       
       populateTitleComposite(toolkit, sform, titleComposite);

	Composite separator = toolkit.createCompositeSeparator(sform.getBody());
	TableWrapData data = new TableWrapData(TableWrapData.FILL_GRAB, TableWrapData.TOP);
	data.maxHeight = 2;
	separator.setLayoutData(data);
}
 
开发者ID:nasa,项目名称:OpenSPIFe,代码行数:19,代码来源:TitleFormPart.java

示例10: createLabel

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
protected Label createLabel(Composite parent) {
	Label label;
	String name = getName();
	if (name == null)
		name = "";
	boolean truncated = name.length() > 20;
	if (truncated) {
		name = name.substring(0,17)+"...";
	}
	label = toolkit.createLabel(parent, name);
	String toolTipText = "";
	if (truncated) {
		toolTipText = getName();
	}
	if ((getToolTipText() != null) && (getToolTipText().trim().length() != 0)) {
		if (truncated) {
			toolTipText += " \n";
		}
		toolTipText += getToolTipText();
	}
	label.setToolTipText(toolTipText);
	label.setLayoutData(new TableWrapData(TableWrapData.LEFT, TableWrapData.MIDDLE));
	return label;
}
 
开发者ID:nasa,项目名称:OpenSPIFe,代码行数:25,代码来源:SimpleDetail.java

示例11: createFormText

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
/**
   * Creates a form text.
   *
   * @param parent the parent to put the form text on
   * @param text the form text to be displayed
   * @return the created form text
   *
   * @see FormToolkit#createFormText(org.eclipse.swt.widgets.Composite, boolean)
   */
  private FormText createFormText(Composite parent, String text) {
      FormToolkit toolkit= new FormToolkit(getShell().getDisplay());
      try {
      	FormText formText= toolkit.createFormText(parent, true);
      	formText.setFont(parent.getFont());
	try {
	    formText.setText(text, true, false);
	} catch (IllegalArgumentException e) {
	    formText.setText(e.getMessage(), false, false);
	    JavaPlugin.log(e);
	}
	formText.marginHeight= 2;
	formText.marginWidth= 0;
	formText.setBackground(null);
	formText.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB));
	return formText;
} finally {
       toolkit.dispose();
}
  }
 
开发者ID:trylimits,项目名称:Eclipse-Postfix-Code-Completion,代码行数:30,代码来源:HintTextGroup.java

示例12: createPluginsSection

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
private void createPluginsSection(Composite parent) {
	Section sctnPlugins = createSection(parent, "Plug-ins");
	sctnPlugins.setLayout(FormUtils.createClearTableWrapLayout(false, 1));
	TableWrapData data = new TableWrapData(TableWrapData.FILL_GRAB);
	sctnPlugins.setLayoutData(data);

	FormText text = formToolkit.createFormText(sctnPlugins, true);
	ImageDescriptor idesc = HybridUI.getImageDescriptor(HybridUI.PLUGIN_ID, "/icons/etool16/cordovaplug_wiz.png");
	text.setImage("plugin", idesc.createImage());

	text.setText(PLUGINS_SECTION_CONTENT, true, false);

	sctnPlugins.setClient(text);
	text.addHyperlinkListener(this);

}
 
开发者ID:eclipse,项目名称:thym,代码行数:17,代码来源:EssentialsPage.java

示例13: createAuthorSection

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
private void createAuthorSection(Composite parent) {
	Section sctnAuthor = createSection(parent, "Author");
	sctnAuthor.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB));

	Composite composite = formToolkit.createComposite(sctnAuthor, SWT.WRAP);
	formToolkit.paintBordersFor(composite);
	sctnAuthor.setClient(composite);
	composite.setLayout(FormUtils.createSectionClientGridLayout(false, 2));

	createFormFieldLabel(composite, "Name:");

	txtAuthorname = formToolkit.createText(composite, "", SWT.WRAP);
	txtAuthorname.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, false, 1, 1));

	createFormFieldLabel(composite, "Email:");

	txtEmail = formToolkit.createText(composite, "", SWT.NONE);
	txtEmail.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, false, 1, 1));

	createFormFieldLabel(composite, "URL:");

	txtUrl = formToolkit.createText(composite, "", SWT.NONE);
	txtUrl.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, false, 1, 1));
}
 
开发者ID:eclipse,项目名称:thym,代码行数:25,代码来源:EssentialsPage.java

示例14: createClient

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
protected void createClient(Section section, FormToolkit toolkit) {
    section.setText("Configurations"); //$NON-NLS-1$
    String desc = "This section describe the configurations defined in your project";
    section.setDescription(desc);

    Composite client = toolkit.createComposite(section);
    TableWrapLayout layout = new TableWrapLayout();
    layout.rightMargin = toolkit.getBorderStyle() != SWT.NULL ? 0 : 2;
    layout.leftMargin = layout.rightMargin;
    layout.numColumns = NUM_COLUMNS;
    client.setLayout(layout);

    toolkit.paintBordersFor(client);
    section.setClient(client);
    TableWrapData td = new TableWrapData(TableWrapData.FILL_GRAB);
    td.colspan = 2;
    section.setLayoutData(td);
}
 
开发者ID:apache,项目名称:ant-ivyde,代码行数:19,代码来源:IvyConfSection.java

示例15: createSecondSection

import org.eclipse.ui.forms.widgets.TableWrapData; //导入依赖的package包/类
private void createSecondSection( ScrolledForm form, FormToolkit toolkit) {
	ExpandableComposite ec = toolkit.createExpandableComposite(form.getBody(), 
		     ExpandableComposite.TREE_NODE|
		     ExpandableComposite.CLIENT_INDENT);
		 ec.setText("Expandable Composite title");
		 String ctext = "We will now create a somewhat long text so that "+
		 "we can use it as content for the expandable composite. "+
		 "Expandable composite is used to hide or show the text using the " +
		 "toggle control";
		 Label client = toolkit.createLabel(ec, ctext, SWT.WRAP);
		 ec.setClient(client);
		 TableWrapData  td = new TableWrapData();
		 td.colspan = 2;
		 ec.setLayoutData(td);
		 ec.addExpansionListener(new ExpansionAdapter() {
		  @Override
		public void expansionStateChanged(ExpansionEvent e) {
		   form.reflow(true);
		  }
		 });

	
}
 
开发者ID:vogellacompany,项目名称:codeexamples-eclipse,代码行数:24,代码来源:FormsPart.java


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