Basic workbench extension points using commands
Commands and handlers have been provided by the workbench in one form
or another since 3.0. In 3.2 the commands, handlers, and keybindings portion
of the Command Framework became mature. In 3.3 the menu contributions portion
of the Command Framework became available.
We are going to take a look at how commands, handlers, menu contributions,
and keybindings can be used to contribute behaviour to the workbench,
to views, and to editors. We'll use the Info example from the
contributions plugin. It provides a view that lists people and an
editor for updating their names. Much of the contribution of editors
and views has already been covered in the readme example in
Basic workbench extension points using actions.
You can show any view in the workbench by choosing
Window > Show View > Other...
and selecting the view from the Show View list. Use this to select the Info View from
the View Contributions category.
The Info example is located in the org.eclipse.ui.examples.contributions
package. To follow along, you will need to make sure that
you have installed the platform examples. (See the
ExamplesGuide for more information.)