~oif-team/ubuntu/natty/qt4-x11/xi2.1

« back to all changes in this revision

Viewing changes to .pc/debian-changes-4:4.7.1-0ubuntu7/doc/html/qscrollbar.html

  • Committer: Bazaar Package Importer
  • Author(s): Jonathan Riddell
  • Date: 2011-01-18 20:37:32 UTC
  • Revision ID: james.westby@ubuntu.com-20110118203732-butn2uvaa6hydoqu
Tags: 4:4.7.1-0ubuntu8
Add kubuntu_26_dbusconnection_pointer.diff,
kubuntu_27_dbus_signal_filter_passes_not_handled.diff from Qt 4.8
to add a way to obtain the DBusConnectionpointer from a
QDBusConnection.  Requested by Ryan Lortie

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
<?xml version="1.0" encoding="UTF-8"?>
2
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
 
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en_US" lang="en_US">
4
 
<head>
5
 
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
 
<!-- qscrollbar.cpp -->
7
 
  <title>Qt 4.7: QScrollBar Class Reference</title>
8
 
  <link rel="stylesheet" type="text/css" href="style/style.css" />
9
 
  <script src="scripts/jquery.js" type="text/javascript"></script>
10
 
  <script src="scripts/functions.js" type="text/javascript"></script>
11
 
</head>
12
 
<body class="offline narrow creator">
13
 
 <div class="header" id="qtdocheader">
14
 
    <div class="content"> 
15
 
    <div id="nav-logo">
16
 
      <a href="index.html">Home</a></div>
17
 
    <a href="index.html" class="qtref"><span>Qt Reference Documentation</span></a>
18
 
    <div id="nav-topright">
19
 
      <ul>
20
 
        <li class="nav-topright-home"><a href="http://qt.nokia.com/">Qt HOME</a></li>
21
 
        <li class="nav-topright-dev"><a href="http://developer.qt.nokia.com/">DEV</a></li>
22
 
        <li class="nav-topright-labs"><a href="http://labs.qt.nokia.com/blogs/">LABS</a></li>
23
 
        <li class="nav-topright-doc nav-topright-doc-active"><a href="http://doc.qt.nokia.com/">
24
 
          DOC</a></li>
25
 
        <li class="nav-topright-blog"><a href="http://blog.qt.nokia.com/">BLOG</a></li>
26
 
      </ul>
27
 
    </div>
28
 
    <div id="shortCut">
29
 
      <ul>
30
 
        <li class="shortCut-topleft-inactive"><span><a href="index.html">Qt 4.7</a></span></li>
31
 
        <li class="shortCut-topleft-active"><a href="http://doc.qt.nokia.com">ALL VERSIONS        </a></li>
32
 
      </ul>
33
 
     </div>
34
 
 <ul class="sf-menu sf-js-enabled sf-shadow" id="narrowmenu"> 
35
 
                 <li><a href="#">API Lookup</a> 
36
 
                         <ul id="topmenuLook"> 
37
 
                           <li><a href="classes.html">Class index</a></li> 
38
 
                          <li><a href="functions.html">Function index</a></li> 
39
 
                           <li><a href="modules.html">Modules</a></li> 
40
 
                           <li><a href="namespaces.html">Namespaces</a></li> 
41
 
                           <li><a href="qtglobal.html">Global Declarations</a></li> 
42
 
                           <li><a href="licensing.html">Licenses and Credits</a></li> 
43
 
                           </ul> 
44
 
                 </li> 
45
 
                 <li><a href="#">Qt Topics</a> 
46
 
                         <ul id="topmenuTopic"> 
47
 
                           <li><a href="qt-basic-concepts.html">Programming with Qt</a></li> 
48
 
                           <li><a href="qtquick.html">Device UI's &amp; Qt Quick</a></li> 
49
 
                           <li><a href="qt-gui-concepts.html">UI Design with Qt</a></li> 
50
 
                           <li><a href="developing-with-qt.html">Cross-platform and Platform-specific</a></li> 
51
 
                           <li><a href="platform-specific.html">Platform-specific info</a></li> 
52
 
                           <li><a href="technology-apis.html">Qt and Key Technologies</a></li> 
53
 
                           <li><a href="best-practices.html">How-To's and Best Practices</a></li> 
54
 
                         </ul> 
55
 
                </li> 
