PDA

View Full Version : QTreeWidget item with multiple parents



di_zou
16th November 2009, 15:32
I have a QtreeWidget with a bunch of QTreeWidgetItems. I want some of the items to have multiple parents. Is this possible? How would I do something like this:

ParentItem1
--Child1
----Child2
--Child3
----Child4
I want Child2 and Child4 to be the same item. So if I were to edit Child2, Child4 would be changed and vice versa.

I guess I could connect the items with a signal from Child2 to change Child4 and a signal from Child4 to change Child2, but I would like to have the two items to actually be one object.