multi-page editor [message #447968] |
Tue, 18 April 2006 14:19 |
Karl Messages: 92 Registered: July 2009 |
Member |
|
|
Hello!
Have an example of an multi-page editor, but I can't combine these two
technics: when I use new TableWrapData and CTabFolder I get an empty
editor page!
Full Example Download: http://www.office2day.com/framemultipage.zip
toolkit.createLabel(form.getBody(), "3. db zugriff?").setBackground(new
Color(null, 150,150,150));
Text text3 = toolkit.createText(form.getBody(), "Hier Text eingeben",
SWT.BORDER); //$NON-NLS-1$
td = new TableWrapData();
td.colspan = 2;
text3.setLayoutData(td);
GridLayout layout2 = new GridLayout(3, true);
layout2.numColumns = 1;
form.getBody().setLayout(layout2);
form.getBody().setLayout(layout);
tabFolder = new CTabFolder(form.getBody(), SWT.FLAT|SWT.TOP);
toolkit.adapt(tabFolder, true, true);
GridData gd = new GridData(GridData.FILL_HORIZONTAL);
gd.heightHint = 0;
tabFolder.setLayoutData(gd);
Color selectedColor = toolkit.getColors().getColor(FormColors.SEPARATOR);
tabFolder.setSelectionBackground(new Color[] {selectedColor,
toolkit.getColors().getBackground()}, new int[] {50});
//tabFolder.setCursor(FormsResources.getHandCursor());
toolkit.paintBordersFor(tabFolder);
createTabs(toolkit);
createText(toolkit, form.getBody());
|
|
|
Re: multi-page editor [message #448349 is a reply to message #447968] |
Fri, 21 April 2006 13:19 |
Karl Messages: 92 Registered: July 2009 |
Member |
|
|
I solved the problem with groups:
final org.eclipse.swt.widgets.Group group = new
org.eclipse.swt.widgets.Group(form.getBody(), SWT.NONE);
toolkit2.adapt(group);
group.setText("Group in Form?");
thx...
Karl schrieb:
> Hello!
>
> Have an example of an multi-page editor, but I can't combine these two
> technics: when I use new TableWrapData and CTabFolder I get an empty
> editor page!
>
> Full Example Download: http://www.office2day.com/framemultipage.zip
>
> toolkit.createLabel(form.getBody(), "3. db zugriff?").setBackground(new
> Color(null, 150,150,150));
> Text text3 = toolkit.createText(form.getBody(), "Hier Text eingeben",
> SWT.BORDER); //$NON-NLS-1$
> td = new TableWrapData();
> td.colspan = 2;
> text3.setLayoutData(td);
>
> GridLayout layout2 = new GridLayout(3, true);
> layout2.numColumns = 1;
> form.getBody().setLayout(layout2);
>
> form.getBody().setLayout(layout);
> tabFolder = new CTabFolder(form.getBody(), SWT.FLAT|SWT.TOP);
> toolkit.adapt(tabFolder, true, true);
> GridData gd = new GridData(GridData.FILL_HORIZONTAL);
> gd.heightHint = 0;
> tabFolder.setLayoutData(gd);
> Color selectedColor = toolkit.getColors().getColor(FormColors.SEPARATOR);
> tabFolder.setSelectionBackground(new Color[] {selectedColor,
> toolkit.getColors().getBackground()}, new int[] {50});
> //tabFolder.setCursor(FormsResources.getHandCursor());
>
> toolkit.paintBordersFor(tabFolder);
> createTabs(toolkit);
> createText(toolkit, form.getBody());
|
|
|
Powered by
FUDForum. Page generated in 0.03330 seconds