56
 
                 <li><a href="#">Examples</a> 
57
 
                         <ul id="topmenuexample"> 
58
 
                                 <li><a href="all-examples.html">Examples</a></li> 
59
 
                                 <li><a href="tutorials.html">Tutorials</a></li> 
60
 
                                 <li><a href="demos.html">Demos</a></li> 
61
 
                                 <li><a href="qdeclarativeexamples.html">QML Examples</a></li> 
62
 
                         </ul> 
63
 
                 </li> 
64
 
 </ul> 
65
 
    </div>
66
 
  </div>
67
 
  <div class="wrapper">
68
 
    <div class="hd">
69
 
      <span></span>
70
 
    </div>
71
 
    <div class="bd group">
72
 
      <div class="sidebar">
73
 
        <div class="searchlabel">
74
 
          Search index:</div>
75
 
        <div class="search">
76
 
          <form id="qtdocsearch" action="" onsubmit="return false;">
77
 
            <fieldset>
78
 
              <input type="text" name="searchstring" id="pageType" value="" />
79
 
            </fieldset>
80
 
          </form>
81
 
        </div>
82
 
        <div class="box first bottombar" id="lookup">
83
 
          <h2 title="API Lookup"><span></span>
84
 
            API Lookup</h2>
85
 
          <div  id="list001" class="list">
86
 
          <ul id="ul001" >
87
 
              <li class="defaultLink"><a href="classes.html">Class index</a></li>
88
 
              <li class="defaultLink"><a href="functions.html">Function index</a></li>
89
 
              <li class="defaultLink"><a href="modules.html">Modules</a></li>
90
 
              <li class="defaultLink"><a href="namespaces.html">Namespaces</a></li>
91
 
              <li class="defaultLink"><a href="qtglobal.html">Global Declarations</a></li>
92
 
              <li class="defaultLink"><a href="qdeclarativeelements.html">QML elements</a></li>
93
 
            </ul> 
94
 
          </div>
95
 
        </div>
96
 
        <div class="box bottombar" id="topics">
97
 
          <h2 title="Qt Topics"><span></span>
98
 
            Qt Topics</h2>
99
 
          <div id="list002" class="list">
100
 
            <ul id="ul002" >
101
 
                           <li class="defaultLink"><a href="qt-basic-concepts.html">Programming with Qt</a></li> 
102
 
                           <li class="defaultLink"><a href="qtquick.html">Device UI's &amp; Qt Quick</a></li> 
103
 
                           <li class="defaultLink"><a href="qt-gui-concepts.html">UI Design with Qt</a></li> 
104
 
                           <li class="defaultLink"><a href="developing-with-qt.html">Cross-platform and Platform-specific</a></li> 
105
 
                           <li class="defaultLink"><a href="platform-specific.html">Platform-specific info</a></li> 
106
 
                           <li class="defaultLink"><a href="technology-apis.html">Qt and Key Technologies</a></li> 
107
 
                           <li class="defaultLink"><a href="best-practices.html">How-To's and Best Practices</a></li> 
108
 
            </ul>  
109
 
          </div>
110
 
        </div>
111
 
        <div class="box" id="examples">
112
 
          <h2 title="Examples"><span></span>
113
 
            Examples</h2>
114
 
          <div id="list003" class="list">
115
 
        <ul id="ul003">
116
 
              <li class="defaultLink"><a href="all-examples.html">Examples</a></li>
117
 
              <li class="defaultLink"><a href="tutorials.html">Tutorials</a></li>
118
 
              <li class="defaultLink"><a href="demos.html">Demos</a></li>
119
 
              <li class="defaultLink"><a href="qdeclarativeexamples.html">QML Examples</a></li>
120
 
            </ul> 
121
 
          </div>
122
 
        </div>
123
 
      </div>
124
 
      <div class="wrap">
125
 
        <div class="toolbar">
126
 
          <div class="breadcrumb toolblock">
127
 
            <ul>
128
 
              <li class="first"><a href="index.html">Home</a></li>
129
 
              <!--  Bread crumbs goes here -->
130
 
              <li><a href="modules.html">Modules</a></li>              <li><a href="qtgui.html">QtGui</a></li>
131
 
              <li>QScrollBar</li>
132
 
            </ul>
133
 
          </div>
134
 
          <div class="toolbuttons toolblock">
135
 
            <ul>
