Perşembe 13 Nisan 2006 17:27 tarihinde, Mateusz Korniak şunları yazmıştı: 
> I have multithread pyqt/pykde application.
> I leave first thread to run qt-loop.
>
> I want long execution time code to be run in different threads as in
> background. [1]
>
> How can I interact from those background threads with my qt GUI ? (send
> signal, update text in QLineEdit) ?

You can post an event from the thread using QApplication::postEvent [1] and 
process the event in main gui with QObject::customEvent [2] . Don't use 
signal/slots across threads , Xlib is not thread safe.

[1] http://doc.trolltech.com/3.3/qapplication.html#postEvent
[2] http://doc.trolltech.com/3.3/qobject.html#customEvent

Hope this helps,
ismail

-- 
<Terwou> \\o \o> <o/ o//

Attachment: pgpQmj3R9RA3y.pgp
Description: PGP signature

_______________________________________________
PyKDE mailing list    [email protected]
http://mats.imk.fraunhofer.de/mailman/listinfo/pykde

Reply via email to