java.lang.Object | ||||
↳ | com.google.gwt.user.client.ui.UIObject | |||
↳ | com.google.gwt.user.client.ui.Widget | |||
↳ | com.google.gwt.user.client.ui.Composite | |||
↳ | com.google.gwt.user.client.ui.TabPanel |
Known Direct Subclasses |
A panel that represents a tabbed set of pages, each of which contains another widget. Its child widgets are shown as the user selects the various tabs associated with them. The tabs can contain arbitrary HTML.
This widget will only work in quirks mode. If your application is in
Standards Mode, use TabLayoutPanel
instead.
Note that this widget is not a panel per se, but rather a
Composite
that aggregates a
TabBar
and a
DeckPanel
. It does, however, implement
HasWidgets
.
[Expand]
Inherited Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
com.google.gwt.user.client.ui.UIObject
|
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Creates an empty tab panel.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Convenience overload to allow
IsWidget to be used directly. | |||||||||||
Adds a widget to the tab panel.
| |||||||||||
Adds a widget to the tab panel.
| |||||||||||
Convenience overload to allow
IsWidget to be used directly. | |||||||||||
Adds a child widget.
| |||||||||||
Convenience overload to allow
IsWidget to be used directly. | |||||||||||
Adds a widget to the tab panel.
| |||||||||||
This method is deprecated.
Use
addBeforeSelectionHandler(BeforeSelectionHandler and addSelectionHandler(SelectionHandler instead
| |||||||||||
Removes all child widgets.
| |||||||||||
Gets the deck panel within this tab panel.
| |||||||||||
Gets the tab bar within this tab panel.
| |||||||||||
Gets the child widget at the specified index.
| |||||||||||
Gets the number of child widgets in this panel.
| |||||||||||
Convenience overload to allow
IsWidget to be used directly. | |||||||||||
Gets the index of the specified child widget.
| |||||||||||
Convenience overload to allow
IsWidget to be used directly. | |||||||||||
Inserts a widget into the tab panel.
| |||||||||||
Convenience overload to allow
IsWidget to be used directly. | |||||||||||
Inserts a widget into the tab panel.
| |||||||||||
Convenience overload to allow
IsWidget to be used directly. | |||||||||||
Inserts a widget into the tab panel.
| |||||||||||
Returns true if animations are enabled, false if not.
| |||||||||||
Gets an iterator for the contained widgets.
| |||||||||||
This method is deprecated.
Use
onBeforeSelection(BeforeSelectionEvent instead
| |||||||||||
This method is deprecated.
Use
onSelection(SelectionEvent instead
| |||||||||||
Removes the given widget, and its associated tab.
| |||||||||||
Removes the widget at the specified index.
| |||||||||||
This method is deprecated.
Use the
removeHandler()
method on the object returned by and add*Handler method instead
| |||||||||||
Programmatically selects the specified tab and fires events.
| |||||||||||
Programmatically selects the specified tab.
| |||||||||||
Enable or disable animations.
|
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Create a
SimplePanel that will wrap the contents in a tab. | |||||||||||
Affected Elements:
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
com.google.gwt.user.client.ui.Composite
| |||||||||||
From class
com.google.gwt.user.client.ui.Widget
| |||||||||||
From class
com.google.gwt.user.client.ui.UIObject
| |||||||||||
From class
java.lang.Object
| |||||||||||
From interface com.google.gwt.event.logical.shared.HasAttachHandlers | |||||||||||
From interface com.google.gwt.event.logical.shared.HasBeforeSelectionHandlers | |||||||||||
From interface com.google.gwt.event.logical.shared.HasSelectionHandlers | |||||||||||
From interface com.google.gwt.event.shared.HasHandlers | |||||||||||
From interface
com.google.gwt.user.client.EventListener
| |||||||||||
From interface
com.google.gwt.user.client.ui.HasAnimation
| |||||||||||
From interface
com.google.gwt.user.client.ui.HasWidgets
| |||||||||||
From interface
com.google.gwt.user.client.ui.IndexedPanel
| |||||||||||
From interface
com.google.gwt.user.client.ui.IndexedPanel.ForIsWidget
| |||||||||||
From interface
com.google.gwt.user.client.ui.IsWidget
| |||||||||||
From interface
com.google.gwt.user.client.ui.SourcesTabEvents
| |||||||||||
From interface
com.google.gwt.user.client.ui.TabListener
| |||||||||||
From interface
java.lang.Iterable
|
Creates an empty tab panel.
Convenience overload to allow IsWidget
to be used directly.
Adds a widget to the tab panel. If the Widget is already attached to the TabPanel, it will be moved to the right-most index.
w | the widget to be added |
---|---|
tabWidget | the widget to be shown in the tab |
Adds a widget to the tab panel. If the Widget is already attached to the TabPanel, it will be moved to the right-most index.
w | the widget to be added |
---|---|
tabText | the text to be shown on its tab |
asHTML | true to treat the specified text as HTML
|
Convenience overload to allow IsWidget
to be used directly.
Convenience overload to allow IsWidget
to be used directly.
Adds a widget to the tab panel. If the Widget is already attached to the TabPanel, it will be moved to the right-most index.
w | the widget to be added |
---|---|
tabText | the text to be shown on its tab |
This method is deprecated.
Use addBeforeSelectionHandler(BeforeSelectionHandler
and addSelectionHandler(SelectionHandler
instead
Adds a listener interface to receive click events.
listener | the listener interface to add |
---|
Removes all child widgets.
Gets the deck panel within this tab panel. Adding or removing Widgets from the DeckPanel is not supported and will throw UnsupportedOperationExceptions.
Gets the tab bar within this tab panel. Adding or removing tabs from from the TabBar is not supported and will throw UnsupportedOperationExceptions.
Gets the child widget at the specified index.
index | the child widget's index |
---|
Gets the number of child widgets in this panel.
Convenience overload to allow IsWidget
to be used directly.
Gets the index of the specified child widget.
widget | the widget to be found |
---|
-1
if it is not a child of this
panel
Convenience overload to allow IsWidget
to be used directly.
Inserts a widget into the tab panel. If the Widget is already attached to the TabPanel, it will be moved to the requested index.
widget | the widget to be inserted |
---|---|
tabText | the text to be shown on its tab |
beforeIndex | the index before which it will be inserted |
Convenience overload to allow IsWidget
to be used directly.
Inserts a widget into the tab panel. If the Widget is already attached to the TabPanel, it will be moved to the requested index.
widget | the widget to be inserted. |
---|---|
tabWidget | the widget to be shown on its tab. |
beforeIndex | the index before which it will be inserted. |
Convenience overload to allow IsWidget
to be used directly.
Inserts a widget into the tab panel. If the Widget is already attached to the TabPanel, it will be moved to the requested index.
widget | the widget to be inserted |
---|---|
tabText | the text to be shown on its tab |
asHTML | true to treat the specified text as HTML |
beforeIndex | the index before which it will be inserted |
Returns true if animations are enabled, false if not.
Gets an iterator for the contained widgets. This iterator is required to
implement remove()
.
This method is deprecated.
Use onBeforeSelection(BeforeSelectionEvent
instead
Fired just before a tab is selected.
sender | the TabBar or TabPanel whose tab was
selected. |
---|---|
tabIndex | the index of the tab about to be selected |
false
to disallow the selection. If any listener
returns false, then the selection will be disallowed.Removes the given widget, and its associated tab.
widget | the widget to be removed |
---|
true
if the widget was present
Removes the widget at the specified index.
index | the index of the widget to be removed |
---|
false
if the widget is not present
This method is deprecated.
Use the removeHandler()
method on the object returned by and add*Handler method instead
Removes a previously added listener interface.
listener | the listener interface to remove |
---|
Programmatically selects the specified tab and fires events.
index | the index of the tab to be selected |
---|
Programmatically selects the specified tab.
index | the index of the tab to be selected |
---|---|
fireEvents | true to fire events, false not to |
Enable or disable animations.
enable | true to enable, false to disable |
---|
Create a SimplePanel
that will wrap the contents in a tab.
Subclasses can use this method to wrap tabs in decorator panels.
SimplePanel
to wrap the tab contents, or null to leave
tabs unwrapped
Affected Elements:
baseID | the base ID used by the main element |
---|