136
 
              <li id="smallA" class="t_button">A</li>
137
 
              <li id="medA" class="t_button active">A</li>
138
 
              <li id="bigA" class="t_button">A</li>
139
 
              <li id="print" class="t_button"><a href="javascript:this.print();">
140
 
                <span>Print</span></a></li>
141
 
            </ul>
142
 
        </div>
143
 
        </div>
144
 
        <div class="content">
145
 
<div class="toc">
146
 
<h3><a name="toc">Contents</a></h3>
147
 
<ul>
148
 
<li class="level1"><a href="#public-functions">Public Functions</a></li>
149
 
<li class="level1"><a href="#protected-functions">Protected Functions</a></li>
150
 
<li class="level1"><a href="#details">Detailed Description</a></li>
151
 
</ul>
152
 
</div>
153
 
<h1 class="title">QScrollBar Class Reference</h1>
154
 
<!-- $$$QScrollBar-brief -->
155
 
<p>The QScrollBar widget provides a vertical or horizontal scroll bar. <a href="#details">More...</a></p>
156
 
<!-- @@@QScrollBar -->
157
 
<pre class="highlightedCode brush: cpp"> #include &lt;QScrollBar&gt;</pre><p>Inherits <a href="qabstractslider.html">QAbstractSlider</a>.</p>
158
 
<ul>
159
 
<li><a href="qscrollbar-members.html">List of all members, including inherited members</a></li>
160
 
<li><a href="qscrollbar-qt3.html">Qt 3 support members</a></li>
161
 
</ul>
162
 
<a name="public-functions"></a>
163
 
<h2>Public Functions</h2>
164
 
<table class="alignedsummary">
165
 
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qscrollbar.html#QScrollBar">QScrollBar</a></b> ( QWidget * <i>parent</i> = 0 )</td></tr>
166
 
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qscrollbar.html#QScrollBar-2">QScrollBar</a></b> ( Qt::Orientation <i>orientation</i>, QWidget * <i>parent</i> = 0 )</td></tr>
167
 
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qscrollbar.html#dtor.QScrollBar">~QScrollBar</a></b> ()</td></tr>
168
 
</table>
169
 
<a name="reimplemented-public-functions"></a>
170
 
<h2>Reimplemented Public Functions</h2>
171
 
<table class="alignedsummary">
172
 
<tr><td class="memItemLeft rightAlign topAlign"> virtual bool </td><td class="memItemRight bottomAlign"><b><a href="qscrollbar.html#event">event</a></b> ( QEvent * <i>event</i> )</td></tr>
173
 
<tr><td class="memItemLeft rightAlign topAlign"> virtual QSize </td><td class="memItemRight bottomAlign"><b><a href="qscrollbar.html#sizeHint">sizeHint</a></b> () const</td></tr>
174
 
</table>
175
 
<ul>
176
 
<li class="fn">22 public functions inherited from <a href="qabstractslider.html#public-functions">QAbstractSlider</a></li>
177
 
<li class="fn">217 public functions inherited from <a href="qwidget.html#public-functions">QWidget</a></li>
178
 
<li class="fn">29 public functions inherited from <a href="qobject.html#public-functions">QObject</a></li>
179
 
<li class="fn">13 public functions inherited from <a href="qpaintdevice.html#public-functions">QPaintDevice</a></li>
180
 
</ul>
181
 
<a name="protected-functions"></a>
182
 
<h2>Protected Functions</h2>
183
 
<table class="alignedsummary">
184
 
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qscrollbar.html#initStyleOption">initStyleOption</a></b> ( QStyleOptionSlider * <i>option</i> ) const</td></tr>
185
 
</table>
186
 
<a name="reimplemented-protected-functions"></a>
187
 
<h2>Reimplemented Protected Functions</h2>
188
 
<table class="alignedsummary">
189
 
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="qscrollbar.html#contextMenuEvent">contextMenuEvent</a></b> ( QContextMenuEvent * <i>event</i> )</td></tr>
190
 
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="qscrollbar.html#hideEvent">hideEvent</a></b> ( QHideEvent * )</td></tr>
191
 
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="qscrollbar.html#mouseMoveEvent">mouseMoveEvent</a></b> ( QMouseEvent * <i>e</i> )</td></tr>
192
 
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="qscrollbar.html#mousePressEvent">mousePressEvent</a></b> ( QMouseEvent * <i>e</i> )</td></tr>
193
 
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="qscrollbar.html#mouseReleaseEvent">mouseReleaseEvent</a></b> ( QMouseEvent * <i>e</i> )</td></tr>
194
 
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="qscrollbar.html#paintEvent">paintEvent</a></b> ( QPaintEvent * )</td></tr>
195
 
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="qscrollbar.html#sliderChange">sliderChange</a></b> ( SliderChange <i>change</i> )</td></tr>
196
 
