GuiObject

The objects provides a means to control and receive events from the GUI interface displayed in the session view on the desktop or iPad device. The interface is constructed via a series of calls to this object during the "paint" event, in a manner similar to the GUI in Unity3D. The layout is automatic is made of cascading calls to vertical and horizontal layouts. A method must be called for each control on every pass to the paint, and these methods return any changes in value caused by a user interacting with the controls.

This object is not implemented.

GuiLayoutObject Object
TODO: move this to its own page

All options supplied to GuiObject methods are of the type GuiLayoutObject which controls adjustments to how each control should be displayed in the layout. The following properties are available:
 * width - the size to draw the control
 * height - the size to draw the control
 * paddingLeft - the padding around the control, in addition to the width and height
 * paddingTop
 * paddingRight
 * paddingBottom

Example
var x = 0.2, y = 0.5, z = 0.8; implant.gui.on('paint', function(e) {   var g = implant.gui;        g.beginHorizontal;    x = g.fader('vertical', x, 0, 1);    g.beginVertical;    y = g.knob(y, 0, 1);    z = g.knob(z, 0, 1);    g.endVertical;    if (g.button('Reset')) {      x = 0;      y = 0;      z = 0;    }     g.endHorizontal;  });

Properties
None

Methods

 * void beginHorizontal - starts a new horizontal layout
 * void endHorizontal - ends a horizontal layout
 * void beginVertical - starts a new vertical layout
 * void endVertical - ends a vertical layout
 * double knob(value, minValue, maxValue, options) - adds a rotary knob at the current position. Default size is 48x48.
 * double fader(direction, value, minValue, maxValue, options) - same as verticalFader and horizontalFader but accepts a direction.
 * double verticalFader(value, minValue, maxValue, options) - adds a vertical fader. Default size is 16x96.
 * double horizontalFader(value, minValue, maxValue, options) - adds a horizontal fader. Default size is 96x16.
 * bool button(text, options) - adds a button at the current position. Default size is 48x16.
 * bool toggle(text, options) - adds a button that toggles its state, like a checkbox. Default size is 96x16.

Events
None