本文整理匯總了Java中org.eclipse.ui.forms.widgets.ScrolledForm.setText方法的典型用法代碼示例。如果您正苦於以下問題:Java ScrolledForm.setText方法的具體用法?Java ScrolledForm.setText怎麽用?Java ScrolledForm.setText使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類org.eclipse.ui.forms.widgets.ScrolledForm
的用法示例。
在下文中一共展示了ScrolledForm.setText方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: createFormContent
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
@Override
protected void createFormContent(IManagedForm managedForm) {
FormToolkit toolkit=managedForm.getToolkit();
ScrolledForm form=managedForm.getForm();
form.setText("流程模版導出與部署");
ColumnLayout layout=new ColumnLayout();
layout.topMargin=0;
layout.bottomMargin=0;
layout.leftMargin=0;
layout.rightMargin=0;
layout.maxNumColumns=1;
layout.horizontalSpacing=5;
layout.verticalSpacing=5;
form.getBody().setLayout(layout);
this.createExportSection(toolkit, form);
this.createOnlineDeploymentSection(toolkit, form);
}
示例2: createFormContent
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
/**
* @see org.eclipse.ui.forms.editor.FormPage#createFormContent(org.eclipse.ui.forms.IManagedForm)
*/
@Override
protected void createFormContent(final IManagedForm managedForm) {
final FormToolkit toolkit = managedForm.getToolkit();
final ScrolledForm scrolledForm = managedForm.getForm();
scrolledForm.setText(Messages.GeneratorEntryFormPage_formPageHeaderPrefix + getStatechartName());
final Form form = scrolledForm.getForm();
toolkit.decorateFormHeading(form);
final IToolBarManager toolBarManager = form.getToolBarManager();
toolBarManager.add(createGenerateAction());
form.updateToolBar();
final Composite body = scrolledForm.getBody();
body.setLayout(new TableWrapLayout());
createSections(toolkit, body);
startListeningToModelChanges();
}
示例3: createFormContent
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
@Override
protected void createFormContent(IManagedForm managedForm) {
final ScrolledForm form = managedForm.getForm();
FormToolkit toolkit = managedForm.getToolkit();
toolkit.decorateFormHeading(form.getForm());
IToolBarManager manager = form.getToolBarManager();
if (contributeToToolbar(manager)) {
form.updateToolBar();
}
String titleText = getFormTitleText();
if (titleText != null) {
form.setText(titleText);
}
Image titleImage = getFormTitleImage();
if (titleImage != null) {
form.setImage(titleImage);
}
toolkit.decorateFormHeading(form.getForm());
createUI(managedForm);
}
示例4: createPartControl
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
/**
* Create contents of the editor part.
* @param parent
*/
@Override
public void createPartControl(Composite parent) {
FormToolkit toolkit = new FormToolkit(parent.getDisplay());
ScrolledForm form = toolkit.createScrolledForm(parent);
form.setText("Analyser");
form.getBody().setLayout(new FillLayout(SWT.HORIZONTAL));
// Creating the Screen
Section section = toolkit.createSection(form.getBody(), Section.DESCRIPTION
| Section.TITLE_BAR);
section.setText("Section 1 for demonstration"); //$NON-NLS-1$
section.setDescription("This demonstrates the usage of section");
// Composite for storing the data
Composite client = toolkit.createComposite(section, SWT.WRAP);
toolkit.paintBordersFor(client);
section.setClient(client);
// Lets make a layout for the first section of the screen
GridLayout layout = new GridLayout();
layout.numColumns = 1;
layout.marginWidth = 2;
layout.marginHeight = 2;
}
示例5: createPartControl
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
/**
* Create contents of the editor part.
* @param parent
*/
@Override
public void createPartControl(Composite parent) {
FormToolkit toolkit = new FormToolkit(parent.getDisplay());
ScrolledForm form = toolkit.createScrolledForm(parent);
form.setText("Spotter");
form.getBody().setLayout(new FillLayout(SWT.HORIZONTAL));
// Creating the Screen
Section section = toolkit.createSection(form.getBody(), Section.DESCRIPTION
| Section.TITLE_BAR);
section.setText("Section 1 for demonstration"); //$NON-NLS-1$
section.setDescription("This demonstrates the usage of section");
// Composite for storing the data
Composite client = toolkit.createComposite(section, SWT.WRAP);
toolkit.paintBordersFor(client);
section.setClient(client);
// Lets make a layout for the first section of the screen
GridLayout layout = new GridLayout();
layout.numColumns = 1;
layout.marginWidth = 2;
layout.marginHeight = 2;
}
示例6: createPartControl
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
/**
* Create contents of the editor part.
* @param parent
*/
@Override
public void createPartControl(Composite parent) {
FormToolkit toolkit = new FormToolkit(parent.getDisplay());
ScrolledForm form = toolkit.createScrolledForm(parent);
form.setText("Main");
FillLayout fillLayout = new FillLayout(SWT.HORIZONTAL);
fillLayout.spacing = 15;
form.getBody().setLayout(fillLayout);
Composite leftComposite = toolkit.createComposite(form.getBody(), SWT.NONE);
toolkit.paintBordersFor(leftComposite);
FillLayout fl_leftComposite = new FillLayout(SWT.VERTICAL);
fl_leftComposite.spacing = 10;
leftComposite.setLayout(fl_leftComposite);
Composite rightComposite = new Composite(form.getBody(), SWT.NONE);
toolkit.adapt(rightComposite);
toolkit.paintBordersFor(rightComposite);
FillLayout fl_rightComposite = new FillLayout(SWT.VERTICAL);
fl_rightComposite.spacing = 10;
rightComposite.setLayout(fl_rightComposite);
}
示例7: createFormContent
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
protected void createFormContent(IManagedForm managedForm) {
// 通過managedForm對象獲得表單工具對象
toolkit = managedForm.getToolkit();
// 通過managedForm對象獲得ScrolledForm可滾動的表單對象
ScrolledForm form = managedForm.getForm();
// 設置表單文本
form.setText("這是第一頁,Hello, Eclipse 表單");
// 創建表格布局
TableWrapLayout layout = new TableWrapLayout();
layout.numColumns = 1;// 表格的列數
layout.bottomMargin = 0;// 下補白
layout.topMargin = 0;// 上補白
layout.leftMargin = 0;// 左補白
layout.rightMargin = 0;// 右補白
form.getBody().setLayout(layout);// 設置表格的布局
form.getBody().setBackground(
form.getBody().getDisplay()
.getSystemColor(SWT.COLOR_WIDGET_BACKGROUND));
}
示例8: createFormContent
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
@Override
protected void createFormContent(IManagedForm managedForm) {
ScrolledForm form = managedForm.getForm();
form.setText(getTitle());
form.setImage(MuleImages.GLOBALS_TITLE_IMAGE);
//configure the layout of the form
GridLayout layout = new GridLayout();
layout.numColumns = 3;
layout.makeColumnsEqualWidth = true;
GridData configData = new GridData(GridData.FILL_BOTH);
configData.horizontalSpan = 2;
//to be fixed
form.getBody().setLayout(layout);
projectsPart = new DomainProjectsSectionPart(form.getBody(), managedForm.getToolkit(), model.getModules(), model.getProject());
projectsPart.getSection().setLayoutData(new GridData(GridData.FILL_BOTH));
}
示例9: createScrolledForm
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
public ScrolledForm createScrolledForm ( final Composite parent, final String label )
{
final ScrolledForm form = this.toolkit.createScrolledForm ( parent );
form.setText ( label );
this.toolkit.decorateFormHeading ( form.getForm () );
return form;
}
示例10: createFormContent
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
@Override
protected void createFormContent(IManagedForm managedForm) {
FormToolkit toolkit = managedForm.getToolkit();
ScrolledForm form = managedForm.getForm();
form.setText("Description");
Composite body = form.getBody();
toolkit.decorateFormHeading(form.getForm());
toolkit.paintBordersFor(body);
body.setLayout(new FillLayout());
DescriptionSection detailsSection = new DescriptionSection(managedForm.getForm().getBody(), toolkit, Section.NO_TITLE, site);
detailsSection.setFormInput(solution);
}
示例11: createFormContent
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
protected void createFormContent(final IManagedForm managedForm) {
final ScrolledForm form = managedForm.getForm();
FormToolkit toolkit = managedForm.getToolkit();
form.setText("HanMeiMei Automation");
toolkit.decorateFormHeading(form.getForm());
form.getForm().addMessageHyperlinkListener(new HyperlinkAdapter());
form.getMessageManager().setDecorationPosition(SWT.RIGHT | SWT.BOTTOM);
block.createContent(managedForm);
}
示例12: createFormContent
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
protected void createFormContent(IManagedForm managedForm) {
super.createFormContent(managedForm);
ScrolledForm form = managedForm.getForm();
form.setText("Overview");
fillBody(managedForm);
managedForm.refresh();
}
示例13: createPartControl
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
/**
* Create contents of the editor part.
* @param parent
*/
@Override
public void createPartControl(Composite parent) {
FormToolkit toolkit = new FormToolkit(parent.getDisplay());
ScrolledForm form = toolkit.createScrolledForm(parent);
form.setText("Extractor");
form.getBody().setLayout(new FillLayout(SWT.HORIZONTAL));
// Creating the Screen
// Basic composite
{
Section section = toolkit.createSection(form.getBody(), Section.DESCRIPTION
| Section.TITLE_BAR);
section.setText("Extracted models"); //$NON-NLS-1$
section.setDescription("Location of extracted PCM models used for this component.");
// Composite for storing the data
BasicExtractorComposite client = new BasicExtractorComposite(parent, this.input.getSoftwareService());
client.setParent(section);
toolkit.paintBordersFor(client);
section.setClient(client);
}
// Lets make a layout for the first section of the screen
GridLayout layout = new GridLayout();
layout.numColumns = 1;
layout.marginWidth = 2;
layout.marginHeight = 2;
}
示例14: createPartControl
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
@PostConstruct
public void createPartControl(Composite parent) {
FormToolkit toolkit = new FormToolkit(parent.getDisplay());
ScrolledForm form = toolkit.createScrolledForm(parent);
toolkit.decorateFormHeading(form.getForm());
form.setText("Eclipse Forms API Example");
createFirstSection(parent, toolkit);
createSecondSection(form, toolkit);
}
示例15: construct
import org.eclipse.ui.forms.widgets.ScrolledForm; //導入方法依賴的package包/類
@Override
public Control construct(Composite parent) {
// TODO Auto-generated method stub
final FormToolkit toolkit = new FormToolkit(parent.getDisplay());
final ScrolledForm form = toolkit.createScrolledForm(parent);
form.setLayoutData(new GridData(GridData.FILL_BOTH));
form.setText("Form with subpages");
form.setFocus();
form.getBody().setLayout(new GridLayout());
ScrolledPageBook pageBook = toolkit.createPageBook(form.getBody(),
SWT.V_SCROLL | SWT.H_SCROLL);
// pageBook.showEmptyPage();
Composite page1 = pageBook.createPage("First Page");
Text text1 = toolkit.createText(page1, "First Page", SWT.MULTI
| SWT.WRAP);
page1.setLayout(new GridLayout());
text1.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
GridData gd = new GridData(GridData.FILL_HORIZONTAL);
gd.heightHint = 0;
pageBook.setLayoutData(gd);
Composite page2 = pageBook.createPage("Second Page");
Text text2 = toolkit.createText(page1, "Second Page", SWT.MULTI
| SWT.WRAP);
page2.setLayout(new GridLayout());
text2.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
pageBook.showPage("First Page");
// pageBook.showPage(page2);
pageBook.getCurrentPage();
return null;
}