NiftyControlTabGroupControlpublic interface TabGroup extends NiftyControl
| Modifier and Type | Method | Description |
|---|---|---|
void |
addTab(Tab tab) |
Adds a single tab to the end of the tab list.
|
void |
addTab(TabBuilder tabBuilder) |
Add a tab builder to the list.
|
void |
addTab(Element tab) |
Adds a single tab to the end of the tab list.
|
Tab |
getSelectedTab() |
Get the tab that is currently selected.
|
int |
getSelectedTabIndex() |
Get the index of the tab that is currently selected.
|
Tab |
getTabAtIndex(int index) |
Get the tab control at a specified index.
|
int |
getTabCount() |
Get the amount of tabs that are currently part of this tab group.
|
int |
indexOf(Tab tab) |
Get the index of a specified tab.
|
boolean |
isTabInGroup(Tab tab) |
Check if a tab is part of this group.
|
void |
removeTab(int index) |
Removes the tab at a specified list index.
|
void |
removeTab(int index,
EndNotify notify) |
Removes the tab at a specified list index.
|
void |
removeTab(Tab tab) |
Remove a tab from this tab group.
|
void |
removeTab(Tab tab,
EndNotify notify) |
Remove a tab from this tab group.
|
void |
removeTab(Element tab) |
Remove a tab from this tab group.
|
void |
removeTab(Element tab,
EndNotify notify) |
Remove a tab from this tab group.
|
void |
setSelectedTab(Tab tab) |
Change the selected tab to a specified tab.
|
void |
setSelectedTabIndex(int index) |
Change the selected tab to a index.
|
void |
setTabCaption(int index,
java.lang.String caption) |
Set the caption of a tab.
|
void |
setTabCaption(Tab tab,
java.lang.String caption) |
Set the caption of a tab.
|
disable, enable, getElement, getHeight, getId, getStyle, getWidth, hasFocus, isBound, isEnabled, layoutCallback, setEnabled, setFocus, setFocusable, setHeight, setId, setStyle, setWidthvoid addTab(@Nonnull
Tab tab)
tab - the tab that is supposed to be added to the tab groupvoid addTab(@Nonnull
Element tab)
tab - the tab that is supposed to be added to the tab groupjava.lang.IllegalArgumentException - in case the tab does not contain a Tab as registered controlvoid addTab(@Nonnull
TabBuilder tabBuilder)
ElementBuilder.build(de.lessvoid.nifty.Nifty, de.lessvoid.nifty.screen.Screen, Element) function.tabBuilder - the builder that is going to construct the tab that will be added to this tab group@Nullable Tab getSelectedTab()
null in case there are no tabs in this tab groupint getSelectedTabIndex()
-1 in case there are no tabs in this groupint getTabCount()
int indexOf(@Nonnull
Tab tab)
tab - the tab to check-1 in case the tab is not part of this group or nullboolean isTabInGroup(@Nonnull
Tab tab)
tab - the tab to checktrue in case the tab is registered to this groupvoid removeTab(int index)
index - the index of the tab that is supposed to be removedjava.lang.IndexOutOfBoundsException - in case the index parameter is less then 0 or larger then getTabCount()void removeTab(@Nonnull
Tab tab)
tab - the tab that is supposed to be removedjava.lang.IllegalArgumentException - in case the tab that is supposed to be removed is not a part of this tab groupvoid removeTab(@Nonnull
Element tab)
tab - the tab that is supposed to be removedjava.lang.IllegalArgumentException - in case the tab that is supposed to be removed is not a part of this tab group or
in case the tab does not contain a Tab as registered controlvoid removeTab(int index,
@Nullable
EndNotify notify)
index - the index of the tab that is supposed to be removednotify - the notification that is called once the tab is removedjava.lang.IndexOutOfBoundsException - in case the index parameter is less then 0 or larger then getTabCount()void removeTab(@Nonnull
Tab tab,
@Nullable
EndNotify notify)
tab - the tab that is supposed to be removednotify - the notification that is called once the tab is removedjava.lang.IllegalArgumentException - in case the tab that is supposed to be removed is not a part of this tab groupvoid removeTab(@Nonnull
Element tab,
@Nullable
EndNotify notify)
tab - the tab that is supposed to be removednotify - the notification that is called once the tab is removedjava.lang.IllegalArgumentException - in case the tab that is supposed to be removed is not a part of this tab group or
in case the tab does not contain a Tab as registered controlvoid setSelectedTab(@Nonnull
Tab tab)
tab - the tab that is supposed to be displayed in the tab groupjava.lang.IllegalArgumentException - in case the tab that is supposed to be removed is not a part of this tab groupvoid setSelectedTabIndex(int index)
index - the index of the tab that is supposed to be displayedjava.lang.IndexOutOfBoundsException - in case the index parameter is less then 0 or larger then getTabCount()void setTabCaption(int index,
@Nonnull
java.lang.String caption)
index - the index of the tab that is supposed to get a new captioncaption - the new caption of this tabjava.lang.IndexOutOfBoundsException - in case the index parameter is less then 0 or larger then getTabCount()void setTabCaption(@Nonnull
Tab tab,
@Nonnull
java.lang.String caption)
tab - the tab that is supposed to receive a new captioncaption - the new caption of this tabjava.lang.IllegalArgumentException - in case the tab that is supposed to be removed is not a part of this tab group@Nullable Tab getTabAtIndex(int index)
index - the index of the tab controlCopyright © 2018. All rights reserved.