![]() |
uvi-script
Musical event scripting with Lua
|
Classes | |
| class | Mapper |
| Predefined mapper types. More... | |
| class | Unit |
| Predefined unit types. More... | |
| class | RectanglePlacement |
| Image placement and alignment options. More... | |
| class | FileFormat |
| Predefined format file types. More... | |
| class | ModifierKeys |
| Keyboard modifier key state information. More... | |
| class | Widget |
| Widget base class. More... | |
| class | ParamWidget |
| base class for ParamWidget. More... | |
| class | Button |
| stateless transient button. More... | |
| class | OnOffButton |
| 2 states boolean button. More... | |
| class | Image |
| Image widget. More... | |
| class | DnDArea |
| DnDArea widget. More... | |
| class | Label |
| text label widget. More... | |
| class | Menu |
| Menu widget. More... | |
| class | MultiStateButton |
| MultiStateButton widget. More... | |
| class | Table |
| Table widget. More... | |
| class | NumBox |
| Numeric input widget. More... | |
| class | Slider |
| Horizontal or vertical slider widget. More... | |
| class | Knob |
| Knob widget. More... | |
| class | ParamKnob |
| A knob bound to an existing Element parameter. More... | |
| class | ParamSlider |
| A fader bound to an existing Element parameter. More... | |
| class | ParamOnOffButton |
| An on/off button bound to an existing boolean Element parameter (e.g. More... | |
| class | ParamMenu |
| A dropdown menu bound to an existing enumerated Element parameter. More... | |
| class | ParamNumBox |
| A numeric box bound to an existing Element parameter. More... | |
| class | ParameterValue |
| A non-visual (logical) binding to an existing Element parameter. More... | |
| class | Panel |
| Panel widget. More... | |
| class | WaveView |
| WaveView widget. More... | |
| class | Viewport |
| Viewport widget. More... | |
| class | XY |
| XY widget. More... | |
| class | AudioMeter |
| AudioMeter widget. More... | |
| class | FileSelector |
| FileSelector widget. More... | |
| class | SVG |
| SVG widget. More... | |
Functions | |
| void | moveControl (Widget widget, int xcol, int yrow) |
| move a UI element to a specific place on the grid | |
| void | setBackground (string imagePath) |
| set the script background Image. | |
| void | setBackgroundColour (string colour) |
| set the script background colour. | |
| void | setSize (number w, number h) |
| set the script UI dimensions explicitly. | |
| void | makePerformanceView () |
| make this script User Interface visible in performance view. | |
| function | setKeyColour (note, colour) |
| customize the keyboard colours. | |
| function | resetKeyColour (note) |
| customize the keyboard colours. | |
| function | setHeight (h) |
| sets the desired height of the user interface. | |
| function | moveControl (widget, xcol, yrow) |
| function | setBackground (imgPath) |
| function | setBackgroundColour (colour) |
Custom user interface widgets and layout system.
The UI group provides a comprehensive set of widgets for creating custom script interfaces. All widgets use automatic layout by default but support precise manual positioning. Widget constructors are only available during the main script chunk (not in real-time callbacks).
Widget Categories:
Layout System:
Key Features:
All image properties support Apple's @2x naming convention for Retina displays. To provide a high-resolution variant, place a file with the @2x suffix alongside the standard-resolution file:
resources/knob.png — standard resolutionresources/knob@2x.png — Retina resolution (2× pixel dimensions)The engine automatically picks the appropriate variant based on the display's scale factor. If no @2x variant is found, the standard image is used.
Lottie Animations:
Knobs, sliders, buttons and meters can wear a vector animation instead of a strip of bitmaps – one file, any size, and a packaged one can answer the mouse. Lottie Animations explains the formats, what drives the frame on each widget, and how to size the widget for its asset.
| void makePerformanceView | ( | ) |
make this script User Interface visible in performance view.
The performance view is the simplified instrument interface shown to the end user during performance (as opposed to the full editing view). Calling this function registers the current script UI so it appears in the performance view panel of the host.
It only sets a flag marking this script as the one providing the performance view; it captures nothing and inspects no widgets, so it may be called anywhere in the main chunk. What matters is that it runs: an error while the script loads aborts every line after the failing one, so a call placed at the end is skipped by any mistake above it. Calling it first avoids that:
| void moveControl | ( | Widget | widget, |
| int | xcol, | ||
| int | yrow ) |
move a UI element to a specific place on the grid
| widget | widget element to move |
| xcol | 1-based grid column index, must be greater than 0 |
| yrow | 1-based grid row index, must be greater than 0 |
| function resetKeyColour | ( | note | ) |
| void setBackground | ( | string | imagePath | ) |
set the script background Image.
supported image types include jpg and png. Supports Retina @2x variants.
| imagePath | file path to the Image can be absolute or relative |
| void setBackgroundColour | ( | string | colour | ) |
set the script background colour.
| colour | string that defines the desired colour. It can be either a named colour like "blue" or "red" or an hexadecimal string in RGB ("#FF00CC") or ARGB ("#3C00FECD") format |
| function setHeight | ( | h | ) |
sets the desired height of the user interface.
it is automatically computed when creating widgets but you can adjust it to fit your needs
| h | height in pixels |
| function setKeyColour | ( | note | , |
| colour | ) |
customize the keyboard colours.
| note | midiNote to change |
| colour | string that defines the desired colour. It can be either a named colour like "blue" or "red" or an hexadecimal string in RGB ("#FF00CC") or ARGB ("#3C00FECD") format You can use custom colors to set the valid key range: #00FFFFFF (transparent white) and #00000000 (transparent black) for a valid and non valid key |
| void setSize | ( | number | w, |
| number | h ) |
set the script UI dimensions explicitly.
By default the UI height adjusts automatically to fit the widgets. Use this to override both width and height when you need a custom canvas size.
| w | width in pixels |
| h | height in pixels |