JsonGui
Associated namespace: sm.jsonGui
Values:
Functions:
Operations:
| Operation | Return type | Description |
| JsonGui == JsonGui | boolean | Checks if two instances of JsonGui refer to the same JsonGui. |
id integer
Get:
Returns the id of a gui.
clearOnCloseCallback(gui)
Clears the close callback so it will not be called when the gui is closed
Parameters:
| Type | Name | Description |
| JsonGui | gui | The gui. |
close(gui)
Close a JsonGui
Parameters:
| Type | Name | Description |
| JsonGui | gui | The gui. |
getWidget(gui, widgetName)
Returns a JsonWidget. Nil if no widget was found with the name
Parameters:
| Type | Name | Description |
| JsonGui | gui | The gui. |
| string | widgetName | The name of the widget. |
Returns:
| Type | Description |
| JsonWidget | widget The found widget in the JsonGui. |
getWidgetAbsolutePosition(gui, widgetName)
Get the absolute position of a named widget in 720 coords
Parameters:
| Type | Name | Description |
| JsonGui | gui | The gui. |
| string | widgetName | The name of the widget. |
Returns:
| Type | Description |
| number, number | Left, Top |
isActive(gui)
Check if a JsonGui is active
Parameters:
| Type | Name | Description |
| JsonGui | gui | The gui. |
Returns:
| Type | Description |
| boolean | Is the gui active? |
isHidden(gui)
Gets the visibility of the gui.
Parameters:
| Type | Name | Description |
| JsonGui | gui | The gui. |
Returns:
| Type | Description |
| boolean | hidden True if the gui is hidden. |
render(gui, DOM, forceProperties?)
Renders the DOM
Parameters:
| Type | Name | Description |
| JsonGui | gui | The gui. |
| table | DOM | A table representing the gui elements to show |
| boolean | forceProperties? | Force update widget properties (optional). (Defaults to false) |
setHidden(gui, hidden)
Sets desired visibility of the gui.
Parameters:
| Type | Name | Description |
| JsonGui | gui | The gui. |
| boolean | hidden | True if the gui should be hidden. |