The following functions are exposed to addons in order to allow them to interact with the built-in Ashita UI system that uses AnTweakBar.
Because of the nature of how some of these things work, there are some 'hack-arounds' in order to fully make use of the UI features.
number Gui_GetBarCount();
boolean Gui_CreateBar(name, x, y, w, h);
Parameters
name - The name of the bar to create.
x - The x position of the bar.
y - The y position of the bar.
w - The width of the bar.
h - The height of the bar.
Returns
boolean Gui_DeleteBar(name);
boolean Gui_DeleteAllBars();
string Gui_GetBarByIndex(index);
boolean Gui_Define(def);
number Gui_DefineEnumFromString(name, str);
boolean Gui_RefreshBar(name);
string Gui_GetBottomBar();
boolean Gui_SetBottomBar(name);
string Gui_GetTopBar();
boolean Gui_SetTopBar(name);
object Gui_CreateVar(type, size);
void Gui_DeleteVar(var);
object Gui_GetVarValue(var);
void Gui_SetVarValue(var, value);
boolean Gui_NewButton(barName, name, def);
Parameters
barName - The name of the bar to create the button within.
name - The name of the button.
def - The definition params of the button.
Returns
boolean Gui_NewSeparator(barName, name, def);
Parameters
barName - The name of the bar to create the separator within.
name - The name of the separator.
def - The definition params of the separator.
Returns
boolean Gui_NewReadOnly(barName, name, type, var, def);
Parameters
barName - The name of the bar to create the read-only property in.
name - The name of the read-only property.
type - The type of property.
var - The variable that this property is attached to.
def - The definition params of the property.
Returns
boolean Gui_NewReadWrite(barName, name, type, var, def);
Parameters
barName - The name of the bar to create the read-write property in.
name - The name of the read-write property.
type - The type of property.
var - The variable that this property is attached to.
def - The definition params of the property.
Returns
object Gui_GetParam(barName, vname, pname, type, count);
Parameters
barName - The name of the bar containing the parameter.
vname - The name of the variable for this parameter.
pname - The parameter name.
type - The type of variable.
count - The count of expected value returns.
Returns
boolean Gui_SetParam(barName, vname, pname, type, count, values);
Parameters
barName - The name of the bar containing the parameter.
vname - The name of the variable for this parameter.
pname - The parameter name.
type - The type of variable.
count - The number of values to be set.
values - The table containing the values to set the param to.
Returns
The following function IS NOT something users should call. Instead, this is a function that addons should define if they are making use of buttons. This function is called from the Addons plugin whenever a button is clicked.
void Gui_ButtonClicked(string name);