[PyQt] Combobox inside a delegate in a proxy widget

Selim Tuvi selim.tuvi at dreamworks.com
Fri Jan 18 21:20:27 GMT 2013


I have a QGraphicsScene and inside it I have a proxy widget with a
QListWidget that has a delegate which creates a QComboBox

When I trigger the editing by clicking on an item in the list widget, I can
use the keyboard to navigate between the items in the combo box but as soon
as I use the mouse to open up the drop down list of the combo box, it
immediately closes. I am attaching a simple example.

I tried messing with the focus events, installing an event filter but none
of them work.

I am using Qt 4.7 and PyQt 4.8.6.

I have also verified this with a C++ Qt app so PyQt has nothing to do with
the problem. Also with Qt 5.0, using the mouse causes the app to crash as
soon as I try to open up the combo drop down.

Thanks
-Selim
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20130118/093017c1/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: simple_scene.py
Type: application/octet-stream
Size: 1364 bytes
Desc: not available
URL: <http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20130118/093017c1/attachment.obj>


More information about the PyQt mailing list