GuiTabBookCtrl
A container.
TabBook
Where to place the tab page headers.
int
Spacing to put between individual tab page headers.
int
Minimum width allocated to a tab page header.
int
Height of tab page headers.
bool
Whether reordering tabs with the mouse is allowed.
int
Index of page to select on first onWake() call (-1 to disable).
int
Index of currently selected page.
int
X offset of first tab page header.
Callbacks
void
onTabSelected(String text, uint index)
Called when a new tab page is selected.
void
onTabRightClick(String text, uint index)
Called when the user right-clicks on a tab page header.
Public Functions
void
addPage(string title)
Add a new tab page to the control.
int
Get the index of the currently selected tab page.
void
selectPage(int index)
Set the selected tab page.
Detailed Description
A container.
// Create
note:Only GuiTabPageCtrls must be added to GuiTabBookCtrls. If an object of a different class is added to the control, it will be reassigned to either the active page or the tab book's parent.
TabBook
GuiTabPosition tabPosition
Where to place the tab page headers.
int tabMargin
Spacing to put between individual tab page headers.
int minTabWidth
Minimum width allocated to a tab page header.
int tabHeight
Height of tab page headers.
bool allowReorder
Whether reordering tabs with the mouse is allowed.
int defaultPage
Index of page to select on first onWake() call (-1 to disable).
int selectedPage
Index of currently selected page.
int frontTabPadding
X offset of first tab page header.
Callbacks
onTabSelected(String text, uint index)
Called when a new tab page is selected.
Parameters:
text | Text of the page header for the tab that is being selected. |
index | Index of the tab page being selected. |
onTabRightClick(String text, uint index)
Called when the user right-clicks on a tab page header.
Parameters:
text | Text of the page header for the tab that is being selected. |
index | Index of the tab page being selected. |
Public Functions
addPage(string title)
Add a new tab page to the control.
Parameters:
title | Title text for the tab page header. |
getSelectedPage()
Get the index of the currently selected tab page.
Index of the selected tab page or -1 if no tab page is selected.
selectPage(int index)
Set the selected tab page.
Parameters:
index | Index of the tab page. |