Constructor
# new DuTabPanel()
Properties:
Name | Type | Description |
---|---|---|
buttons |
Array.<DuButton>
|
The buttons for the tabs. Not that an "index" property is added to the button, containing the DuTab index. |
tabs |
Array.<DuTab>
|
The tabs. |
index |
int
|
The currently visible tab. |
buttonsGroup |
Group
|
The ScriptUI Group containing the buttons |
mainGroup |
Group
|
The ScriptUI Group containing the tabs |
scriptUIPanel |
string
|
The file name ("script.jsx") of a scriptUI Panel. Alt+Click on this tab will open/close this panel. |
onChange |
DuTabPanel~onChange
|
Called when the index changes. |
Methods
# static addTab(textopt, imageopt, helpTipopt, translatableopt) → {DuTab}
Adds a new empty DuTab in the DuTabPanel.
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
text |
string
|
<optional> |
'' | The label of the button. |
image |
string
|
<optional> |
'' | The path to the icon. |
helpTip |
string
|
<optional> |
'' | The helptip. |
translatable |
bool
|
<optional> |
true | Set to false to not translate this tab text and helptip |
The new DuTab.
# static setCurrentIndex(indexopt)
Sets the current visible tab.
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
index |
int
|
<optional> |
0 | The index of the tab to show. |