- Loading...
Author: Dusan Pavlica
This document is the user experience specification for the JavaFX Tabs control.
A TabView is a UI control that allows multiple documents to be contained within a single window and switch between them. Tabs can be placed on any side of a document area or nested. Typically there is a TabView header and a content area. Every tab in the header can contain an icon, a title, and a close button.
Figure: Basic parts of a TabView UI control
There are a few basic states of tabs. Tab can be selected, not selected, disabled, or it there is an visual effect when mouse is above the tab.
Figure: Basic states of tabs
Let's mention features that are sort of standard ones and you can find them in most of TabView implementations
There are additional features that can make TabView UI control even more advanced, so let's see a few of them:
The following table describes how keystrokes should be processed in case a TabView has focus:
Keystroke | Action |
---|---|
LEFT/UP Arrow | When focus is on a tab in the TabPane header, move focus to the previous tab and display its corresponding page. |
RIGHT/DOWN Arrow | When focus is on a tab in the TabPane header, move focus to the next tab and display its corresponding page. |
HOME | When focus is on a tab in the TabPane header, move focus to the first tab and display its corresponding page. |
END | When focus is on a tab in the TabPane header, move focus to the last tab and display its corresponding page. |
CTRL-TAB/ CTRL-PAGE DOWN | Move focus to the next tab and display its corresponding page. Wrap from last to first. |
CTRL-SHIFT-TAB/ CTRL-PAGE UP | Move focus to the previous tab and display its corresponding page. Wrap from first to last. |
TAB | Move focus to the next control in selected tab. If focus is on the last control, move focus to the next focusable control outside the TabPane. |
SHIFT-TAB | Moves focus to the previous control in selected tab. If focus is on the first control, move focus to the selected tab in the TabPane header. If focus is on the selected tab, move focus to the previous focusable control outside the TabPane. |