</table>
197
 
<ul>
198
 
<li class="fn">8 protected functions inherited from <a href="qabstractslider.html#protected-functions">QAbstractSlider</a></li>
199
 
<li class="fn">37 protected functions inherited from <a href="qwidget.html#protected-functions">QWidget</a></li>
200
 
<li class="fn">7 protected functions inherited from <a href="qobject.html#protected-functions">QObject</a></li>
201
 
<li class="fn">1 protected function inherited from <a href="qpaintdevice.html#protected-functions">QPaintDevice</a></li>
202
 
</ul>
203
 
<h3>Additional Inherited Members</h3>
204
 
<ul>
205
 
<li class="fn">11 properties inherited from <a href="qabstractslider.html#properties">QAbstractSlider</a></li>
206
 
<li class="fn">58 properties inherited from <a href="qwidget.html#properties">QWidget</a></li>
207
 
<li class="fn">1 property inherited from <a href="qobject.html#properties">QObject</a></li>
208
 
<li class="fn">2 public slots inherited from <a href="qabstractslider.html#public-slots">QAbstractSlider</a></li>
209
 
<li class="fn">19 public slots inherited from <a href="qwidget.html#public-slots">QWidget</a></li>
210
 
<li class="fn">1 public slot inherited from <a href="qobject.html#public-slots">QObject</a></li>
211
 
<li class="fn">6 signals inherited from <a href="qabstractslider.html#signals">QAbstractSlider</a></li>
212
 
<li class="fn">1 signal inherited from <a href="qwidget.html#signals">QWidget</a></li>
213
 
<li class="fn">1 signal inherited from <a href="qobject.html#signals">QObject</a></li>
214
 
<li class="fn">4 static public members inherited from <a href="qwidget.html#static-public-members">QWidget</a></li>
215
 
<li class="fn">5 static public members inherited from <a href="qobject.html#static-public-members">QObject</a></li>
216
 
<li class="fn">1 protected slot inherited from <a href="qwidget.html#protected-slots">QWidget</a></li>
217
 
</ul>
218
 
<a name="details"></a>
219
 
<!-- $$$QScrollBar-description -->
220
 
<div class="descr">
221
 
<h2>Detailed Description</h2>
222
 
<p>The QScrollBar widget provides a vertical or horizontal scroll bar.</p>
223
 
<p>A scroll bar is a control that enables the user to access parts of a document that is larger than the widget used to display it. It provides a visual indication of the user's current position within the document and the amount of the document that is visible. Scroll bars are usually equipped with other controls that enable more accurate navigation. Qt displays scroll bars in a way that is appropriate for each platform.</p>
224
 
<p>If you need to provide a scrolling view onto another widget, it may be more convenient to use the <a href="qscrollarea.html">QScrollArea</a> class because this provides a viewport widget and scroll bars. QScrollBar is useful if you need to implement similar functionality for specialized widgets using <a href="qabstractscrollarea.html">QAbstractScrollArea</a>; for example, if you decide to subclass <a href="qabstractitemview.html">QAbstractItemView</a>. For most other situations where a slider control is used to obtain a value within a given range, the <a href="qslider.html">QSlider</a> class may be more appropriate for your needs.</p>
225
 
<table class="generic">
226
 
<tr class="odd topAlign"><td ><p><p class="centerAlign"><img src="images/qscrollbar-picture.png" /></p></p></td><td ><p>Scroll bars typically include four separate controls: a slider, scroll arrows, and a page control.<ul>
227
 
<li>a. The slider provides a way to quickly go to any part of the document, but does not support accurate navigation within large documents.</li>
228
 
<li>b. The scroll arrows are push buttons which can be used to accurately navigate to a particular place in a document. For a vertical scroll bar connected to a text editor, these typically move the current position one &quot;line&quot; up or down, and adjust the position of the slider by a small amount. In editors and list boxes a &quot;line&quot; might mean one line of text; in an image viewer it might mean 20 pixels.</li>
229
 
