Scripting Interface |
The waypoint JavaScript global object. More...
Public Slots | |
String | add (String &parentGroup, String &instanceName, int x, int y) |
Add a waypoint to the Node View. More... | |
bool | deleteWaypoint (String &qualifiedName) |
Delete a single waypoint. More... | |
bool | linkOutportToWaypoint (String &nodeQualifiedName, int outPortId, String &wpQualifiedName) |
Link an output port from a node to a waypoint. More... | |
bool | linkWaypointToWaypoint (String &srcQualifiedName, String &dstQualifiedName) |
Link a waypoint to another waypoint. More... | |
bool | linkWaypointToInport (String &wpQualifiedName, String &nodeQualifiedName, int inPortId, bool insertMode=false) |
Link a waypoint to an input port. More... | |
StringList | getAllWaypointsAbove (String &nodeQualifiedName, int inPortId) |
Retrieve all the waypoints found along the cable of the specified node input port. More... | |
StringList | getAllWaypointsBelow (String &nodeQualifiedName, int outPortId) |
Retrieve all the waypoints found along the cable tree under the specified node output port. More... | |
StringList | getWaypointsInGroup (String &groupQualifiedName) |
Retrieve the waypoint list for the specified group. More... | |
bool | unlinkParent (String &wpQualifiedName) |
Unlink the waypoint from its parent node or waypoint. More... | |
bool | unlinkChildInport (String &wpQualifiedName, String &nodeQualifiedName, int inPortId) |
Unlink the child input port from the waypoint. More... | |
bool | unlinkChildNode (String &wpQualifiedName, String &nodeQualifiedName) |
Unlink the destination node from the waypoint source. More... | |
bool | unlinkChildWaypoint (String &wpQualifiedName, String &childWpQualifiedName) |
Unlink the child waypoint from the specified waypoint. More... | |
bool | unlinkAllChildren (String &wpQualifiedName) |
Unlink all children node and children waypoints from the specified waypoint. More... | |
QScriptValue | childInports (String &wpQualifiedName) |
Retrieve the list of children ports directly connected to the specified waypoint. More... | |
StringList | childNodes (String &wpQualifiedName) |
Retrieve the list of children port nodes directly connected to the specified waypoint. More... | |
StringList | childWaypoints (String &wpQualifiedName) |
Retrieve the list of children waypoints. More... | |
StringList | childWaypoints (String &nodeQualifiedName, int outPortId) |
Retrieve the list of waypoints directly linked to the specified node output port. More... | |
String | parentWaypoint (String &wpQualifiedName) |
Get parent waypoint path. More... | |
String | parentWaypoint (String &nodeQualifiedName, int inPortId) |
Retrieve the waypoint above a node port, linked to the specified input port. More... | |
String | parentNode (String &wpQualifiedName) |
Get parent node path, if applicable. More... | |
int | parentOutport (String &wpQualifiedName) |
Get parent outport index, if applicable. More... | |
void | setCoord (String &qualifiedName, int x, int y) |
Set the position of a waypoint in the Node View. More... | |
int | coordX (String &qualifiedName) |
Returns an integer indicating the X position of a waypoint in the Node View. More... | |
int | coordY (String &qualifiedName) |
Returns an integer indicating the X position of a waypoint in the Node View. More... | |
The waypoint JavaScript global object.
Waypoints are graphical objects used in the Node View to control the path of a cable linking modules together. With waypoint methods, it is possible to Add, link, remove, move and get position of any waypoint. The naming convention for waypoints is highly similar to naming convention for nodes. The qualified name of a waypoint is the concatenation of its parent group qualified name and its instance name, e.g. "Top/MyFirstGroup/MyWaypointName"
.
|
slot |
Add a waypoint to the Node View.
For an example usage of add, see the above Detailed Description.
parentGroup | : The path of the parent group node into which you want to add this waypoint. |
instanceName | : The suggested name of the waypoint you want to add. |
x | : The X position of the waypoint in the Node View. |
y | : The Y position of the waypoint in the Node View. |
|
slot |
Retrieve the list of children ports directly connected to the specified waypoint.
Meant to be used in conjunction with waypoint.childNodes().
wpQualifiedName | : The path to the waypoint. |
|
slot |
Retrieve the list of children port nodes directly connected to the specified waypoint.
Meant to be used in conjunction with waypoint.childInports().
wpQualifiedName | : The path to the waypoint. |
|
slot |
Retrieve the list of children waypoints.
wpQualifiedName | : The path to the waypoint. |
|
slot |
Retrieve the list of waypoints directly linked to the specified node output port.
nodeQualifiedName | : The path of the node. |
outPortId | : The out port from which waypoints are linked. This value is between 0 and the number of node out ports, minus one. |
|
slot |
Returns an integer indicating the X position of a waypoint in the Node View.
The example below takes the path of a waypoint, uses coordX to retrieve it's X coordinate in the Node View, then moves it to the right by 50 units.
qualifiedName | : The path of the waypoint. |
|
slot |
Returns an integer indicating the X position of a waypoint in the Node View.
The example below takes the path of a waypoint, uses coordY to retrieve it's X coordinate in the Node View, then moves it to the down by 50 units.
qualifiedName | : The path of the waypoint. |
|
slot |
Delete a single waypoint.
The following example deletes the currently selected waypoint. Existing links will bypass the deleted waypoint.
qualifiedName | : The path of the waypoint. |
|
slot |
Retrieve all the waypoints found along the cable of the specified node input port.
nodeQualifiedName | : The path of the node. |
inPortId | : The in port from which the waypoint path starts. This value is between 0 and the number of node in ports, minus one. |
|
slot |
Retrieve all the waypoints found along the cable tree under the specified node output port.
nodeQualifiedName | : The path of the node. |
outPortId | : The out port from which waypoints are linked. This value is between 0 and the number of node out ports, minus one. |
|
slot |
Retrieve the waypoint list for the specified group.
groupQualifiedName | : The path of the group. |
|
slot |
Link an output port from a node to a waypoint.
nodeQualifiedName | : The path of the node whose output port you want to link to a destination waypoint. |
outPortId | : The port that you want to link to the input port on the destination waypoint. This value is between 0 and the results of the numberOfOutputPorts() method, minus one. |
wpQualifiedName | : The path of the waypoint you want to link to the source node. |
|
slot |
Link a waypoint to an input port.
wpQualifiedName | : The path of the source waypoint you want to link from. |
nodeQualifiedName | : The path of the destination node you want to link to. |
inPortId | : The port on the destination node that you want to link to the waypoint source. This value is between 0 and the results of the numberOfInputPorts() method, minus one. |
insertMode | : This flag allows to either insert a new port on the destination node (true) or link to an existing port (false) if one exists at the specified index. |
|
slot |
Link a waypoint to another waypoint.
srcQualifiedName | : The path of the source waypoint you want to link from. |
dstQualifiedName | : The path of the destination waypoint you want to link to. |
|
slot |
Get parent node path, if applicable.
wpQualifiedName | : The path to the waypoint. |
|
slot |
Get parent outport index, if applicable.
wpQualifiedName | : The path to the waypoint. |
|
slot |
Get parent waypoint path.
wpQualifiedName | : The path to the waypoint. |
|
slot |
Retrieve the waypoint above a node port, linked to the specified input port.
nodeQualifiedName | : The path of the node. |
inPortId | : The in port to which a waypoint is linked. This value is between 0 and the number of node in ports, minus one. |
|
slot |
Set the position of a waypoint in the Node View.
The example below takes the path of a waypoint and then shifts its position 50 units to the right, and down in the node view.
qualifiedName | : The path of the waypoint. |
x | : The X position of the waypoint in the Node View. |
y | : The Y position of the waypoint in the Node View. |
|
slot |
Unlink all children node and children waypoints from the specified waypoint.
This method will also disconnect all destination ports below the waypoint.
wpQualifiedName | : The parent waypoint. |
|
slot |
Unlink the child input port from the waypoint.
wpQualifiedName | : The path of the waypoint. |
nodeQualifiedName | : The path to the destination node. |
inPortId | : The index of the port to unlink. |
|
slot |
Unlink the destination node from the waypoint source.
wpQualifiedName | : The path of the waypoint. |
nodeQualifiedName | : The path to the destination node. |
|
slot |
Unlink the child waypoint from the specified waypoint.
This method will also disconnect all destination ports below the child waypoint.
wpQualifiedName | : The parent waypoint. |
childWpQualifiedName | : The child waypoint to unlink. |
|
slot |
Unlink the waypoint from its parent node or waypoint.
wpQualifiedName | : The path of the waypoint. |