SubGraph
|
The |
- class NodeGraphQt.SubGraph(parent=None, node=None, node_factory=None, **kwargs)
The
SubGraph
class is just like theNodeGraph
but is the main controller for managing the expanded node graph for aNodeGraphQt.GroupNode
.Attributes:
Returns a list of the sub graphs in the order they were initialized.
The navigation widget from the top most sub graph.
The widget to the sub graph.
The parent node graph controller.
Returns the parent node to the sub graph.
Methods:
collapse_graph
([clear_session])Collapse the current sub graph and hide its widget.
expand_group_node
(node)Expands a group node session in current sub view.
collapse_group_node
(node)Collapse a group node session and it's expanded child sub graphs.
Return all the port nodes related to the group node input ports.
Return all the port nodes related to the group node output ports.
get_node_by_port
(port)Returns the node related to the parent group node port object.
- property initialized_graphs
Returns a list of the sub graphs in the order they were initialized.
- Returns:
list of sub graph objects.
- Return type:
list[NodeGraphQt.SubGraph]
The navigation widget from the top most sub graph.
- Returns:
navigation widget.
- Return type:
NodeNavigationWidget
- property subviewer_widget
The widget to the sub graph.
- Returns:
node graph widget.
- Return type:
PySide2.QtWidgets.QWidget
- collapse_graph(clear_session=True)
Collapse the current sub graph and hide its widget.
- Parameters:
clear_session (bool) – clear the current session.
- expand_group_node(node)
Expands a group node session in current sub view.
- Parameters:
node (NodeGraphQt.GroupNode) – group node.
- Returns:
sub node graph used to manage the group node session.
- Return type:
- collapse_group_node(node)
Collapse a group node session and it’s expanded child sub graphs.
- Parameters:
node (NodeGraphQt.GroupNode) – group node.
- get_input_port_nodes()
Return all the port nodes related to the group node input ports.
- Returns:
input nodes.
- Return type:
list[NodeGraphQt.PortInputNode]
- get_output_port_nodes()
Return all the port nodes related to the group node output ports.
- Returns:
output nodes.
- Return type:
list[NodeGraphQt.PortOutputNode]
- get_node_by_port(port)
Returns the node related to the parent group node port object.
- Parameters:
port (NodeGraphQt.Port) – parent node port object.
- Returns:
port node object.
- Return type: