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

Table widget. More...

Inheritance diagram for Table:
Widget

Public Member Functions

 Table (string name, int size, number def, number min, number max, bool integer)
 creates a table widget on the user interface.
 
void setValue (int index, number value, bool callChangedCallback=true)
 set a table value.
 
void setRange (number min, number max)
 
number getValue (int index)
 get a table value.
 

Public Attributes

int length
 table size
 
number min
 minimum value
 
number max
 maximum value
 
string backgroundColour
 background colour: colour string that defines the desired colour.
 
string sliderColour
 slider colour: colour string that defines the
 
bool showPopupDisplay
 show/hide the value popup display (if any)
 
string fillStyle
 background and slider fill style: 'gloss' or 'solid'
 
bool drawInnerEdge
 draw separation line between each bar (default is true)
 
string innerEdgeColour
 inner edge colour: colour string that defines the desired 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

Table widget.

creates a table widget on the user interface.

t = Table("table", 10, 0, -12, 12, true)
t.changed = function(self, index)
print("table changed:", index, self:getValue(index))
end
Table(string name, int size, number def, number min, number max, bool integer)
creates a table widget on the user interface.
number getValue(int index)
get a table value.
function changed
callback function used by child widgets to be notified of changes
Definition ui.cpp:776

Constructor & Destructor Documentation

◆ Table()

Table::Table ( string name,
int size,
number def,
number min,
number max,
bool integer )

creates a table widget on the user interface.

Parameters
namethe name to give to the widget
sizenumber of element in the table
defdefault and initial value of all sliders
minminimum value
maxmaximum value
integeroptional default is false

Member Function Documentation

◆ getValue()

number Table::getValue ( int index)

get a table value.

Parameters
indexindex of the value to read

◆ setRange()

void Table::setRange ( number min,
number max )
Parameters
minminimum value
maxmaximum value

◆ setValue()

void Table::setValue ( int index,
number value,
bool callChangedCallback = true )

set a table value.

Parameters
indexindex of the value to write in the table
valuevalue to write in the table
callChangedCallbackcall the changed callback function if true

Member Data Documentation

◆ backgroundColour

string Table::backgroundColour

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

◆ innerEdgeColour

string Table::innerEdgeColour

inner edge 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

◆ sliderColour

string Table::sliderColour

slider 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