[PyQt] wx.MilliSleep equivalent

Jones, Bryan bjones at ece.msstate.edu
Fri Sep 21 20:40:09 BST 2018


See http://doc.qt.io/qt-5/qtest.html#qWait. Of course, a much better
approach is to schedule an event using a timer. To quit an app after 1000
ms, you can use QTimer.singleShot(1000, app.quit), where app is your
QApplication instance.

On Fri, Sep 21, 2018 at 1:23 PM Tong Zhang <warriorlance at gmail.com> wrote:

> Hello,
>
> When I'm building applications by wxPython, there is a function
> wx.MilliSleep could be used to do non-GUI-block sleep, while I cannot find
> the similar thing in PyQt, is it available or not? Otherwise, what I can do
> to is to use QThread. Any comment is appreciated!
>
> Tong
>


-- 
Bryan A. Jones, Ph.D.
Associate Professor
Department of Electrical and Computer Engineering
231 Simrall / PO Box 9571
Mississippi State University
Mississippi State, MS 39762
http://www.ece.msstate.edu/~bjones
bjones AT ece DOT msstate DOT edu
voice 662-325-3149
fax 662-325-2298

Our Master, Jesus Christ, is on his way. He'll show up right on
time, his arrival guaranteed by the Blessed and Undisputed Ruler,
High King, High God.
- 1 Tim. 6:14b-15 (The Message)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.riverbankcomputing.com/pipermail/pyqt/attachments/20180921/a3b4e29f/attachment.html>


More information about the PyQt mailing list