Skip to content

PythonQt.QtCore.QEventLoop · declarations 001

Back to PythonQt.QtCore.QEventLoop

AllEvents instance-attribute

AllEvents: Any

DialogExec instance-attribute

DialogExec: Any

EventLoopExec instance-attribute

EventLoopExec: Any

ExcludeSocketNotifiers instance-attribute

ExcludeSocketNotifiers: Any

ExcludeUserInputEvents instance-attribute

ExcludeUserInputEvents: Any

ProcessEventsFlag instance-attribute

ProcessEventsFlag: type

int([x]) -> integer int(x, base=10) -> integer

Convert a number or string to an integer, or return 0 if no arguments are given. If x is a number, return x.int(). For floating point numbers, this truncates towards zero.

If x is not a number or if base is given, then x must be a string, bytes, or bytearray instance representing an integer literal in the given base. The literal can be preceded by '+' or '-' and be surrounded by whitespace. The base defaults to 10. Valid bases are 0 and 2-36. Base 0 means to interpret the base from the string as an integer literal.

int('0b100', base=0) 4

ProcessEventsFlags instance-attribute

ProcessEventsFlags: type

int([x]) -> integer int(x, base=10) -> integer

Convert a number or string to an integer, or return 0 if no arguments are given. If x is a number, return x.int(). For floating point numbers, this truncates towards zero.

If x is not a number or if base is given, then x must be a string, bytes, or bytearray instance representing an integer literal in the given base. The literal can be preceded by '+' or '-' and be surrounded by whitespace. The base defaults to 10. Valid bases are 0 and 2-36. Base 0 means to interpret the base from the string as an integer literal.

int('0b100', base=0) 4

WaitForMoreEvents instance-attribute

WaitForMoreEvents: Any

X11ExcludeTimers instance-attribute

X11ExcludeTimers: Any

destroyed

destroyed(*args: Any, **kwargs: Any) -> Any

Native PythonQt.QtCore.QEventLoop.destroyed; argument details are not documented.

event

event(event: Any) -> bool

X.event(event) -> bool

Supplemental documentation: Qt 5 reference:

[override virtual] bool QEventLoop::event(QEvent *event)

Reimplements: QObject::event(QEvent *e).

Upstream PySide2 reference signatures (binding differences may apply):

event(self, event: PySide2.QtCore.QEvent) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qeventloop.html#event

exec

exec(arg0: flags) -> int

X.exec(flags) -> int

Supplemental documentation: Qt 5 reference:

int QEventLoop::exec(QEventLoop::ProcessEventsFlags flags \= AllEvents)

Enters the main event loop and waits until exit() is called. Returns the value that was passed to exit().

If flags are specified, only events of the types allowed by the flags will be processed.

It is necessary to call this function to start event handling. The main event loop receives events from the window system and dispatches these to the application widgets.

Generally speaking, no user interaction can take place before calling exec(). As a special case, modal widgets like QMessageBox can be used before calling exec(), because modal widgets use their own local event loop.

To make your application perform idle processing (i.e. executing a special function whenever there are no pending events), use a QTimer with 0 timeout. More sophisticated idle processing schemes can be achieved using processEvents().

See also QCoreApplication::quit(), exit(), and processEvents().

Source: https://doc.qt.io/archives/qt-5.15/qeventloop.html#exec

exit

exit(returnCode: int) -> None

X.exit(returnCode)

Supplemental documentation: Qt 5 reference:

void QEventLoop::exit(int returnCode \= 0)

Tells the event loop to exit with a return code.

After this function has been called, the event loop returns from the call to exec(). The exec() function returns returnCode.

By convention, a returnCode of 0 means success, and any non-zero value indicates an error.

Note that unlike the C library function of the same name, this function does return to the caller -- it is event processing that stops.

See also QCoreApplication::quit(), quit(), and exec().

Upstream PySide2 reference signatures (binding differences may apply):

exit(self, returnCode: int=...) -> None

Source: https://doc.qt.io/archives/qt-5.15/qeventloop.html#exit

isRunning

isRunning() -> bool

X.isRunning() -> bool

Supplemental documentation: Qt 5 reference:

bool QEventLoop::isRunning() const

Returns true if the event loop is running; otherwise returns false. The event loop is considered running from the time when exec() is called until exit() is called.

See also exec() and exit().

Upstream PySide2 reference signatures (binding differences may apply):

isRunning(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qeventloop.html#isRunning

objectNameChanged

objectNameChanged(*args: Any, **kwargs: Any) -> Any

Native PythonQt.QtCore.QEventLoop.objectNameChanged; argument details are not documented.

processEvents

processEvents(arg0: flags, maximumTime: Any) -> bool

X.processEvents(flags, maximumTime) -> bool

Supplemental documentation: Qt 5 reference:

bool QEventLoop::processEvents(QEventLoop::ProcessEventsFlags flags \= ...)

Processes some pending events that match flags. Returns true if pending events were handled; otherwise returns false.

This function is especially useful if you have a long running operation and want to show its progress without allowing user input; i.e. by using the ExcludeUserInputEvents flag.

This function is simply a wrapper for QAbstractEventDispatcher::processEvents(). See the documentation for that function for details.

void QEventLoop::processEvents(QEventLoop::ProcessEventsFlags flags, int maxTime)

Process pending events that match flags for a maximum of maxTime milliseconds, or until there are no more events to process, whichever is shorter. This function is especially useful if you have a long running operation and want to show its progress without allowing user input, i.e. by using the ExcludeUserInputEvents flag.

Notes:

  • This function does not process events continuously; it returns after all available events are processed.
  • Specifying the WaitForMoreEvents flag makes no sense and will be ignored.

Upstream PySide2 reference signatures (binding differences may apply):

processEvents(self, flags: PySide2.QtCore.QEventLoop.ProcessEventsFlags, maximumTime: int) -> None
processEvents(self, flags: PySide2.QtCore.QEventLoop.ProcessEventsFlags=...) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qeventloop.html#processEvents

quit

quit() -> None

X.quit()

Supplemental documentation: Qt 5 reference:

[slot] void QEventLoop::quit()

Tells the event loop to exit normally.

Same as exit(0).

See also QCoreApplication::quit() and exit().

Upstream PySide2 reference signatures (binding differences may apply):

quit(self) -> None

Source: https://doc.qt.io/archives/qt-5.15/qeventloop.html#quit

wakeUp

wakeUp() -> None

X.wakeUp()

Supplemental documentation: Qt 5 reference:

void QEventLoop::wakeUp()

Wakes up the event loop.

See also QAbstractEventDispatcher::wakeUp().

Upstream PySide2 reference signatures (binding differences may apply):

wakeUp(self) -> None

Source: https://doc.qt.io/archives/qt-5.15/qeventloop.html#wakeUp