QTimerEvent Class
La clase QTimerEvent contiene parámetros que describen un evento de temporizador. Más información...
| Cabecera: | #include <QTimerEvent> |
| CMake: | find_package(Qt6 REQUIRED COMPONENTS Core) target_link_libraries(mytarget PRIVATE Qt6::Core) |
| qmake: | QT += core |
| Heredado de: | QEvent |
- Lista de todos los miembros, incluidos los heredados
- QTimerEvent forma parte de las clases de eventos.
Funciones públicas
(since 6.8) | QTimerEvent(Qt::TimerId timerId) |
| QTimerEvent(int timerId) | |
(since 6.8) Qt::TimerId | id() const |
(since 6.9) bool | matches(const QBasicTimer &timer) const |
| int | timerId() const |
Funciones protegidas
| QTimerEvent(QTimerEvent &&) | |
| QTimerEvent & | operator=(QTimerEvent &&) |
| QTimerEvent & | operator=(const QTimerEvent &other) |
Descripción detallada
Los eventos de temporizador se envían a intervalos regulares a los objetos que han iniciado uno o varios temporizadores. Cada temporizador tiene un identificador único. Un temporizador se inicia con QObject::startTimer().
La clase ` QChronoTimer ` proporciona una interfaz de programación de alto nivel que utiliza señales en lugar de eventos.
El controlador de eventos QObject::timerEvent() recibe los eventos del temporizador.
Véase también QChronoTimer, QObject::timerEvent(), QObject::startTimer() y QObject::killTimer().
Documentación de las funciones de miembro
[explicit, since 6.8] QTimerEvent::QTimerEvent(Qt::TimerId timerId)
Crea un objeto de evento de temporizador con el identificador del temporizador establecido en « timerId ».
Esta función se introdujo en Qt 6.8.
[explicit] QTimerEvent::QTimerEvent(int timerId)
Crea un objeto de evento de temporizador con el identificador del temporizador establecido en « timerId ».
[protected delete] QTimerEvent::QTimerEvent(QTimerEvent &&)
Crea una instancia de ` QTimerEvent`. Esta función ha sido eliminada.
[since 6.8] Qt::TimerId QTimerEvent::id() const
Devuelve el identificador « Qt::TimerId » del temporizador asociado a este evento, que es el mismo identificador que devuelve la función « QObject::startTimer()», convertido a « Qt::TimerId ».
Esta función se introdujo en Qt 6.8.
[noexcept, since 6.9] bool QTimerEvent::matches(const QBasicTimer &timer) const
Devuelve « true » si este evento de temporizador y « timer » tienen el mismo ID; en caso contrario, devuelve « false ».
Esta función se introdujo en Qt 6.9.
int QTimerEvent::timerId() const
Devuelve el identificador único del temporizador, que es el mismo identificador que devuelve la función ` QObject::startTimer()`.
[protected delete] QTimerEvent &QTimerEvent::operator=(QTimerEvent &&)
Asigna mediante «move» other a esta instancia de QTimerEvent. Esta función se elimina.
[noexcept protected default] QTimerEvent &QTimerEvent::operator=(const QTimerEvent &other)
Asigna por copia other a esta instancia de QTimerEvent.
© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.