Scripting Interface |
The Backdrop JavaScript global object. Get, set and add backdrops. More...
Public Slots | |
QScriptValue | backdrops (String &group) |
Returns the backdrops of a group. More... | |
bool | setBackdrops (String &group, QScriptValue &backdrops) |
Sets the backdrops for the specified group. More... | |
bool | addBackdrop (String &group, QScriptValue &backdrop) |
Adds a single backdrop. The new backdrop is displayed on top of all the others. More... | |
The Backdrop JavaScript global object. Get, set and add backdrops.
The Backdrop methods sometimes use backdrop JavaScript objects which are described as follows:
Color is a integer representation of a RGBA value. It can be obtained with the following computation.
Here's an example demonstrating how to customize a backdrop
|
slot |
Adds a single backdrop. The new backdrop is displayed on top of all the others.
group | : The name of the parent group node. |
backdrop | : A backdrop JavaScript object, as described in the Backdrop class description. |
|
slot |
Returns the backdrops of a group.
This method returns an array of JavaScript objects where each object represent a single backdrop. Since backdrop do not have keys/unique ID, all backdrops are returned in the order they are defined in the group. The group node must be provided as input.
group | : The name of the group node. |
|
slot |
Sets the backdrops for the specified group.
This replaces all the backdrops in the group. The backdrop is in the format as the array returned by 'Backdrop.backdrops(group). The code will parse the JavaScript object, as described in the Backdrop class description.
group | : The name of the group node. |
backdrops | : An array of backdrop objects or a single backdrop object. See the Backdrop class description for information on the backdrop object. |