PyQt6 QTreeWidget itemDelegate error?
kukovecmatic at hotmail.com
Fri Jun 17 23:23:05 BST 2022
Specs: Windows 10 x64, PyQt6.3.1.dev2206051323, Python3.9
I'm getting an error in a QTreeWidget when trying to access a delegate
through self.itemDelegate(index), the error is:
Traceback (most recent call last):
File "C:\projects\gui\newfiletree.py", line 235, in __create_item
delegate = self.itemDelegate(new_index)
TypeError: itemDelegate(self): too many arguments
This code works in PyQt5 (5.15.4), but not in PyQt6 (6.3.1.dev2206051323).
Am I doing something wrong or is this perhaps a bug?
Sorry, got it, it's self.itemDelegateForIndex on PyQt6.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the PyQt