uvi-script
Musical event scripting with Lua
Loading...
Searching...
No Matches

Panel widget. More...

Inheritance diagram for Panel:
Widget

Public Member Functions

 Panel (string name)
 creates a Panel widget on the user interface.
 

Public Attributes

string backgroundImage
 path to background image. Supports Retina @2x variants.
 
string backgroundColour
 background colour.
 
- Public Attributes inherited from Widget
string name
 widget name
 
string displayName
 widget display name
 
string tooltip
 widget tooltip, default is name
 
int x
 x position in pixels
 
int y
 y position in pixels
 
int width
 widget width in pixels
 
int height
 widget height in pixels
 
table size
 widget size {width, height}
 
table position
 widget position {x,y}
 
table bounds
 widget bounding rect {x,y,width,height}
 
number alpha
 transparency value between 0.0 and 1.0
 
bool enabled
 boolean flag to enable / disable the widget
 
bool visible
 boolean flag to toggle widget visibility
 
bool interceptsMouseClicks
 boolean flag to toggle mouse handling on widget
 
bool showLabel
 show widgets label if any
 
bool persistent
 flag to tell if the widget values should be serialized when saving.
 
function changed
 callback function used by child widgets to be notified of changes
 

Detailed Description

Panel widget.

creates a Panel widget on the user interface.

Panel inherits all the standard widget creation functions (Knob, Slider...) as methods. in order to add sub-widgets, just call those function on an existing Panel instance.

local panel = Panel("panel")
panel.x = 5
panel.y = 5
panel.width = 710
panel.height = 120
panel:Button("foo")
panel:OnOffButton("onoff", false)
panel:Knob("knob", 0, 0, 1)
panel:Slider("slider", 0, 0, 1)
panel:Label("label")
panel:NumBox("NumBox", 0, 0, 1)
panel:Menu("Menu", {"one", "two", "three"})
panel:Table("table", 24, 0, 0, 1)
panel.backgroundColour = "3f000000"
local panel2 = panel:Panel("panel2")
panel2.bounds = {5, 95, 700, 20}
stateless transient button.
Definition ui.cpp:804
Knob widget.
Definition ui.cpp:1424
text label widget.
Definition ui.cpp:984
Menu widget.
Definition ui.cpp:1040
Numeric input widget.
Definition ui.cpp:1297
2 states boolean button.
Definition ui.cpp:864
Panel widget.
Definition ui.cpp:1502
string backgroundColour
background colour.
Definition ui.cpp:1512
Panel(string name)
creates a Panel widget on the user interface.
Horizontal or vertical slider widget.
Definition ui.cpp:1356
Table widget.
Definition ui.cpp:1231
int x
x position in pixels
Definition ui.cpp:760
int height
widget height in pixels
Definition ui.cpp:763
table bounds
widget bounding rect {x,y,width,height}
Definition ui.cpp:766
int y
y position in pixels
Definition ui.cpp:761
int width
widget width in pixels
Definition ui.cpp:762

Constructor & Destructor Documentation

◆ Panel()

Panel::Panel ( string name)

creates a Panel widget on the user interface.

Parameters
namethe name to give to the widget

Member Data Documentation

◆ backgroundColour

string Panel::backgroundColour

background colour.

It can be either a named colour like "blue" or "red" or an hexadecimal string in RGB ("#FF00CC") or ARGB ("#3C00FECD") format