QTreeView CustomDelegate set by setItemDelegateForRow stays with row index
Unsolved
General and Desktop
-
@gary-1959 said in QTreeView CustomDelegate set by setItemDelegateForRow stays with row index:
setItemDelegateForRow
Is there a way to set a CustomDelegate which will stay connected to the row item
So you enable your custom delegate for, say, row 3, then remove rows 1-2. After that your delegate for row 3 should be in row 1?!
I don't think that this is standard behavior, therefore you have to keep track on insertations and deletion yourself and handle them as desired. -
... or check inside the delegate functions if the row is still the one e.g. by checking the data to display.