public class TabPane
  Comment     Returned-by     Constructor-argument     Method-argument     Field-type     Type-bound     Links  

A control that allows switching between a group of Tabs. Only one tab is visible at a time. Tabs are added to the TabPane by using the getTabs.

Tabs in a TabPane can be positioned at any of the four sides by specifying the Side.

A TabPane has two modes floating or recessed. Applying the styleclass STYLE_CLASS_FLOATING will change the TabPane mode to floating.

The tabs width and height can be set to a specific size by setting the min and max for height and width. TabPane default width will be determined by the largest content width in the TabPane. This is the same for the height. If a different size is desired the width and height of the TabPane can be overridden by setting the min, pref and max size.

When the number of tabs do not fit the TabPane a menu button will appear on the right. The menu button is used to select the tabs that are currently not visible.


 TabPane tabPane = new TabPane();
 Tab tab = new Tab();
 tab.setText("new tab");
 tab.setContent(new Rectangle(200,200, Color.LIGHTSTEELBLUE));

extends Control

See also:

Since:  JavaFX 2.0