~ubuntu-branches/ubuntu/oneiric/qwt/oneiric-proposed

« back to all changes in this revision

Viewing changes to doc/man/man3/QwtAbstractSlider.3

  • Committer: Bazaar Package Importer
  • Author(s): Fathi Boudra
  • Date: 2011-06-10 11:22:47 UTC
  • mfrom: (1.1.6 upstream) (2.1.4 sid)
  • Revision ID: james.westby@ubuntu.com-20110610112247-0i1019vvmzaq6p86
Tags: 6.0.0-1
* New upstream release (Closes: #624107):
  - drop Qt3 support. (Closes: #604379, #626868)
* Register documentation with doc-base. (Closes: #626567)
* Drop patches:
  - 01_makefiles.diff
  - 02_add_missing_warnings.diff
  - 03_qwt_branch_pull_r544.diff
* Add qwt_install_paths.patch to fix the hardcoded installation paths.
* Update debian/control:
  - drop libqt3-mt-dev build dependency.
  - bump Standards-Version to 3.9.2 (no changes).
  - drop Qt3 related packages.
  - due to bump soname (and as we dropper Qt3 support):
    - libqwt5-qt4-dev -> libqwt-dev
    - libqwt5-qt4 -> libqwt6
    - libqwt5-doc -> libqwt-doc
* Update debian/copyright file.
* Update debian/rules: drop Qt3 packages support.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
.TH "QwtAbstractSlider" 3 "Fri Apr 15 2011" "Version 6.0.0" "Qwt User's Guide" \" -*- nroff -*-
 
2
.ad l
 
3
.nh
 
4
.SH NAME
 
5
QwtAbstractSlider \- 
 
6
.PP
 
7
An abstract base class for slider widgets.  
 
8
 
 
9
.SH SYNOPSIS
 
10
.br
 
11
.PP
 
12
.PP
 
13
\fC#include <qwt_abstract_slider.h>\fP
 
14
.PP
 
15
Inherits \fBQwtDoubleRange\fP.
 
16
.PP
 
17
Inherited by \fBQwtDial\fP, \fBQwtKnob\fP, \fBQwtSlider\fP, and \fBQwtWheel\fP.
 
18
.SS "Public Types"
 
19
 
 
20
.in +1c
 
21
.ti -1c
 
22
.RI "enum \fBScrollMode\fP { \fBScrNone\fP, \fBScrMouse\fP, \fBScrTimer\fP, \fBScrDirect\fP, \fBScrPage\fP }"
 
23
.br
 
24
.in -1c
 
25
.SS "Public Slots"
 
26
 
 
27
.in +1c
 
28
.ti -1c
 
29
.RI "virtual void \fBsetValue\fP (double val)"
 
30
.br
 
31
.ti -1c
 
32
.RI "virtual void \fBfitValue\fP (double val)"
 
33
.br
 
34
.ti -1c
 
35
.RI "virtual void \fBincValue\fP (int steps)"
 
36
.br
 
37
.ti -1c
 
38
.RI "virtual void \fBsetReadOnly\fP (bool)"
 
39
.br
 
40
.in -1c
 
41
.SS "Signals"
 
42
 
 
43
.in +1c
 
44
.ti -1c
 
45
.RI "void \fBvalueChanged\fP (double value)"
 
46
.br
 
47
.ti -1c
 
48
.RI "void \fBsliderPressed\fP ()"
 
49
.br
 
50
.ti -1c
 
51
.RI "void \fBsliderReleased\fP ()"
 
52
.br
 
53
.ti -1c
 
54
.RI "void \fBsliderMoved\fP (double value)"
 
55
.br
 
56
.in -1c
 
57
.SS "Public Member Functions"
 
58
 
 
59
.in +1c
 
60
.ti -1c
 
61
.RI "\fBQwtAbstractSlider\fP (Qt::Orientation, QWidget *parent=NULL)"
 
62
.br
 
63
.ti -1c
 
64
.RI "virtual \fB~QwtAbstractSlider\fP ()"
 
65
.br
 
66
.ti -1c
 
67
.RI "void \fBsetUpdateTime\fP (int t)"
 
68
.br
 
69
.ti -1c
 
70
.RI "void \fBstopMoving\fP ()"
 
71
.br
 
72
.ti -1c
 
73
.RI "void \fBsetTracking\fP (bool enable)"
 
74
.br
 
75
.ti -1c
 
76
.RI "virtual void \fBsetMass\fP (double val)"
 
77
.br
 
78
.ti -1c
 
79
.RI "virtual double \fBmass\fP () const "
 
80
.br
 
81
.ti -1c
 
82
.RI "virtual void \fBsetOrientation\fP (Qt::Orientation o)"
 
83
.br
 
84
.ti -1c
 
85
.RI "Qt::Orientation \fBorientation\fP () const "
 
86
.br
 
87
.ti -1c
 
88
.RI "bool \fBisReadOnly\fP () const "
 
89
.br
 
90
.ti -1c
 
91
.RI "bool \fBisValid\fP () const "
 
92
.br
 
93
.ti -1c
 
94
.RI "void \fBsetValid\fP (bool valid)"
 
95
.br
 
96
.in -1c
 
97
.SS "Protected Member Functions"
 
98
 
 
99
.in +1c
 
100
.ti -1c
 
101
.RI "virtual void \fBsetPosition\fP (const QPoint &)"
 
102
.br
 
103
.ti -1c
 
104
.RI "virtual void \fBvalueChange\fP ()"
 
105
.br
 
106
.ti -1c
 
107
.RI "virtual void \fBtimerEvent\fP (QTimerEvent *e)"
 
108
.br
 
109
.ti -1c
 
110
.RI "virtual void \fBmousePressEvent\fP (QMouseEvent *e)"
 
111
.br
 
112
.ti -1c
 
113
.RI "virtual void \fBmouseReleaseEvent\fP (QMouseEvent *e)"
 
114
.br
 
115
.ti -1c
 
116
.RI "virtual void \fBmouseMoveEvent\fP (QMouseEvent *e)"
 
117
.br
 
118
.ti -1c
 
119
.RI "virtual void \fBkeyPressEvent\fP (QKeyEvent *e)"
 
120
.br
 
121
.ti -1c
 
122
.RI "virtual void \fBwheelEvent\fP (QWheelEvent *e)"
 
123
.br
 
124
.ti -1c
 
125
.RI "virtual double \fBgetValue\fP (const QPoint &p)=0"
 
126
.br
 
127
.ti -1c
 
128
.RI "virtual void \fBgetScrollMode\fP (const QPoint &pos, \fBScrollMode\fP &scrollMode, int &direction) const =0"
 
129
.br
 
130
.ti -1c
 
131
.RI "void \fBsetMouseOffset\fP (double)"
 
132
.br
 
133
.ti -1c
 
134
.RI "double \fBmouseOffset\fP () const "
 
135
.br
 
136
.ti -1c
 
137
.RI "int \fBscrollMode\fP () const "
 
138
.br
 
139
.in -1c
 
140
.SH "Detailed Description"
 
141
.PP 
 
142
An abstract base class for slider widgets. 
 
143
 
 
144
\fBQwtAbstractSlider\fP is a base class for slider widgets. It handles mouse events and updates the slider's value accordingly. Derived classes only have to implement the \fBgetValue()\fP and \fBgetScrollMode()\fP members, and should react to a \fBvalueChange()\fP, which normally requires repainting. 
 
145
.SH "Member Enumeration Documentation"
 
146
.PP 
 
147
.SS "enum \fBQwtAbstractSlider::ScrollMode\fP"Scroll mode 
 
148
.PP
 
149
\fBSee also:\fP
 
150
.RS 4
 
151
\fBgetScrollMode()\fP 
 
152
.RE
 
153
.PP
 
154
 
 
155
.PP
 
156
\fBEnumerator: \fP
 
157
.in +1c
 
158
.TP
 
159
\fB\fIScrNone \fP\fP
 
160
Scrolling switched off. Don't change the value. 
 
161
.TP
 
162
\fB\fIScrMouse \fP\fP
 
163
Change the value while the user keeps the button pressed and moves the mouse. 
 
164
.TP
 
165
\fB\fIScrTimer \fP\fP
 
166
Automatic scrolling. Increment the value in the specified direction as long as the user keeps the button pressed. 
 
167
.TP
 
168
\fB\fIScrPage \fP\fP
 
169
Automatic scrolling. Same as ScrTimer, but increment by page size. 
 
170
.SH "Constructor & Destructor Documentation"
 
171
.PP 
 
172
.SS "QwtAbstractSlider::QwtAbstractSlider (Qt::Orientationorientation, QWidget *parent = \fCNULL\fP)\fC [explicit]\fP"
 
173
.PP
 
174
Constructor. \fBParameters:\fP
 
175
.RS 4
 
176
\fIorientation\fP Orientation 
 
177
.br
 
178
\fIparent\fP Parent widget 
 
179
.RE
 
180
.PP
 
181
 
 
182
.SS "QwtAbstractSlider::~QwtAbstractSlider ()\fC [virtual]\fP"
 
183
.PP
 
184
Destructor. 
 
185
.SH "Member Function Documentation"
 
186
.PP 
 
187
.SS "void QwtAbstractSlider::fitValue (doublevalue)\fC [virtual, slot]\fP"
 
188
.PP
 
189
Set the slider's value to the nearest integer multiple of the step size. \fBParameters:\fP
 
190
.RS 4
 
191
\fIvalue\fP Value 
 
192
.RE
 
193
.PP
 
194
\fBSee also:\fP
 
195
.RS 4
 
196
\fBsetValue()\fP, \fBincValue()\fP 
 
197
.RE
 
198
.PP
 
199
 
 
200
.PP
 
201
Reimplemented from \fBQwtDoubleRange\fP.
 
202
.SS "virtual void QwtAbstractSlider::getScrollMode (const QPoint &pos, \fBScrollMode\fP &scrollMode, int &direction) const\fC [protected, pure virtual]\fP"
 
203
.PP
 
204
Determine what to do when the user presses a mouse button. This function is abstract and has to be implemented by derived classes. It is called on a mousePress event. The derived class can determine what should happen next in dependence of the position where the mouse was pressed by returning scrolling mode and direction.
 
205
.PP
 
206
\fBParameters:\fP
 
207
.RS 4
 
208
\fIpos\fP point where the mouse was pressed 
 
209
.RE
 
210
.PP
 
211
\fBReturn values:\fP
 
212
.RS 4
 
213
\fIscrollMode\fP The scrolling mode 
 
214
.br
 
215
\fIdirection\fP direction: 1, 0, or -1. 
 
216
.RE
 
217
.PP
 
218
 
 
219
.PP
 
220
Implemented in \fBQwtDial\fP, \fBQwtKnob\fP, \fBQwtSlider\fP, and \fBQwtWheel\fP.
 
221
.SS "virtual double QwtAbstractSlider::getValue (const QPoint &p)\fC [protected, pure virtual]\fP"
 
222
.PP
 
223
Determine the value corresponding to a specified poind. This is an abstract virtual function which is called when the user presses or releases a mouse button or moves the mouse. It has to be implemented by the derived class. 
 
224
.PP
 
225
\fBParameters:\fP
 
226
.RS 4
 
227
\fIp\fP point 
 
228
.RE
 
229
.PP
 
230
 
 
231
.PP
 
232
Implemented in \fBQwtDial\fP, \fBQwtKnob\fP, \fBQwtSlider\fP, and \fBQwtWheel\fP.
 
233
.SS "void QwtAbstractSlider::incValue (intsteps)\fC [virtual, slot]\fP"
 
234
.PP
 
235
Increment the value by a specified number of steps. \fBParameters:\fP
 
236
.RS 4
 
237
\fIsteps\fP number of steps 
 
238
.RE
 
239
.PP
 
240
\fBSee also:\fP
 
241
.RS 4
 
242
\fBsetValue()\fP 
 
243
.RE
 
244
.PP
 
245
 
 
246
.PP
 
247
Reimplemented from \fBQwtDoubleRange\fP.
 
248
.SS "bool QwtAbstractSlider::isReadOnly () const"In read only mode the slider can't be controlled by mouse or keyboard.
 
249
.PP
 
250
\fBReturns:\fP
 
251
.RS 4
 
252
true if read only 
 
253
.RE
 
254
.PP
 
255
\fBSee also:\fP
 
256
.RS 4
 
257
\fBsetReadOnly()\fP 
 
258
.RE
 
259
.PP
 
260
 
 
261
.SS "bool QwtAbstractSlider::isValid () const\fC [inline]\fP"\fBSee also:\fP
 
262
.RS 4
 
263
QwtDblRange::isValid() 
 
264
.RE
 
265
.PP
 
266
 
 
267
.PP
 
268
Reimplemented from \fBQwtDoubleRange\fP.
 
269
.SS "void QwtAbstractSlider::keyPressEvent (QKeyEvent *e)\fC [protected, virtual]\fP"Handles key events
 
270
.PP
 
271
.IP "\(bu" 2
 
272
Key_Down, KeyLeft
 
273
.br
 
274
 Decrement by 1
 
275
.IP "\(bu" 2
 
276
Key_Up, Key_Right
 
277
.br
 
278
 Increment by 1
 
279
.PP
 
280
.PP
 
281
\fBParameters:\fP
 
282
.RS 4
 
283
\fIe\fP Key event 
 
284
.RE
 
285
.PP
 
286
\fBSee also:\fP
 
287
.RS 4
 
288
\fBisReadOnly()\fP 
 
289
.RE
 
290
.PP
 
291
 
 
292
.PP
 
293
Reimplemented in \fBQwtCompass\fP, and \fBQwtDial\fP.
 
294
.SS "double QwtAbstractSlider::mass () const\fC [virtual]\fP"\fBReturns:\fP
 
295
.RS 4
 
296
mass 
 
297
.RE
 
298
.PP
 
299
\fBSee also:\fP
 
300
.RS 4
 
301
\fBsetMass()\fP 
 
302
.RE
 
303
.PP
 
304
 
 
305
.PP
 
306
Reimplemented in \fBQwtWheel\fP.
 
307
.SS "void QwtAbstractSlider::mouseMoveEvent (QMouseEvent *e)\fC [protected, virtual]\fP"Mouse Move Event handler 
 
308
.PP
 
309
\fBParameters:\fP
 
310
.RS 4
 
311
\fIe\fP Mouse event 
 
312
.RE
 
313
.PP
 
314
 
 
315
.SS "double QwtAbstractSlider::mouseOffset () const\fC [protected]\fP"\fBSee also:\fP
 
316
.RS 4
 
317
\fBsetMouseOffset()\fP 
 
318
.RE
 
319
.PP
 
320
 
 
321
.SS "void QwtAbstractSlider::mousePressEvent (QMouseEvent *e)\fC [protected, virtual]\fP"Mouse press event handler 
 
322
.PP
 
323
\fBParameters:\fP
 
324
.RS 4
 
325
\fIe\fP Mouse event 
 
326
.RE
 
327
.PP
 
328
 
 
329
.SS "void QwtAbstractSlider::mouseReleaseEvent (QMouseEvent *e)\fC [protected, virtual]\fP"Mouse Release Event handler 
 
330
.PP
 
331
\fBParameters:\fP
 
332
.RS 4
 
333
\fIe\fP Mouse event 
 
334
.RE
 
335
.PP
 
336
 
 
337
.SS "Qt::Orientation QwtAbstractSlider::orientation () const"\fBReturns:\fP
 
338
.RS 4
 
339
Orientation 
 
340
.RE
 
341
.PP
 
342
\fBSee also:\fP
 
343
.RS 4
 
344
\fBsetOrientation()\fP 
 
345
.RE
 
346
.PP
 
347
 
 
348
.SS "int QwtAbstractSlider::scrollMode () const\fC [protected]\fP"
 
349
.PP
 
350
sa ScrollMode 
 
351
.SS "void QwtAbstractSlider::setMass (doubleval)\fC [virtual]\fP"
 
352
.PP
 
353
Set the slider's mass for flywheel effect. If the slider's mass is greater then 0, it will continue to move after the mouse button has been released. Its speed decreases with time at a rate depending on the slider's mass. A large mass means that it will continue to move for a long time.
 
354
.PP
 
355
Derived widgets may overload this function to make it public.
 
356
.PP
 
357
\fBParameters:\fP
 
358
.RS 4
 
359
\fIval\fP New mass in kg
 
360
.RE
 
361
.PP
 
362
\fBSee also:\fP
 
363
.RS 4
 
364
\fBmass()\fP 
 
365
.RE
 
366
.PP
 
367
 
 
368
.PP
 
369
Reimplemented in \fBQwtWheel\fP.
 
370
.SS "void QwtAbstractSlider::setMouseOffset (doubleoffset)\fC [protected]\fP"\fBSee also:\fP
 
371
.RS 4
 
372
\fBmouseOffset()\fP 
 
373
.RE
 
374
.PP
 
375
 
 
376
.SS "void QwtAbstractSlider::setOrientation (Qt::Orientationo)\fC [virtual]\fP"
 
377
.PP
 
378
Set the orientation. \fBParameters:\fP
 
379
.RS 4
 
380
\fIo\fP Orientation. Allowed values are Qt::Horizontal and Qt::Vertical. 
 
381
.RE
 
382
.PP
 
383
 
 
384
.PP
 
385
Reimplemented in \fBQwtSlider\fP, and \fBQwtWheel\fP.
 
386
.SS "void QwtAbstractSlider::setPosition (const QPoint &p)\fC [protected, virtual]\fP"Move the slider to a specified point, adjust the value and emit signals if necessary. 
 
387
.SS "void QwtAbstractSlider::setReadOnly (boolreadOnly)\fC [virtual, slot]\fP"En/Disable read only mode
 
388
.PP
 
389
In read only mode the slider can't be controlled by mouse or keyboard.
 
390
.PP
 
391
\fBParameters:\fP
 
392
.RS 4
 
393
\fIreadOnly\fP Enables in case of true 
 
394
.RE
 
395
.PP
 
396
\fBSee also:\fP
 
397
.RS 4
 
398
\fBisReadOnly()\fP 
 
399
.RE
 
400
.PP
 
401
 
 
402
.SS "void QwtAbstractSlider::setTracking (boolenable)"
 
403
.PP
 
404
Enables or disables tracking. If tracking is enabled, the slider emits a \fBvalueChanged()\fP signal whenever its value changes (the default behaviour). If tracking is disabled, the value changed() signal will only be emitted if:
 
405
.PD 0
 
406
 
 
407
.IP "\(bu" 2
 
408
the user releases the mouse button and the value has changed or 
 
409
.IP "\(bu" 2
 
410
at the end of automatic scrolling.
 
411
.PP
 
412
Tracking is enabled by default. 
 
413
.PP
 
414
\fBParameters:\fP
 
415
.RS 4
 
416
\fIenable\fP \fCtrue\fP (enable) or \fCfalse\fP (disable) tracking. 
 
417
.RE
 
418
.PP
 
419
 
 
420
.SS "void QwtAbstractSlider::setUpdateTime (intt)"
 
421
.PP
 
422
Specify the update interval for automatic scrolling. \fBParameters:\fP
 
423
.RS 4
 
424
\fIt\fP update interval in milliseconds 
 
425
.RE
 
426
.PP
 
427
\fBSee also:\fP
 
428
.RS 4
 
429
\fBgetScrollMode()\fP 
 
430
.RE
 
431
.PP
 
432
 
 
433
.SS "void QwtAbstractSlider::setValid (boolvalid)\fC [inline]\fP"\fBParameters:\fP
 
434
.RS 4
 
435
\fIvalid\fP true/false 
 
436
.RE
 
437
.PP
 
438
\fBSee also:\fP
 
439
.RS 4
 
440
QwtDblRange::isValid() 
 
441
.RE
 
442
.PP
 
443
 
 
444
.PP
 
445
Reimplemented from \fBQwtDoubleRange\fP.
 
446
.SS "void QwtAbstractSlider::setValue (doubleval)\fC [virtual, slot]\fP"
 
447
.PP
 
448
Move the slider to a specified value. This function can be used to move the slider to a value which is not an integer multiple of the step size. 
 
449
.PP
 
450
\fBParameters:\fP
 
451
.RS 4
 
452
\fIval\fP new value 
 
453
.RE
 
454
.PP
 
455
\fBSee also:\fP
 
456
.RS 4
 
457
\fBfitValue()\fP 
 
458
.RE
 
459
.PP
 
460
 
 
461
.PP
 
462
Reimplemented from \fBQwtDoubleRange\fP.
 
463
.SS "void QwtAbstractSlider::sliderMoved (doublevalue)\fC [signal]\fP"This signal is emitted when the user moves the slider with the mouse. 
 
464
.PP
 
465
\fBParameters:\fP
 
466
.RS 4
 
467
\fIvalue\fP new value 
 
468
.RE
 
469
.PP
 
470
 
 
471
.SS "void QwtAbstractSlider::sliderPressed ()\fC [signal]\fP"This signal is emitted when the user presses the movable part of the slider (start ScrMouse Mode). 
 
472
.SS "void QwtAbstractSlider::sliderReleased ()\fC [signal]\fP"This signal is emitted when the user releases the movable part of the slider. 
 
473
.SS "void QwtAbstractSlider::stopMoving ()"
 
474
.PP
 
475
Stop updating if automatic scrolling is active. 
 
476
.SS "void QwtAbstractSlider::timerEvent (QTimerEvent *e)\fC [protected, virtual]\fP"Qt timer event 
 
477
.PP
 
478
\fBParameters:\fP
 
479
.RS 4
 
480
\fIe\fP Timer event 
 
481
.RE
 
482
.PP
 
483
 
 
484
.SS "void QwtAbstractSlider::valueChange ()\fC [protected, virtual]\fP"Notify change of value
 
485
.PP
 
486
This function can be reimplemented by derived classes in order to keep track of changes, i.e. repaint the widget. The default implementation emits a \fBvalueChanged()\fP signal if tracking is enabled. 
 
487
.PP
 
488
Reimplemented from \fBQwtDoubleRange\fP.
 
489
.PP
 
490
Reimplemented in \fBQwtDial\fP, \fBQwtSlider\fP, and \fBQwtWheel\fP.
 
491
.SS "void QwtAbstractSlider::valueChanged (doublevalue)\fC [signal]\fP"
 
492
.PP
 
493
Notify a change of value. In the default setting (tracking enabled), this signal will be emitted every time the value changes ( see \fBsetTracking()\fP ). 
 
494
.PP
 
495
\fBParameters:\fP
 
496
.RS 4
 
497
\fIvalue\fP new value 
 
498
.RE
 
499
.PP
 
500
 
 
501
.SS "void QwtAbstractSlider::wheelEvent (QWheelEvent *e)\fC [protected, virtual]\fP"Wheel Event handler 
 
502
.PP
 
503
\fBParameters:\fP
 
504
.RS 4
 
505
\fIe\fP Whell event 
 
506
.RE
 
507
.PP
 
508
 
 
509
 
 
510
.SH "Author"
 
511
.PP 
 
512
Generated automatically by Doxygen for Qwt User's Guide from the source code.