Skip to content

Commit 94359e2

Browse files
committed
doc updates
1 parent 9b138e1 commit 94359e2

File tree

4 files changed

+36
-10
lines changed

4 files changed

+36
-10
lines changed

NodeGraphQt/base/graph.py

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -801,6 +801,11 @@ def layout_direction(self):
801801
"""
802802
Return the current node graph layout direction.
803803
804+
`Implemented in` ``v0.3.0``
805+
806+
See Also:
807+
:meth:`NodeGraph.set_layout_direction`
808+
804809
Returns:
805810
int: layout direction.
806811
"""
@@ -814,13 +819,20 @@ def set_layout_direction(self, direction):
814819
815820
`Implemented in` ``v0.3.0``
816821
822+
See Also:
823+
:meth:`NodeGraph.layout_direction`,
824+
:meth:`NodeObject.set_layout_direction`
825+
817826
Note:
818-
By default node graph direction is set to "NODE_LAYOUT_HORIZONTAL".
827+
By default node graph direction is set to horizontal.
819828
820829
Node Graph Layout Types:
821830
822-
* :attr:`NodeGraphQt.constants.NODE_LAYOUT_HORIZONTAL`
823-
* :attr:`NodeGraphQt.constants.NODE_LAYOUT_VERTICAL`
831+
* :attr:`NodeGraphQt.constants.LayoutDirectionEnum.HORIZONTAL`
832+
* :attr:`NodeGraphQt.constants.LayoutDirectionEnum.VERTICAL`
833+
834+
Warnings:
835+
This function does not register to the undo stack.
824836
825837
Args:
826838
direction (int): layout direction.
@@ -900,7 +912,7 @@ def register_node(self, node, alias=None):
900912
Register the node to the :meth:`NodeGraph.node_factory`
901913
902914
Args:
903-
node (_NodeGraphQt.NodeObject): node object.
915+
node (NodeGraphQt.NodeObject): node object.
904916
alias (str): custom alias name for the node type.
905917
"""
906918
self._node_factory.register_node(node, alias)

NodeGraphQt/base/node.py

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -463,7 +463,10 @@ def pos(self):
463463

464464
def layout_direction(self):
465465
"""
466-
Returns the current node layout direction.
466+
Returns layout direction for this node.
467+
468+
See Also:
469+
:meth:`NodeObject.set_layout_direction`
467470
468471
Returns:
469472
int: node layout direction.
@@ -472,11 +475,16 @@ def layout_direction(self):
472475

473476
def set_layout_direction(self, value=0):
474477
"""
475-
Sets the node layout direction to either horizontal or vertical.
478+
Sets the node layout direction to either horizontal or vertical on
479+
the current node only.
476480
477481
`Implemented in` ``v0.3.0``
478482
479-
Note:
483+
See Also:
484+
:meth:`NodeGraph.set_layout_direction`
485+
:meth:`NodeObject.layout_direction`
486+
487+
Warnings:
480488
This function does not register to the undo stack.
481489
482490
Args:

NodeGraphQt/nodes/base_node.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,11 +74,17 @@ def update_model(self):
7474

7575
def set_layout_direction(self, value=0):
7676
"""
77-
Sets the node layout direction to either horizontal or vertical.
77+
Sets the node layout direction to either horizontal or vertical on
78+
the current node only.
7879
7980
`Implemented in` ``v0.3.0``
8081
81-
Note:
82+
See Also:
83+
:meth:`NodeGraph.set_layout_direction`,
84+
:meth:`NodeObject.layout_direction`
85+
86+
87+
Warnings:
8288
This function does not register to the undo stack.
8389
8490
Args:

docs/nodes/BaseNode.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ BaseNode
33

44
.. autoclass:: NodeGraphQt.BaseNode
55
:members:
6-
:exclude-members: update_model
6+
:exclude-members: update_model, set_layout_direction

0 commit comments

Comments
 (0)