summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/corelib/kernel/qtimer.cpp20
1 files changed, 16 insertions, 4 deletions
diff --git a/src/corelib/kernel/qtimer.cpp b/src/corelib/kernel/qtimer.cpp
index f40f491..2e34592 100644
--- a/src/corelib/kernel/qtimer.cpp
+++ b/src/corelib/kernel/qtimer.cpp
@@ -101,10 +101,22 @@ QT_BEGIN_NAMESPACE
more and more platforms, and we expect that zero-millisecond
QTimers will gradually be replaced by \l{QThread}s.
- Note that QTimer's accuracy depends on the underlying operating
- system and hardware. Most platforms support an accuracy of
- 1 millisecond. If Qt is unable to deliver the requested number of
- timer clicks, it will silently discard some.
+ \section1 Accuracy and Timer Resolution
+
+ Timers will never time out earlier than the specified timeout value
+ and they are not guaranteed to time out at the exact value specified.
+ In many situations, they may time out late by a period of time that
+ depends on the accuracy of the system timers.
+
+ The accuracy of timers depends on the underlying operating system
+ and hardware. Most platforms support a resolution of 1 millisecond,
+ though the accuracy of the timer will not equal this resolution
+ in many real-world situations.
+
+ If Qt is unable to deliver the requested number of timer clicks,
+ it will silently discard some.
+
+ \section1 Alternatives to QTimer
An alternative to using QTimer is to call QObject::startTimer()
for your object and reimplement the QObject::timerEvent() event