I forgot to add a couple code comments that I think would be helpful:
# Break a path like "|root|one|two" into parts and reverse:
# ["|root", "|root|one", "|root|one|two"]
parts = [path.rsplit('|', i)[0] for i in xrange(path.count('|'))]
parts.reverse()
# Get the last name component of the path:
While I am not very adept in using PyQt yet, and this script that I have
currently have on hand, is taken from a tool (with edited functions here
and there).
I am wondering if you could advise, if it will be better for me to re-write
the whole thing?
Truth be told, as mentioned, that I took
This is my piece of actual code - https://pastebin.com/pfqDgVtX
As soon as I tried adding the following after Line 292 (after `.setModel`)
for row in range(self.tree_view.rowCount()):
data.append([])
for column in range(self.tree_view.columnCount()):
index = self.tree_view.index(row,
If I understand the goal, then something like this might work.
from maya import cmds
cmds.listRelatives("|group1", type="nurbsCurve", allDescendents=True)
If there’s a nurbsCurve on any path starting with |group1, then this would
return it.
*Test scene*
cmds.file(new=True, force=True)
circle =