|
Krita Source Code Documentation
|
#include <kis_node_facade.h>
Inheritance diagram for KisNodeFacade:Public Member Functions | |
| bool | addNode (KisNodeSP node, KisNodeSP parent, KisNodeSP aboveThis, KisNodeAdditionFlags flags=KisNodeAdditionFlag::None) |
| bool | addNode (KisNodeSP node, KisNodeSP parent, quint32 index, KisNodeAdditionFlags flags=KisNodeAdditionFlag::None) |
| bool | addNode (KisNodeSP node, KisNodeSP parent=KisNodeSP(), KisNodeAdditionFlags flags=KisNodeAdditionFlag::None) |
| KisNodeFacade () | |
| KisNodeFacade (KisNodeSP root) | |
| bool | moveNode (KisNodeSP node, KisNodeSP parent, KisNodeSP aboveThis) |
| bool | moveNode (KisNodeSP node, KisNodeSP parent, quint32 index) |
| bool | removeNode (KisNodeSP node) |
| const KisNodeSP | root () const |
| void | setRoot (KisNodeSP root) |
| virtual | ~KisNodeFacade () |
Public Member Functions inherited from Private | |
| Private (KisCanvas2 *c) | |
Public Attributes | |
| KisNodeWSP | root |
Public Attributes inherited from Private | |
| KisCanvas2 * | canvas |
| int | displayedFrame |
| int | intendedFrame |
Private Attributes | |
| QScopedPointer< Private > | m_d |
KisNodeFacade is the public interface to adding and removing nodes.
Definition at line 11 of file kis_node_facade.cpp.
| KisNodeFacade::KisNodeFacade | ( | ) |
Create a new, empty KisNodeFacade
Definition at line 17 of file kis_node_facade.cpp.
| KisNodeFacade::KisNodeFacade | ( | KisNodeSP | root | ) |
Create a new kisnodefacade for the given root.
Definition at line 22 of file kis_node_facade.cpp.
|
virtual |
Definition at line 28 of file kis_node_facade.cpp.
| bool KisNodeFacade::addNode | ( | KisNodeSP | node, |
| KisNodeSP | parent, | ||
| KisNodeSP | aboveThis, | ||
| KisNodeAdditionFlags | flags = KisNodeAdditionFlag::None ) |
Add already existing node to the graph.
| node | the node to be added |
| parent | the parent node |
| aboveThis | in the list with child nodes of the specified parent, add this node above the specified sibling. if 0, the node is put in the lowermost position in its group. returns false if adding the node didn't work, true if the node got added |
Definition at line 104 of file kis_node_facade.cpp.
| bool KisNodeFacade::addNode | ( | KisNodeSP | node, |
| KisNodeSP | parent, | ||
| quint32 | index, | ||
| KisNodeAdditionFlags | flags = KisNodeAdditionFlag::None ) |
Adds the node as a child of the given parent at the specified index.
childCount() is a valid index and appends to the end. Fails and returns false if the node is already in this group or any other (remove it first.)
Definition at line 112 of file kis_node_facade.cpp.
| bool KisNodeFacade::addNode | ( | KisNodeSP | node, |
| KisNodeSP | parent = KisNodeSP(), | ||
| KisNodeAdditionFlags | flags = KisNodeAdditionFlag::None ) |
Add an already existing node to the image. The node is put on top of the nodes in the specified node group. If parent is 0, then the root is used as parent.
| node | the node to be added |
| parent | the parent node |
Definition at line 92 of file kis_node_facade.cpp.
References dbgImage, KisNode::lastChild(), and m_d.
Move the given node to specified position. If the node already has a parent, it is removed from the parent's node list.
Definition at line 42 of file kis_node_facade.cpp.
References dbgImage, moveNode(), and KisNode::parent.
Move the given node at the specified index. If the node already has a parent, it is removed from the parent's node list.
childCount() is a valid index and appends to the end.
Definition at line 72 of file kis_node_facade.cpp.
References KisNodeGraphListener::aboutToMoveNode(), addNode(), KisSharedPtr< T >::data(), dbgImage, KisNode::graphListener, KisNode::index(), KisNodeGraphListener::nodeHasBeenMoved(), KisNode::parent, and KisNode::remove().
| bool KisNodeFacade::removeNode | ( | KisNodeSP | node | ) |
Remove the specified node.
Definition at line 125 of file kis_node_facade.cpp.
References KisNode::parent, and KisNode::remove().
| const KisNodeSP KisNodeFacade::root | ( | ) | const |
Return the root node for the graph this facade managed
|
private |
Definition at line 103 of file kis_node_facade.h.
| const KisNodeSP KisNodeFacade::root |
Definition at line 14 of file kis_node_facade.cpp.