<li>c. The page control is the area over which the slider is dragged (the scroll bar's background). Clicking here moves the scroll bar towards the click by one &quot;page&quot;. This value is usually the same as the length of the slider.</li>
230
 
</ul>
231
 
</p></td></tr>
232
 
</table>
233
 
<p>Each scroll bar has a value that indicates how far the slider is from the start of the scroll bar; this is obtained with <a href="qabstractslider.html#value-prop">value</a>() and set with <a href="qabstractslider.html#value-prop">setValue</a>(). This value always lies within the range of values defined for the scroll bar, from <a href="qabstractslider.html#minimum-prop">minimum()</a> to <a href="qabstractslider.html#minimum-prop">maximum()</a> inclusive. The range of acceptable values can be set with <a href="qabstractslider.html#minimum-prop">setMinimum</a>() and <a href="qabstractslider.html#maximum-prop">setMaximum</a>(). At the minimum value, the top edge of the slider (for a vertical scroll bar) or left edge (for a horizontal scroll bar) will be at the top (or left) end of the scroll bar. At the maximum value, the bottom (or right) edge of the slider will be at the bottom (or right) end of the scroll bar.</p>
234
 
<p>The length of the slider is usually related to the value of the page step, and typically represents the proportion of the document area shown in a scrolling view. The page step is the amount that the value changes by when the user presses the <b>Page Up</b> and <b>Page Down</b> keys, and is set with <a href="qabstractslider.html#pageStep-prop">setPageStep</a>(). Smaller changes to the value defined by the line step are made using the cursor keys, and this quantity is set with <a href="qabstractslider.html#singleStep-prop">setSingleStep()</a>.</p>
235
 
<p>Note that the range of values used is independent of the actual size of the scroll bar widget. You do not need to take this into account when you choose values for the range and the page step.</p>
236
 
<p>The range of values specified for the scroll bar are often determined differently to those for a <a href="qslider.html">QSlider</a> because the length of the slider needs to be taken into account. If we have a document with 100 lines, and we can only show 20 lines in a widget, we may wish to construct a scroll bar with a page step of 20, a minimum value of 0, and a maximum value of 80. This would give us a scroll bar with five &quot;pages&quot;.</p>
237
 
<table class="generic">
238
 
<tr class="odd topAlign"><td ><p><img src="images/qscrollbar-values.png" /></p></td><td ><p>The relationship between a document length, the range of values used in a scroll bar, and the page step is simple in many common situations. The scroll bar's range of values is determined by subtracting a chosen page step from some value representing the length of the document. In such cases, the following equation is useful:<p><i>document length</i> = <a href="qabstractslider.html#maximum-prop">maximum</a>() - <a href="qabstractslider.html#minimum-prop">minimum</a>() + <a href="qabstractslider.html#pageStep-prop">pageStep</a>().</p>
239
 
</p></td></tr>
240
 
</table>
241
 
<p>QScrollBar only provides integer ranges. Note that although QScrollBar handles very large numbers, scroll bars on current screens cannot usefully represent ranges above about 100,000 pixels. Beyond that, it becomes difficult for the user to control the slider using either the keyboard or the mouse, and the scroll arrows will have limited use.</p>
242
 
<p>ScrollBar inherits a comprehensive set of signals from <a href="qabstractslider.html">QAbstractSlider</a>:</p>
243
 
<ul>
244
 
<li><a href="qabstractslider.html#valueChanged">valueChanged()</a> is emitted when the scroll bar's value has changed. The tracking() determines whether this signal is emitted during user interaction.</li>
245
 
<li><a href="qabstractslider.html#rangeChanged">rangeChanged()</a> is emitted when the scroll bar's range of values has changed.</li>
246
 
<li><a href="qabstractslider.html#sliderPressed">sliderPressed()</a> is emitted when the user starts to drag the slider.</li>
247
 
<li><a href="qabstractslider.html#sliderMoved">sliderMoved()</a> is emitted when the user drags the slider.</li>
248
 
<li><a href="qabstractslider.html#sliderReleased">sliderReleased()</a> is emitted when the user releases the slider.</li>
249
 
<li><a href="qabstractslider.html#actionTriggered">actionTriggered()</a> is emitted when the scroll bar is changed by user interaction or via the <a href="qabstractslider.html#triggerAction">triggerAction()</a> function.</li>
250
 
</ul>
251
 
<p>A scroll bar can be controlled by the keyboard, but it has a default <a href="qwidget.html#focusPolicy-prop">focusPolicy</a>() of <a href="qt.html#FocusPolicy-enum">Qt::NoFocus</a>. Use <a href="qwidget.html#focusPolicy-prop">setFocusPolicy</a>() to enable keyboard interaction with the scroll bar:</p>
252
 
<ul>
253
 
<li>Left/Right move a horizontal scroll bar by one single step.</li>
254
 
<li>Up/Down move a vertical scroll bar by one single step.</li>
255
 
<li>PageUp moves up one page.</li>
256
 
<li>PageDown moves down one page.</li>
257
 
<li>Home moves to the start (mininum).</li>
258
 
<li>End moves to the end (maximum).</li>
259
 
</ul>
260
 
<p>The slider itself can be controlled by using the <a href="qabstractslider.html#triggerAction">triggerAction()</a> function to simulate user interaction with the scroll bar controls. This is useful if you have many different widgets that use a common range of values.</p>
261
 
<p>Most GUI styles use the <a href="qabstractslider.html#pageStep-prop">pageStep</a>() value to calculate the size of the slider.</p>
262
 
<table class="generic">
263
 
 <tr class="odd topAlign"><td ><p><img src="images/macintosh-horizontalscrollbar.png" alt="Screenshot of a Macintosh style scroll bar" /></p></td><td ><p>A scroll bar shown in the <a href="gallery-macintosh.html">Macintosh widget style</a>.</p></td></tr>
264
 
<tr class="even topAlign"><td ><p><img src="images/windowsxp-horizontalscrollbar.png" alt="Screenshot of a Windows XP style scroll bar" /></p></td><td ><p>A scroll bar shown in the <a href="gallery-windowsxp.html">Windows XP widget style</a>.</p></td></tr>
265
 
<tr class="odd topAlign"><td ><p><img src="images/plastique-horizontalscrollbar.png" alt="Screenshot of a Plastique style scroll bar" /></p></td><td ><p>A scroll bar shown in the <a href="gallery-plastique.html">Plastique widget style</a>.</p></td></tr>
266
 
</table>
267
 
</div>
268
 
<p>See also <a href="qscrollarea.html">QScrollArea</a>, <a href="qslider.html">QSlider</a>, <a href="qdial.html">QDial</a>, <a href="qspinbox.html">QSpinBox</a>, <a href="guibooks.html#fowler">GUI Design Handbook: Scroll Bar</a>, and <a href="widgets-sliders.html">Sliders Example</a>.</p>
269
 
<!-- @@@QScrollBar -->
270
 
<div class="func">
271
 
<h2>Member Function Documentation</h2>
272
 
<!-- $$$QScrollBar[overload1]$$$QScrollBarQWidget* -->
273
 
<h3 class="fn"><a name="QScrollBar"></a>QScrollBar::QScrollBar ( <a href="qwidget.html">QWidget</a> * <i>parent</i> = 0 )</h3>
274
 
<p>Constructs a vertical scroll bar.</p>
275
 
<p>The <i>parent</i> arguments is sent to the <a href="qwidget.html">QWidget</a> constructor.</p>
276
 
<p>The <a href="qabstractslider.html#minimum-prop">minimum</a> defaults to 0, the <a href="qabstractslider.html#maximum-prop">maximum</a> to 99, with a <a href="qabstractslider.html#singleStep-prop">singleStep</a> size of 1 and a <a href="qabstractslider.html#pageStep-prop">pageStep</a> size of 10, and an initial <a href="qabstractslider.html#value-prop">value</a> of 0.</p>
277
 
<!-- @@@QScrollBar -->
278
 
<!-- $$$QScrollBar$$$QScrollBarQt::OrientationQWidget* -->
279
 
<h3 class="fn"><a name="QScrollBar-2"></a>QScrollBar::QScrollBar ( <a href="qt.html#Orientation-enum">Qt::Orientation</a> <i>orientation</i>, <a href="qwidget.html">QWidget</a> * <i>parent</i> = 0 )</h3>
280
 
<p>Constructs a scroll bar with the given <i>orientation</i>.</p>
281
 
<p>The <i>parent</i> argument is passed to the <a href="qwidget.html">QWidget</a> constructor.</p>
282
 
<p>The <a href="qabstractslider.html#minimum-prop">minimum</a> defaults to 0, the <a href="qabstractslider.html#maximum-prop">maximum</a> to 99, with a <a href="qabstractslider.html#singleStep-prop">singleStep</a> size of 1 and a <a href="qabstractslider.html#pageStep-prop">pageStep</a> size of 10, and an initial <a href="qabstractslider.html#value-prop">value</a> of 0.</p>
283
 
<!-- @@@QScrollBar -->
284
 
<!-- $$$~QScrollBar[overload1]$$$~QScrollBar -->
285
 
<h3 class="fn"><a name="dtor.QScrollBar"></a>QScrollBar::~QScrollBar ()</h3>
286
 
<p>Destroys the scroll bar.</p>
287
 
<!-- @@@~QScrollBar -->
288
 
<!-- $$$contextMenuEvent[overload1]$$$contextMenuEventQContextMenuEvent* -->
289
 
<h3 class="fn"><a name="contextMenuEvent"></a>void QScrollBar::contextMenuEvent ( <a href="qcontextmenuevent.html">QContextMenuEvent</a> * <i>event</i> )<tt> [virtual protected]</tt></h3>
290
 
<p>Reimplemented from <a href="qwidget.html#contextMenuEvent">QWidget::contextMenuEvent</a>().</p>
291
 
<!-- @@@contextMenuEvent -->
292
 
<!-- $$$event[overload1]$$$eventQEvent* -->
293
 
<h3 class="fn"><a name="event"></a>bool QScrollBar::event ( <a href="qevent.html">QEvent</a> * <i>event</i> )<tt> [virtual]</tt></h3>
294
 
<p>Reimplemented from <a href="qobject.html#event">QObject::event</a>().</p>
295
 
<!-- @@@event -->
296
 
<!-- $$$hideEvent[overload1]$$$hideEventQHideEvent* -->
297
 
<h3 class="fn"><a name="hideEvent"></a>void QScrollBar::hideEvent ( <a href="qhideevent.html">QHideEvent</a> * )<tt> [virtual protected]</tt></h3>
298
 
<p>Reimplemented from <a href="qwidget.html#hideEvent">QWidget::hideEvent</a>().</p>
299
 
<!-- @@@hideEvent -->
300
 
<!-- $$$initStyleOption[overload1]$$$initStyleOptionQStyleOptionSlider* -->
301
 
<h3 class="fn"><a name="initStyleOption"></a>void QScrollBar::initStyleOption ( <a href="qstyleoptionslider.html">QStyleOptionSlider</a> * <i>option</i> ) const<tt> [protected]</tt></h3>
302
 
<p>Initialize <i>option</i> with the values from this <a href="qscrollbar.html">QScrollBar</a>. This method is useful for subclasses when they need a <a href="qstyleoptionslider.html">QStyleOptionSlider</a>, but don't want to fill in all the information themselves.</p>
303
 
<p>See also <a href="qstyleoption.html#initFrom">QStyleOption::initFrom</a>().</p>
304
 
<!-- @@@initStyleOption -->
305
 
<!-- $$$mouseMoveEvent[overload1]$$$mouseMoveEventQMouseEvent* -->
306
 
<h3 class="fn"><a name="mouseMoveEvent"></a>void QScrollBar::mouseMoveEvent ( <a href="qmouseevent.html">QMouseEvent</a> * <i>e</i> )<tt> [virtual protected]</tt></h3>
307
 
<p>Reimplemented from <a href="qwidget.html#mouseMoveEvent">QWidget::mouseMoveEvent</a>().</p>
308
 
<!-- @@@mouseMoveEvent -->
309
 
<!-- $$$mousePressEvent[overload1]$$$mousePressEventQMouseEvent* -->
310
 
<h3 class="fn"><a name="mousePressEvent"></a>void QScrollBar::mousePressEvent ( <a href="qmouseevent.html">QMouseEvent</a> * <i>e</i> )<tt> [virtual protected]</tt></h3>
311
 
<p>Reimplemented from <a href="qwidget.html#mousePressEvent">QWidget::mousePressEvent</a>().</p>
312
 
<!-- @@@mousePressEvent -->
313
 
<!-- $$$mouseReleaseEvent[overload1]$$$mouseReleaseEventQMouseEvent* -->
314
 
<h3 class="fn"><a name="mouseReleaseEvent"></a>void QScrollBar::mouseReleaseEvent ( <a href="qmouseevent.html">QMouseEvent</a> * <i>e</i> )<tt> [virtual protected]</tt></h3>
315
 
<p>Reimplemented from <a href="qwidget.html#mouseReleaseEvent">QWidget::mouseReleaseEvent</a>().</p>
316
 
<!-- @@@mouseReleaseEvent -->
317
 
<!-- $$$paintEvent[overload1]$$$paintEventQPaintEvent* -->
318
 
<h3 class="fn"><a name="paintEvent"></a>void QScrollBar::paintEvent ( <a href="qpaintevent.html">QPaintEvent</a> * )<tt> [virtual protected]</tt></h3>
319
 
<p>Reimplemented from <a href="qwidget.html#paintEvent">QWidget::paintEvent</a>().</p>
320
 
<!-- @@@paintEvent -->
321
 
<!-- $$$sizeHint[overload1]$$$sizeHint -->
322
 
<h3 class="fn"><a name="sizeHint"></a><a href="qsize.html">QSize</a> QScrollBar::sizeHint () const<tt> [virtual]</tt></h3>
323
 
<p>Reimplemented from <a href="qwidget.html#sizeHint-prop">QWidget::sizeHint</a>().</p>
324
 
<!-- @@@sizeHint -->
325
 
<!-- $$$sliderChange[overload1]$$$sliderChangeSliderChange -->
326
 
<h3 class="fn"><a name="sliderChange"></a>void QScrollBar::sliderChange ( <a href="qabstractslider.html#SliderChange-enum">SliderChange</a> <i>change</i> )<tt> [virtual protected]</tt></h3>
327
 
<p>Reimplemented from <a href="qabstractslider.html#sliderChange">QAbstractSlider::sliderChange</a>().</p>
328
 
<!-- @@@sliderChange -->
329
 
</div>
330
 
        <div class="feedback t_button">
331
 
          [+] Documentation Feedback</div>
332
 
      </div>
333
 
    </div>
334
 
    </div> 
335
 
    <div class="ft">
336
 
      <span></span>
337
 
    </div>
338
 
  </div> 
339
 
  <div class="footer">
340
 
    <p>
341
 
      <acronym title="Copyright">&copy;</acronym> 2008-2010 Nokia Corporation and/or its
342
 
      subsidiaries. Nokia, Qt and their respective logos are trademarks of Nokia Corporation 
343
 
      in Finland and/or other countries worldwide.</p>
344
 
    <p>
345
 
      All other trademarks are property of their respective owners. <a title="Privacy Policy"
346
 
        href="http://qt.nokia.com/about/privacy-policy">Privacy Policy</a></p>
347
 
    <br />
348
 
    <p>
349
 
      Licensees holding valid Qt Commercial licenses may use this document in accordance with the      Qt Commercial License Agreement provided with the Software or, alternatively, in accordance      with the terms contained in a written agreement between you and Nokia.</p>
350
 
    <p>
351
 
      Alternatively, this document may be used under the terms of the <a href="http://www.gnu.org/licenses/fdl.html">GNU
352
 
      Free Documentation License version 1.3</a>
353
 
      as published by the Free Software Foundation.</p>
354
 
  </div>
355
 
  <div id="feedbackBox">
356
 
      <div id="feedcloseX" class="feedclose t_button">X</div>
357
 
    <form id="feedform" action="http://doc.qt.nokia.com/docFeedbck/feedback.php" method="get">
358
 
      <p id="noteHead">Thank you for giving your feedback.</p> <p class="note">Make sure it is related to this specific page. For more general bugs and 
359
 
      requests, please use the <a href="http://bugreports.qt.nokia.com/secure/Dashboard.jspa">Qt Bug Tracker</a>.</p>
360
 
      <p><textarea id="feedbox" name="feedText" rows="5" cols="40"></textarea></p>
361
 
      <p><input id="feedsubmit" class="feedclose" type="submit" name="feedback" /></p>
362
 
    </form>
363
 
  </div>
364
 
  <div id="blurpage">
365
 
  </div>
366
 
</body>
367
 
</html>