[Qt-interest] Running wx from a thread

Javier Urien javierurien at gmail.com
Tue Jul 6 22:03:08 CEST 2010


Hello List,

   I am trying to run a wxWidgets application from a QThread and run
into some problems. First let me say that I want to start adding QT to
a wxWidgets application and make the transition as smooth as I can,
that's the reason for this Qt-wx madness.
   I consulted the wx developer lists and they say in theory it should work.
   I based my qt app in QMandelbrot example, so the layout is like
this. A Qt application with a main window, a Qthread with a run() from
where I launch the wx-minimal example's main loop.

   From here the application hangs, and using the debugger I find that
the main thread is calling methods of the wxapp object through
QEventDispatcherGlib. I searched and could not find something
helpfull. Can anyone point me to the right aproach to this problem?
(please, rewriting is not an option right now).

   Also it is worth noting that, when run from the main thread the
wxapp works, but the qt application does not (due to the fact that the
qt application loop is not running)

TIA.



More information about the Qt-interest-old mailing list