Difference between revisions of "Nebula Breadcrumb"
Line 11: | Line 11: | ||
=Usage= | =Usage= | ||
− | This is very simple : you instantiate a Breadcrumb object and then you create BreadcrumbItems : | + | This is very simple : you instantiate a <code>Breadcrumb</code> object and then you create <code>BreadcrumbItems</code> (it works like the SWT '''Toolbar'''): |
final Breadcrumb bc = new Breadcrumb(shell, breadCrumbArgument); | final Breadcrumb bc = new Breadcrumb(shell, breadCrumbArgument); | ||
Line 20: | Line 20: | ||
And ''voilà''! | And ''voilà''! | ||
− | The BreadcrumbItem can be labels (style SWT.NONE), buttons (style SWT.PUSH) or toggle buttons (style SWT.TOGGLE). | + | The BreadcrumbItem can be labels (style <code>SWT.NONE</code>), buttons (style <code>SWT.PUSH</code>) or toggle buttons (style <code>SWT.TOGGLE</code>). |
=Examples= | =Examples= | ||
Line 27: | Line 27: | ||
This example is also available here : | This example is also available here : | ||
− | [https:// | + | [https://github.com/eclipse/nebula/blob/master/widgets/opal/breadcrumb/org.eclipse.nebula.widgets.opal.breadcrumb.snippets/src/org/eclipse/nebula/widgets/opal/breadcrumb/snippets/BreadcrumbSnippet.java BreadcrumbSnippet.java] |
Latest revision as of 06:07, 19 March 2020
Introduction
A simple breadcrumb toolbar.
Contents
Usage
This is very simple : you instantiate a Breadcrumb
object and then you create BreadcrumbItems
(it works like the SWT Toolbar):
final Breadcrumb bc = new Breadcrumb(shell, breadCrumbArgument); final BreadcrumbItem item = new BreadcrumbItem(bc, SWT.PUSH); item.setText("Text");
And voilà!
The BreadcrumbItem can be labels (style SWT.NONE
), buttons (style SWT.PUSH
) or toggle buttons (style SWT.TOGGLE
).
Examples
An example called BreadcrumbSnippet.java is located in the plugin org.eclipse.nebula.widgets.opal.breadcrumb.snippets.
This example is also available here : BreadcrumbSnippet.java