Warning: That file was not part of the compilation database. It may have many parsing errors.

1/****************************************************************************
2**
3** Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies).
4** Contact: http://www.qt-project.org/legal
5**
6** This file is part of the documentation of the Qt Toolkit.
7**
8** $QT_BEGIN_LICENSE:FDL$
9** Commercial License Usage
10** Licensees holding valid commercial Qt licenses may use this file in
11** accordance with the commercial license agreement provided with the
12** Software or, alternatively, in accordance with the terms contained in
13** a written agreement between you and Digia. For licensing terms and
14** conditions see http://qt.digia.com/licensing. For further information
15** use the contact form at http://qt.digia.com/contact-us.
16**
17** GNU Free Documentation License Usage
18** Alternatively, this file may be used under the terms of the GNU Free
19** Documentation License version 1.3 as published by the Free Software
20** Foundation and appearing in the file included in the packaging of
21** this file. Please review the following information to ensure
22** the GNU Free Documentation License version 1.3 requirements
23** will be met: http://www.gnu.org/copyleft/fdl.html.
24** $QT_END_LICENSE$
25**
26****************************************************************************/
27
28/*!
29 \class QTestEventList
30 \inmodule QtTest
31
32 \brief The QTestEventList class provides a list of GUI events.
33
34 QTestEventList inherits from QList<QTestEvent *>, and provides
35 convenience functions for populating the list.
36
37 A QTestEventList can be populated with GUI events that can be
38 stored as test data for later usage, or be replayed on any
39 QWidget.
40
41 Example:
42 \snippet doc/src/snippets/code/doc_src_qtestevent.cpp 0
43
44 The example above simulates the user entering the character \c a
45 followed by a backspace, waiting for 200 milliseconds and
46 repeating it.
47*/
48
49/*! \fn QTestEventList::QTestEventList()
50
51 Constructs an empty QTestEventList.
52*/
53
54/*! \fn QTestEventList::QTestEventList(const QTestEventList &other)
55
56 Constructs a new QTestEventList as a copy of \a other.
57*/
58
59/*! \fn QTestEventList::~QTestEventList()
60
61 Empties the list and destroys all stored events.
62*/
63
64/*! \fn void QTestEventList::clear()
65
66 Removes all events from the list.
67*/
68
69/*! \fn void QTestEventList::addKeyClick(Qt::Key qtKey, Qt::KeyboardModifiers modifiers = Qt::NoModifier, int msecs = -1)
70
71 Adds a new key click to the list. The event will simulate the key \a qtKey with the modifier \a modifiers and then wait for \a msecs milliseconds.
72
73 \sa QTest::keyClick()
74*/
75
76/*! \fn void QTestEventList::addKeyPress(Qt::Key qtKey, Qt::KeyboardModifiers modifiers = Qt::NoModifier, int msecs = -1)
77
78 Adds a new key press to the list. The event will press the key \a qtKey with the modifier \a modifiers and then wait for \a msecs milliseconds.
79
80 \sa QTest::keyPress()
81*/
82
83/*! \fn void QTestEventList::addKeyRelease(Qt::Key qtKey, Qt::KeyboardModifiers modifiers = Qt::NoModifier, int msecs = -1)
84
85 Adds a new key release to the list. The event will release the key \a qtKey with the modifier \a modifiers and then wait for \a msecs milliseconds.
86
87 \sa QTest::keyRelease()
88
89*/
90
91/*! \fn void QTestEventList::addKeyEvent(QTest::KeyAction action, Qt::Key qtKey, Qt::KeyboardModifiers modifiers = Qt::NoModifier, int msecs = -1)
92 \internal
93*/
94
95/*! \fn void QTestEventList::addKeyClick(char ascii, Qt::KeyboardModifiers modifiers = Qt::NoModifier, int msecs = -1)
96
97 \overload
98
99 Adds a new key click to the list. The event will simulate the key \a ascii with the modifier \a modifiers and then wait for \a msecs milliseconds.
100
101 \sa QTest::keyClick()
102
103*/
104
105/*! \fn void QTestEventList::addKeyPress(char ascii, Qt::KeyboardModifiers modifiers = Qt::NoModifier, int msecs = -1)
106
107 \overload
108
109 Adds a new key press to the list. The event will press the key \a ascii with the modifier \a modifiers and then wait for \a msecs milliseconds.
110
111 \sa QTest::keyPress()
112*/
113
114/*! \fn void QTestEventList::addKeyRelease(char ascii, Qt::KeyboardModifiers modifiers = Qt::NoModifier, int msecs = -1)
115
116 \overload
117
118 Adds a new key release to the list. The event will release the key \a ascii with the modifier \a modifiers and then wait for \a msecs milliseconds.
119
120 \sa QTest::keyRelease()
121*/
122
123/*! \fn void QTestEventList::addKeyClicks(const QString &keys, Qt::KeyboardModifiers modifiers = Qt::NoModifier, int msecs = -1)
124
125 Adds new keyboard entries to the list. The event will press the \a keys with the \a modifiers and wait \a msecs milliseconds between each key.
126
127 \sa QTest::keyClicks()
128*/
129
130/*! \fn void QTestEventList::addKeyEvent(QTest::KeyAction action, char ascii, Qt::KeyboardModifiers modifiers = Qt::NoModifier, int msecs = -1)
131 \internal
132*/
133
134/*! \fn void QTestEventList::addDelay(int msecs)
135
136 Adds a \a msecs milliseconds delay.
137
138 \sa QTest::qWait()
139*/
140
141/*! \fn void QTestEventList::simulate(QWidget *w)
142
143 Simulates the events from the list one by one on the widget \a w.
144 For an example, please read the \l QTestEventList class documentation.
145*/
146
147/*! \fn void QTestEventList::addMousePress(Qt::MouseButton button, Qt::KeyboardModifiers modifiers = 0, QPoint pos = QPoint(), int delay=-1)
148
149 Add a mouse press to the list. The event will press the \a button with optional \a modifiers at the position \a pos with an optional \a delay. The default position is the center of the widget.
150
151 \sa QTest::mousePress()
152*/
153/*! \fn void QTestEventList::addMouseRelease(Qt::MouseButton button, Qt::KeyboardModifiers modifiers = 0, QPoint pos = QPoint(), int delay=-1)
154
155 Add a mouse release to the list. The event will release the \a button with optional \a modifiers at the position \a pos with an optional \a delay. The default position is the center of the widget.
156
157 \sa QTest::mouseRelease()
158*/
159/*! \fn void QTestEventList::addMouseClick(Qt::MouseButton button, Qt::KeyboardModifiers modifiers = 0, QPoint pos = QPoint(), int delay=-1)
160
161 Add a mouse click to the list. The event will click the \a button with optional \a modifiers at the position \a pos with an optional \a delay. The default position is the center of the widget.
162
163 \sa QTest::mouseClick()
164*/
165/*! \fn void QTestEventList::addMouseDClick(Qt::MouseButton button, Qt::KeyboardModifiers modifiers = 0, QPoint pos = QPoint(), int delay=-1)
166
167 Add a double mouse click to the list. The event will double click the \a button with optional \a modifiers at the position \a pos with an optional \a delay. The default position is the center of the widget.
168
169 \sa QTest::mousePress()
170*/
171/*! \fn void QTestEventList::addMouseMove(QPoint pos = QPoint(), int delay=-1)
172
173 Adds a mouse move to the list. The event will move the mouse to the position \a pos. If a \a delay (in milliseconds) is set, the test will wait after moving the mouse. The default position is the center of the widget.
174
175 \sa QTest::mousePress()
176*/
177
178

Warning: That file was not part of the compilation database. It may have many parsing errors.