Inheritence |
|
Methods
treeTypes()
→ tuple
of str
Returns a tuple of strings that represent the different tree types that can be shown in the Data Tree pane.
treeType()
→ str
Returns the current tree type being shown in the Data Tree. This function may return an empty string if no tree type has been chosen yet.
setTreeType(tree_type)
→ bool
Changes the tree type being displayed in the Data Tree. Valid values are
any strings returned by the treeTypes
function. Returns True if the tree
type was successfully changed, otherwise False.
currentPath()
→ str
Returns the path to the current node in the tree.
clearCurrentPath()
→ str
Clears the node(s) currently selected in the tree.
setCurrentPath(path, multi=False, index=-1)
Sets the currently selected node in the tree. If the provided path does not match a node in the tree, the tree will still attempt to set the current node to the best possible match of the provided path.
If multi is set to True, the previous selection will not be cleared before selecting the new the node. This allows multiple nodes to be selected in the tree.
setCurrentPaths(paths, expand)
Selects mutliple nodes in the data tree based on the array of paths
passed in. If the expand
flag is set to True the tree nodes will be
expanded after selection.
setCurrentNodeExpanded(expanded)
Sets the expanded state of the currently selected node in the tree. If there is no selected node the method has no effect on the tree.
setTreeExpanded(expanded)
Recursively sets the expanded state of the entire data tree.
Methods from hou.PaneTab
name()
→ str
Return the name of this tab.
setName(name)
Set the name of this pane tab. A pane tab name may contain spaces.
Note that this name is the internal name of the tab, and is different from the label displayed in the interface.
type()
→ hou.paneTabType enum value
Return the type of this tab (i.e. whether it is a scene viewer, parameter editor, network editor, etc.).
setType(type)
→ hou.PaneTab
Create a new pane tab of the given type, replace this tab with it, and return the new pane tab. Use the returned pane tab afterward; references to this tab become invalid.
close()
Close the pane tab.
pane()
→ hou.Pane or None
Return the pane in the desktop that contains this pane tab. Note that pane tabs in regular floating panels are always in a pane, since regular floating panels contain one or more panes.
However, some floating panels have their content stripped down to only contain one particular pane tab type, and do not display the user interface to add more pane tabs, split the pane, etc. This method returns None for these stripped down floating panels.
floatingPanel()
→ hou.FloatingPanel or None
Return the floating panel that contains this pane tab or None if the pane tab is not in a floating panel.
isCurrentTab()
→ bool
Return whether this tab is the selected tab in the containing pane.
setIsCurrentTab()
Set this tab as the selected tab in the containing pane.
isFloating()
→ bool
Return whether this pane tab is in a floating panel.
This method can be approximately implemented as follows:
def isFloating(self): return self.pane() is None or self.pane().floatingPanel() is not None
clone()
→ hou.PaneTab
Create a floating copy of the pane tab and return the cloned pane tab. The new pane tab is in a new floating panel.
linkGroup()
→ hou.paneLinkType enum value
Return the link group that this pane tab belongs to.
See also hou.PaneTab.isPin().
setLinkGroup(group)
Set the link group membership of this pane tab.
isPin()
→ bool
Return whether this pane tab is pinned. This method is equivalent to
(self.linkGroup() == hou.paneLinkType.Pinned)
See also hou.PaneTab.linkGroup().
setPin(pin)
If pin is True
, set the link group membership to hou.paneLinkType.Pinned.
Otherwise, set it to hou.paneLinkType.FollowSelection. This method can be
implemented using hou.PaneTab.setLinkGroup() as follows:
def setPin(self, pin): if pin: self.setLinkGroup(hou.paneLinkType.Pinned) else: self.setLinkGroup(hou.paneLinkType.FollowSelection)
See also hou.PaneTab.setLinkGroup().