开发者

PyQt Hide QDialogs Inside of QTreeWidget

开发者 https://www.devze.com 2023-02-17 00:23 出处:网络
I have a QTreeWidget with QComboBoxes inside of it.I would like 开发者_Python百科to be able to hide the combo boxes.

I have a QTreeWidget with QComboBoxes inside of it. I would like 开发者_Python百科to be able to hide the combo boxes.

I am getting the QComboBox out of the tree using the itemWidget function. I have tried using setVisible(False) and hide() but neither work. Can anyone explain why this is the case and possibly offer a soultion?

I suspect it has something to do with the QTreeWidget or the QTreeWidgetItems controlling the visibility of its widgets.


Have you tried putting the QComboBoxes inside a layout inside a QWidget, and placing the QWidget in the QTreeWidget?

0

精彩评论

暂无评论...
验证码 换一张
取 消