Keyboard navigation refers to an alternative means of
interacting with an application without using a mouse. In particular,
it involves interaction with elements of the graphical user interface
(GUI), such as menus and buttons. In the graphical framework, you
can use keystrokes to move through the contents.
A JViews application
consists essentially of Swing GUI components and graphic objects inside
a manager view.
Keyboard navigation for Swing components is provided
with the JDK. Some Swing elements interpret the Tab key specifically
or act as a pseudo-focus cycle root, for example multiline text fields,
JTrees, and JTables. For these components, you must use Ctrl+Tab to
navigate out of the component. You can use Tab and Ctrl+Tab to navigate
through all elements of the GUI. Use Enter, Esc, and the Arrow keys
to operate menus, combination boxes, and buttons. You can assign shortcut
keys to the most important menus and buttons by using JMenuItem.setAccelerator(KeyStroke) and AbstractButton.setMnemonic(int).
You can implement navigation and operation on graphic
objects (instances of
IlvGraphic)
by using the keyboard accelerators (
IlvAccelerator and its subclasses). Keyboard accelerators are associated with a
key event and installed at the highest level manager of a view. The
accelerators also apply to a submanager of the highest level manager.
For details, see
Handling input events: interactors and accelerators.
Navigation between graphic objects is handled by the
selection mechanism of the manager. For details, see
Selection in a manager. The selection handle shows you which object is currently selected.
You can find a sample that illustrates the accessibility
features of the JViews Framework in <installdir>/jviews-frameworkxx/samples/accessibility.