Sophie

Sophie

distrib > Mageia > 7 > x86_64 > by-pkgid > 1dd17e0d683ef79b4bb6872bbf359d7f > files > 4650

qt4-doc-4.8.7-26.2.mga7.noarch.rpm

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en_US" lang="en_US">
<head>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!-- q3scrollview.cpp -->
  <title>Qt 4.8: Q3ScrollView Class Reference</title>
  <link rel="stylesheet" type="text/css" href="style/style.css" />
  <script src="scripts/jquery.js" type="text/javascript"></script>
  <script src="scripts/functions.js" type="text/javascript"></script>
  <link rel="stylesheet" type="text/css" href="style/superfish.css" />
  <link rel="stylesheet" type="text/css" href="style/narrow.css" />
  <!--[if IE]>
<meta name="MSSmartTagsPreventParsing" content="true">
<meta http-equiv="imagetoolbar" content="no">
<![endif]-->
<!--[if lt IE 7]>
<link rel="stylesheet" type="text/css" href="style/style_ie6.css">
<![endif]-->
<!--[if IE 7]>
<link rel="stylesheet" type="text/css" href="style/style_ie7.css">
<![endif]-->
<!--[if IE 8]>
<link rel="stylesheet" type="text/css" href="style/style_ie8.css">
<![endif]-->

<script src="scripts/superfish.js" type="text/javascript"></script>
<script src="scripts/narrow.js" type="text/javascript"></script>

</head>
<body class="" onload="CheckEmptyAndLoadList();">
 <div class="header" id="qtdocheader">
    <div class="content"> 
    <div id="nav-logo">
      <a href="index.html">Home</a></div>
    <a href="index.html" class="qtref"><span>Qt Reference Documentation</span></a>
    <div id="narrowsearch"></div>
    <div id="nav-topright">
      <ul>
        <li class="nav-topright-home"><a href="http://qt.digia.com/">Qt HOME</a></li>
        <li class="nav-topright-dev"><a href="http://qt-project.org/">DEV</a></li>
        <li class="nav-topright-doc nav-topright-doc-active"><a href="http://qt-project.org/doc/">
          DOC</a></li>
        <li class="nav-topright-blog"><a href="http://blog.qt.digia.com/">BLOG</a></li>
      </ul>
    </div>
    <div id="shortCut">
      <ul>
        <li class="shortCut-topleft-inactive"><span><a href="index.html">Qt 4.8</a></span></li>
        <li class="shortCut-topleft-active"><a href="http://qt-project.org/doc/">ALL VERSIONS        </a></li>
      </ul>
     </div>
 <ul class="sf-menu" id="narrowmenu"> 
             <li><a href="#">API Lookup</a> 
                 <ul> 
                     <li><a href="classes.html">Class index</a></li> 
           <li><a href="functions.html">Function index</a></li> 
           <li><a href="modules.html">Modules</a></li> 
           <li><a href="namespaces.html">Namespaces</a></li> 
           <li><a href="qtglobal.html">Global Declarations</a></li> 
           <li><a href="qdeclarativeelements.html">QML elements</a></li> 
             </ul> 
             </li> 
             <li><a href="#">Qt Topics</a> 
                 <ul> 
                        <li><a href="qt-basic-concepts.html">Programming with Qt</a></li>  
                        <li><a href="qtquick.html">Device UIs &amp; Qt Quick</a></li>  
                        <li><a href="qt-gui-concepts.html">UI Design with Qt</a></li>  
                        <li><a href="supported-platforms.html">Supported Platforms</a></li>  
                        <li><a href="technology-apis.html">Qt and Key Technologies</a></li>  
                        <li><a href="best-practices.html">How-To's and Best Practices</a></li>  
              </ul> 
                 </li> 
                 <li><a href="#">Examples</a> 
                     <ul> 
                       <li><a href="all-examples.html">Examples</a></li> 
                       <li><a href="tutorials.html">Tutorials</a></li> 
                       <li><a href="demos.html">Demos</a></li> 
                       <li><a href="qdeclarativeexamples.html">QML Examples</a></li> 
                </ul> 
                     </li> 
                 </ul> 
    </div>
  </div>
  <div class="wrapper">
    <div class="hd">
      <span></span>
    </div>
    <div class="bd group">
      <div class="sidebar">
        <div class="searchlabel">
          Search index:</div>
        <div class="search" id="sidebarsearch">
          <form id="qtdocsearch" action="" onsubmit="return false;">
            <fieldset>
              <input type="text" name="searchstring" id="pageType" value="" />
 <div id="resultdialog"> 
 <a href="#" id="resultclose">Close</a> 
 <p id="resultlinks" class="all"><a href="#" id="showallresults">All</a> | <a href="#" id="showapiresults">API</a> | <a href="#" id="showarticleresults">Articles</a> | <a href="#" id="showexampleresults">Examples</a></p> 
 <p id="searchcount" class="all"><span id="resultcount"></span><span id="apicount"></span><span id="articlecount"></span><span id="examplecount"></span>&nbsp;results:</p> 
 <ul id="resultlist" class="all"> 
 </ul> 
 </div> 
            </fieldset>
          </form>
        </div>
        <div class="box first bottombar" id="lookup">
          <h2 title="API Lookup"><span></span>
            API Lookup</h2>
          <div  id="list001" class="list">
          <ul id="ul001" >
              <li class="defaultLink"><a href="classes.html">Class index</a></li>
              <li class="defaultLink"><a href="functions.html">Function index</a></li>
              <li class="defaultLink"><a href="modules.html">Modules</a></li>
              <li class="defaultLink"><a href="namespaces.html">Namespaces</a></li>
              <li class="defaultLink"><a href="qtglobal.html">Global Declarations</a></li>
              <li class="defaultLink"><a href="qdeclarativeelements.html">QML elements</a></li>
            </ul> 
          </div>
        </div>
        <div class="box bottombar" id="topics">
          <h2 title="Qt Topics"><span></span>
            Qt Topics</h2>
          <div id="list002" class="list">
            <ul id="ul002" >
               <li class="defaultLink"><a href="qt-basic-concepts.html">Programming with Qt</a></li> 
               <li class="defaultLink"><a href="qtquick.html">Device UIs &amp; Qt Quick</a></li> 
               <li class="defaultLink"><a href="qt-gui-concepts.html">UI Design with Qt</a></li> 
               <li class="defaultLink"><a href="supported-platforms.html">Supported Platforms</a></li>  
               <li class="defaultLink"><a href="technology-apis.html">Qt and Key Technologies</a></li> 
               <li class="defaultLink"><a href="best-practices.html">How-To's and Best Practices</a></li> 
            </ul>  
          </div>
        </div>
        <div class="box" id="examples">
          <h2 title="Examples"><span></span>
            Examples</h2>
          <div id="list003" class="list">
        <ul id="ul003">
              <li class="defaultLink"><a href="all-examples.html">Examples</a></li>
              <li class="defaultLink"><a href="tutorials.html">Tutorials</a></li>
              <li class="defaultLink"><a href="demos.html">Demos</a></li>
              <li class="defaultLink"><a href="qdeclarativeexamples.html">QML Examples</a></li>
            </ul> 
          </div>
        </div>
      </div>
      <div class="wrap">
        <div class="toolbar">
          <div class="breadcrumb toolblock">
            <ul>
              <li class="first"><a href="index.html">Home</a></li>
              <!--  Breadcrumbs go here -->
<li><a href="modules.html">Modules</a></li>
<li>Qt3SupportLight</li>
<li>Q3ScrollView</li>
            </ul>
          </div>
          <div class="toolbuttons toolblock">
            <ul>
              <li id="smallA" class="t_button">A</li>
              <li id="medA" class="t_button active">A</li>
              <li id="bigA" class="t_button">A</li>
              <li id="print" class="t_button"><a href="javascript:this.print();">
                <span>Print</span></a></li>
            </ul>
        </div>
        </div>
        <div class="content mainContent">
<div class="toc">
<h3><a name="toc">Contents</a></h3>
<ul>
<li class="level1"><a href="#public-types">Public Types</a></li>
<li class="level1"><a href="#properties">Properties</a></li>
<li class="level1"><a href="#public-functions">Public Functions</a></li>
<li class="level1"><a href="#public-slots">Public Slots</a></li>
<li class="level1"><a href="#signals">Signals</a></li>
<li class="level1"><a href="#protected-functions">Protected Functions</a></li>
<li class="level1"><a href="#details">Detailed Description</a></li>
<li class="level2"><a href="#using-one-big-widget">Using One Big Widget</a></li>
<li class="level2"><a href="#using-a-very-big-view-with-some-widgets">Using a Very Big View with Some Widgets</a></li>
<li class="level2"><a href="#using-a-very-big-view-with-many-widgets">Using a Very Big View with Many Widgets</a></li>
<li class="level2"><a href="#details-relevant-for-all-views">Details Relevant for All Views</a></li>
</ul>
</div>
<h1 class="title">Q3ScrollView Class Reference</h1>
<!-- $$$Q3ScrollView-brief -->
<p>The Q3ScrollView widget provides a scrolling area with on-demand scroll bars. <a href="#details">More...</a></p>
<!-- @@@Q3ScrollView -->
<pre class="cpp"> <span class="preprocessor">#include &lt;Q3ScrollView&gt;</span></pre><p><b>This class is part of the Qt 3 support library.</b> It is provided to keep old source code working. We strongly advise against using it in new code. See <a href="porting4.html#qscrollview">Porting to Qt 4</a> for more information.</p>
<p><b>Inherits: </b><a href="q3frame.html">Q3Frame</a>.</p>
<p><b>Inherited by: </b><a href="q3canvasview.html">Q3CanvasView</a>, <a href="q3gridview.html">Q3GridView</a>, <a href="q3iconview.html">Q3IconView</a>, <a href="q3listbox.html">Q3ListBox</a>, <a href="q3listview.html">Q3ListView</a>, <a href="q3table.html">Q3Table</a>, and <a href="q3textedit.html">Q3TextEdit</a>.</p>
<ul>
<li><a href="q3scrollview-members.html">List of all members, including inherited members</a></li>
<li><a href="q3scrollview-obsolete.html">Obsolete members</a></li>
</ul>
<a name="public-types"></a>
<h2>Public Types</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> enum </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#ResizePolicy-enum">ResizePolicy</a></b> { Default, Manual, AutoOne, AutoOneFit }</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> enum </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#ScrollBarMode-enum">ScrollBarMode</a></b> { Auto, AlwaysOff, AlwaysOn }</td></tr>
</table>
<a name="properties"></a>
<h2>Properties</h2>
<table class="propsummary">
<tr><td class="topAlign"><ul>
<li class="fn"><b><a href="q3scrollview.html#contentsHeight-prop">contentsHeight</a></b> : const int</li>
<li class="fn"><b><a href="q3scrollview.html#contentsWidth-prop">contentsWidth</a></b> : const int</li>
<li class="fn"><b><a href="q3scrollview.html#contentsX-prop">contentsX</a></b> : const int</li>
<li class="fn"><b><a href="q3scrollview.html#contentsY-prop">contentsY</a></b> : const int</li>
<li class="fn"><b><a href="q3scrollview.html#dragAutoScroll-prop">dragAutoScroll</a></b> : bool</li>
</ul></td><td class="topAlign"><ul>
<li class="fn"><b><a href="q3scrollview.html#hScrollBarMode-prop">hScrollBarMode</a></b> : ScrollBarMode</li>
<li class="fn"><b><a href="q3scrollview.html#resizePolicy-prop">resizePolicy</a></b> : ResizePolicy</li>
<li class="fn"><b><a href="q3scrollview.html#vScrollBarMode-prop">vScrollBarMode</a></b> : ScrollBarMode</li>
<li class="fn"><b><a href="q3scrollview.html#visibleHeight-prop">visibleHeight</a></b> : const int</li>
<li class="fn"><b><a href="q3scrollview.html#visibleWidth-prop">visibleWidth</a></b> : const int</li>
</ul>
</td></tr>
</table>
<ul>
<li class="fn">2 properties inherited from <a href="q3frame.html#properties">Q3Frame</a></li>
<li class="fn">6 properties inherited from <a href="qframe.html#properties">QFrame</a></li>
<li class="fn">58 properties inherited from <a href="qwidget.html#properties">QWidget</a></li>
<li class="fn">1 property inherited from <a href="qobject.html#properties">QObject</a></li>
</ul>
<a name="public-functions"></a>
<h2>Public Functions</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#Q3ScrollView">Q3ScrollView</a></b> ( QWidget * <i>parent</i> = 0, const char * <i>name</i> = 0, Qt::WindowFlags <i>f</i> = 0 )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#dtor.Q3ScrollView">~Q3ScrollView</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#addChild">addChild</a></b> ( QWidget * <i>child</i>, int <i>x</i> = 0, int <i>y</i> = 0 )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#bottomMargin">bottomMargin</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#childX">childX</a></b> ( QWidget * <i>child</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#childY">childY</a></b> ( QWidget * <i>child</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QWidget * </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#clipper">clipper</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsHeight-prop">contentsHeight</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsToViewport">contentsToViewport</a></b> ( int <i>x</i>, int <i>y</i>, int &amp; <i>vx</i>, int &amp; <i>vy</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QPoint </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsToViewport-2">contentsToViewport</a></b> ( const QPoint &amp; <i>p</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsWidth-prop">contentsWidth</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsX-prop">contentsX</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsY-prop">contentsY</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QWidget * </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#cornerWidget">cornerWidget</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#dragAutoScroll-prop">dragAutoScroll</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#enableClipper">enableClipper</a></b> ( bool <i>y</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> ScrollBarMode </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#hScrollBarMode-prop">hScrollBarMode</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#hasStaticBackground">hasStaticBackground</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QScrollBar * </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#horizontalScrollBar">horizontalScrollBar</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#isHorizontalSliderPressed">isHorizontalSliderPressed</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#isVerticalSliderPressed">isVerticalSliderPressed</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#leftMargin">leftMargin</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#moveChild">moveChild</a></b> ( QWidget * <i>child</i>, int <i>x</i>, int <i>y</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#removeChild">removeChild</a></b> ( QWidget * <i>child</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#repaintContents">repaintContents</a></b> ( int <i>x</i>, int <i>y</i>, int <i>w</i>, int <i>h</i>, bool <i>erase</i> = true )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#repaintContents-2">repaintContents</a></b> ( const QRect &amp; <i>r</i>, bool <i>erase</i> = true )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#repaintContents-3">repaintContents</a></b> ( bool <i>erase</i> = true )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> ResizePolicy </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#resizePolicy-prop">resizePolicy</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#rightMargin">rightMargin</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#setCornerWidget">setCornerWidget</a></b> ( QWidget * <i>corner</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#dragAutoScroll-prop">setDragAutoScroll</a></b> ( bool <i>b</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#hScrollBarMode-prop">setHScrollBarMode</a></b> ( ScrollBarMode )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#setMargins">setMargins</a></b> ( int <i>left</i>, int <i>top</i>, int <i>right</i>, int <i>bottom</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#resizePolicy-prop">setResizePolicy</a></b> ( ResizePolicy )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#setStaticBackground">setStaticBackground</a></b> ( bool <i>y</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#vScrollBarMode-prop">setVScrollBarMode</a></b> ( ScrollBarMode )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#topMargin">topMargin</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#updateContents">updateContents</a></b> ( int <i>x</i>, int <i>y</i>, int <i>w</i>, int <i>h</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#updateContents-2">updateContents</a></b> ( const QRect &amp; <i>r</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#updateContents-3">updateContents</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> ScrollBarMode </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#vScrollBarMode-prop">vScrollBarMode</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QScrollBar * </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#verticalScrollBar">verticalScrollBar</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QWidget * </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#viewport">viewport</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QSize </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#viewportSize">viewportSize</a></b> ( int <i>x</i>, int <i>y</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#viewportToContents">viewportToContents</a></b> ( int <i>vx</i>, int <i>vy</i>, int &amp; <i>x</i>, int &amp; <i>y</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QPoint </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#viewportToContents-2">viewportToContents</a></b> ( const QPoint &amp; <i>vp</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#visibleHeight-prop">visibleHeight</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#visibleWidth-prop">visibleWidth</a></b> () const</td></tr>
</table>
<a name="reimplemented-public-functions"></a>
<h2>Reimplemented Public Functions</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> virtual QSize </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#minimumSizeHint">minimumSizeHint</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#setVisible">setVisible</a></b> ( bool <i>visible</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual QSize </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#sizeHint">sizeHint</a></b> () const</td></tr>
</table>
<ul>
<li class="fn">4 public functions inherited from <a href="q3frame.html#public-functions">Q3Frame</a></li>
<li class="fn">14 public functions inherited from <a href="qframe.html#public-functions">QFrame</a></li>
<li class="fn">221 public functions inherited from <a href="qwidget.html#public-functions">QWidget</a></li>
<li class="fn">29 public functions inherited from <a href="qobject.html#public-functions">QObject</a></li>
<li class="fn">13 public functions inherited from <a href="qpaintdevice.html#public-functions">QPaintDevice</a></li>
</ul>
<a name="public-slots"></a>
<h2>Public Slots</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#center">center</a></b> ( int <i>x</i>, int <i>y</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#center-2">center</a></b> ( int <i>x</i>, int <i>y</i>, float <i>xmargin</i>, float <i>ymargin</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#ensureVisible">ensureVisible</a></b> ( int <i>x</i>, int <i>y</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#ensureVisible-2">ensureVisible</a></b> ( int <i>x</i>, int <i>y</i>, int <i>xmargin</i>, int <i>ymargin</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#resizeContents">resizeContents</a></b> ( int <i>w</i>, int <i>h</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#scrollBy">scrollBy</a></b> ( int <i>dx</i>, int <i>dy</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#setContentsPos">setContentsPos</a></b> ( int <i>x</i>, int <i>y</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#updateScrollBars">updateScrollBars</a></b> ()</td></tr>
</table>
<ul>
<li class="fn">19 public slots inherited from <a href="qwidget.html#public-slots">QWidget</a></li>
<li class="fn">1 public slot inherited from <a href="qobject.html#public-slots">QObject</a></li>
</ul>
<a name="signals"></a>
<h2>Signals</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsMoving">contentsMoving</a></b> ( int <i>x</i>, int <i>y</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#horizontalSliderPressed">horizontalSliderPressed</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#horizontalSliderReleased">horizontalSliderReleased</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#verticalSliderPressed">verticalSliderPressed</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#verticalSliderReleased">verticalSliderReleased</a></b> ()</td></tr>
</table>
<ul>
<li class="fn">1 signal inherited from <a href="qwidget.html#signals">QWidget</a></li>
<li class="fn">1 signal inherited from <a href="qobject.html#signals">QObject</a></li>
</ul>
<a name="protected-functions"></a>
<h2>Protected Functions</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsContextMenuEvent">contentsContextMenuEvent</a></b> ( QContextMenuEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsDragEnterEvent">contentsDragEnterEvent</a></b> ( QDragEnterEvent * <i>event</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsDragLeaveEvent">contentsDragLeaveEvent</a></b> ( QDragLeaveEvent * <i>event</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsDragMoveEvent">contentsDragMoveEvent</a></b> ( QDragMoveEvent * <i>event</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsDropEvent">contentsDropEvent</a></b> ( QDropEvent * <i>event</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsMouseDoubleClickEvent">contentsMouseDoubleClickEvent</a></b> ( QMouseEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsMouseMoveEvent">contentsMouseMoveEvent</a></b> ( QMouseEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsMousePressEvent">contentsMousePressEvent</a></b> ( QMouseEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsMouseReleaseEvent">contentsMouseReleaseEvent</a></b> ( QMouseEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contentsWheelEvent">contentsWheelEvent</a></b> ( QWheelEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#drawContents">drawContents</a></b> ( QPainter * <i>p</i>, int <i>clipx</i>, int <i>clipy</i>, int <i>clipw</i>, int <i>cliph</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#drawContentsOffset">drawContentsOffset</a></b> ( QPainter * <i>p</i>, int <i>offsetx</i>, int <i>offsety</i>, int <i>clipx</i>, int <i>clipy</i>, int <i>clipw</i>, int <i>cliph</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#setHBarGeometry">setHBarGeometry</a></b> ( QScrollBar &amp; <i>hbar</i>, int <i>x</i>, int <i>y</i>, int <i>w</i>, int <i>h</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#setVBarGeometry">setVBarGeometry</a></b> ( QScrollBar &amp; <i>vbar</i>, int <i>x</i>, int <i>y</i>, int <i>w</i>, int <i>h</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#viewportPaintEvent">viewportPaintEvent</a></b> ( QPaintEvent * <i>pe</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#viewportResizeEvent">viewportResizeEvent</a></b> ( QResizeEvent * <i>event</i> )</td></tr>
</table>
<a name="reimplemented-protected-functions"></a>
<h2>Reimplemented Protected Functions</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#contextMenuEvent">contextMenuEvent</a></b> ( QContextMenuEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual bool </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#eventFilter">eventFilter</a></b> ( QObject * <i>obj</i>, QEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual bool </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#focusNextPrevChild">focusNextPrevChild</a></b> ( bool <i>next</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#frameChanged">frameChanged</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#mouseDoubleClickEvent">mouseDoubleClickEvent</a></b> ( QMouseEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#mouseMoveEvent">mouseMoveEvent</a></b> ( QMouseEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#mousePressEvent">mousePressEvent</a></b> ( QMouseEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#mouseReleaseEvent">mouseReleaseEvent</a></b> ( QMouseEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#resizeEvent">resizeEvent</a></b> ( QResizeEvent * <i>event</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3scrollview.html#wheelEvent">wheelEvent</a></b> ( QWheelEvent * <i>e</i> )</td></tr>
</table>
<ul>
<li class="fn">5 protected functions inherited from <a href="q3frame.html#protected-functions">Q3Frame</a></li>
<li class="fn">3 protected functions inherited from <a href="qframe.html#protected-functions">QFrame</a></li>
<li class="fn">37 protected functions inherited from <a href="qwidget.html#protected-functions">QWidget</a></li>
<li class="fn">8 protected functions inherited from <a href="qobject.html#protected-functions">QObject</a></li>
<li class="fn">1 protected function inherited from <a href="qpaintdevice.html#protected-functions">QPaintDevice</a></li>
</ul>
<h3>Additional Inherited Members</h3>
<ul>
<li class="fn">4 static public members inherited from <a href="qwidget.html#static-public-members">QWidget</a></li>
<li class="fn">7 static public members inherited from <a href="qobject.html#static-public-members">QObject</a></li>
<li class="fn">1 protected slot inherited from <a href="qwidget.html#protected-slots">QWidget</a></li>
</ul>
<a name="details"></a>
<!-- $$$Q3ScrollView-description -->
<div class="descr">
<h2>Detailed Description</h2>
<p>The Q3ScrollView widget provides a scrolling area with on-demand scroll bars.</p>
<p>The Q3ScrollView is a large canvas - potentially larger than the coordinate system normally supported by the underlying window system. This is important because it is quite easy to go beyond these limitations (e.g&#x2e; many web pages are more than 32000 pixels high). Additionally, the Q3ScrollView can have QWidgets positioned on it that scroll around with the drawn content. These sub-widgets can also have positions outside the normal coordinate range (but they are still limited in size).</p>
<p>To provide content for the widget, inherit from Q3ScrollView, reimplement <a href="q3scrollview.html#drawContents">drawContents</a>() and use <a href="q3scrollview.html#resizeContents">resizeContents</a>() to set the size of the viewed area. Use <a href="q3scrollview.html#addChild">addChild</a>() and <a href="q3scrollview.html#moveChild">moveChild</a>() to position widgets on the view.</p>
<p>To use Q3ScrollView effectively it is important to understand its widget structure in the three styles of use: a single large child widget, a large panning area with some widgets and a large panning area with many widgets.</p>
<a name="using-one-big-widget"></a>
<h3>Using One Big Widget</h3>
<p class="centerAlign"><img src="images/qscrollview-vp2.png" alt="" /></p><p>The first, simplest usage of Q3ScrollView (depicted above), is appropriate for scrolling areas that are never more than about 4000 pixels in either dimension (this is about the maximum reliable size on X11 servers). In this usage, you just make one large child in the Q3ScrollView. The child should be a child of the <a href="q3scrollview.html#viewport">viewport</a>() of the scrollview and be added with <a href="q3scrollview.html#addChild">addChild</a>():</p>
<pre class="cpp"> <span class="type">Q3ScrollView</span><span class="operator">*</span> sv <span class="operator">=</span> <span class="keyword">new</span> <span class="type">Q3ScrollView</span>(<span class="operator">.</span><span class="operator">.</span><span class="operator">.</span>);
 <span class="type"><a href="qwidget.html">QWidget</a></span> <span class="operator">*</span>widget <span class="operator">=</span> <span class="keyword">new</span> <span class="type"><a href="qwidget.html">QWidget</a></span>(sv<span class="operator">-</span><span class="operator">&gt;</span>viewport());
 <span class="type"><a href="qvboxlayout.html">QVBoxLayout</a></span> <span class="operator">*</span>layout <span class="operator">=</span> <span class="keyword">new</span> <span class="type"><a href="qvboxlayout.html">QVBoxLayout</a></span>(widget);
 <a href="q3scrollview.html#addChild">addChild</a>(widget);</pre>
<p>You can go on to add arbitrary child widgets to the single child in the scrollview as you would with any widget:</p>
<pre class="cpp"> <span class="type"><a href="qlabel.html">QLabel</a></span><span class="operator">*</span> child1 <span class="operator">=</span> <span class="keyword">new</span> <span class="type"><a href="qlabel.html">QLabel</a></span>(<span class="string">&quot;CHILD&quot;</span><span class="operator">,</span> widget);
 <span class="type"><a href="qlabel.html">QLabel</a></span><span class="operator">*</span> child2 <span class="operator">=</span> <span class="keyword">new</span> <span class="type"><a href="qlabel.html">QLabel</a></span>(<span class="string">&quot;CHILD&quot;</span><span class="operator">,</span> widget);
 <span class="type"><a href="qlabel.html">QLabel</a></span><span class="operator">*</span> child3 <span class="operator">=</span> <span class="keyword">new</span> <span class="type"><a href="qlabel.html">QLabel</a></span>(<span class="string">&quot;CHILD&quot;</span><span class="operator">,</span> widget);
 layout<span class="operator">-</span><span class="operator">&gt;</span>addWidget(child1);
 layout<span class="operator">-</span><span class="operator">&gt;</span>addWidget(child2);
 layout<span class="operator">-</span><span class="operator">&gt;</span>addWidget(child3);
 <span class="operator">.</span><span class="operator">.</span><span class="operator">.</span></pre>
<p>Here the Q3ScrollView has four children: the <a href="q3scrollview.html#viewport">viewport</a>(), the <a href="q3scrollview.html#verticalScrollBar">verticalScrollBar</a>(), the <a href="q3scrollview.html#horizontalScrollBar">horizontalScrollBar</a>() and a small <a href="q3scrollview.html#cornerWidget">cornerWidget</a>(). The <a href="q3scrollview.html#viewport">viewport</a>() has one child: the <a href="qwidget.html">QWidget</a>. The <a href="qwidget.html">QWidget</a> has the three <a href="qlabel.html">QLabel</a> objects as child widgets. When the view is scrolled, the <a href="qwidget.html">QWidget</a> is moved; its children move with it as child widgets normally do.</p>
<a name="using-a-very-big-view-with-some-widgets"></a>
<h3>Using a Very Big View with Some Widgets</h3>
<p class="centerAlign"><img src="images/qscrollview-vp.png" alt="" /></p><p>The second usage of Q3ScrollView (depicted above) is appropriate when few, if any, widgets are on a very large scrolling area that is potentially larger than 4000 pixels in either dimension. In this usage you call <a href="q3scrollview.html#resizeContents">resizeContents</a>() to set the size of the area and reimplement <a href="q3scrollview.html#drawContents">drawContents</a>() to paint the contents. You may also add some widgets by making them children of the <a href="q3scrollview.html#viewport">viewport</a>() and adding them with <a href="q3scrollview.html#addChild">addChild</a>() (this is the same as the process for the single large widget in the previous example):</p>
<pre class="cpp"> <span class="type">Q3ScrollView</span><span class="operator">*</span> sv <span class="operator">=</span> <span class="keyword">new</span> <span class="type">Q3ScrollView</span>(<span class="operator">.</span><span class="operator">.</span><span class="operator">.</span>);
 <span class="type"><a href="qlabel.html">QLabel</a></span><span class="operator">*</span> child1 <span class="operator">=</span> <span class="keyword">new</span> <span class="type"><a href="qlabel.html">QLabel</a></span>(<span class="string">&quot;CHILD&quot;</span><span class="operator">,</span> sv<span class="operator">-</span><span class="operator">&gt;</span>viewport());
 sv<span class="operator">-</span><span class="operator">&gt;</span><a href="q3scrollview.html#addChild">addChild</a>(child1);
 <span class="type"><a href="qlabel.html">QLabel</a></span><span class="operator">*</span> child2 <span class="operator">=</span> <span class="keyword">new</span> <span class="type"><a href="qlabel.html">QLabel</a></span>(<span class="string">&quot;CHILD&quot;</span><span class="operator">,</span> sv<span class="operator">-</span><span class="operator">&gt;</span>viewport());
 sv<span class="operator">-</span><span class="operator">&gt;</span><a href="q3scrollview.html#addChild">addChild</a>(child2);
 <span class="type"><a href="qlabel.html">QLabel</a></span><span class="operator">*</span> child3 <span class="operator">=</span> <span class="keyword">new</span> <span class="type"><a href="qlabel.html">QLabel</a></span>(<span class="string">&quot;CHILD&quot;</span><span class="operator">,</span> sv<span class="operator">-</span><span class="operator">&gt;</span>viewport());
 sv<span class="operator">-</span><span class="operator">&gt;</span><a href="q3scrollview.html#addChild">addChild</a>(child3);</pre>
<p>Here, the Q3ScrollView has the same four children: the <a href="q3scrollview.html#viewport">viewport</a>(), the <a href="q3scrollview.html#verticalScrollBar">verticalScrollBar</a>(), the <a href="q3scrollview.html#horizontalScrollBar">horizontalScrollBar</a>() and a small <a href="q3scrollview.html#cornerWidget">cornerWidget</a>(). The <a href="q3scrollview.html#viewport">viewport</a>() has the three <a href="qlabel.html">QLabel</a> objects as child widgets. When the view is scrolled, the scrollview moves the child widgets individually.</p>
<a name="using-a-very-big-view-with-many-widgets"></a>
<h3>Using a Very Big View with Many Widgets</h3>
<p class="centerAlign"><img src="images/qscrollview-cl.png" alt="" /></p><p>The final usage of Q3ScrollView (depicted above) is appropriate when many widgets are on a very large scrolling area that is potentially larger than 4000 pixels in either dimension. In this usage you call <a href="q3scrollview.html#resizeContents">resizeContents</a>() to set the size of the area and reimplement <a href="q3scrollview.html#drawContents">drawContents</a>() to paint the contents. You then call enableClipper(true) and add widgets, again by making them children of the <a href="q3scrollview.html#viewport">viewport</a>(), and adding them with <a href="q3scrollview.html#addChild">addChild</a>():</p>
<pre class="cpp"> <span class="type">Q3ScrollView</span><span class="operator">*</span> sv <span class="operator">=</span> <span class="keyword">new</span> <span class="type">Q3ScrollView</span>(<span class="operator">.</span><span class="operator">.</span><span class="operator">.</span>);
 sv<span class="operator">-</span><span class="operator">&gt;</span><a href="q3scrollview.html#enableClipper">enableClipper</a>(<span class="keyword">true</span>);
 <span class="type"><a href="qlabel.html">QLabel</a></span><span class="operator">*</span> child1 <span class="operator">=</span> <span class="keyword">new</span> <span class="type"><a href="qlabel.html">QLabel</a></span>(<span class="string">&quot;CHILD&quot;</span><span class="operator">,</span> sv<span class="operator">-</span><span class="operator">&gt;</span>viewport());
 sv<span class="operator">-</span><span class="operator">&gt;</span><a href="q3scrollview.html#addChild">addChild</a>(child1);
 <span class="type"><a href="qlabel.html">QLabel</a></span><span class="operator">*</span> child2 <span class="operator">=</span> <span class="keyword">new</span> <span class="type"><a href="qlabel.html">QLabel</a></span>(<span class="string">&quot;CHILD&quot;</span><span class="operator">,</span> sv<span class="operator">-</span><span class="operator">&gt;</span>viewport());
 sv<span class="operator">-</span><span class="operator">&gt;</span><a href="q3scrollview.html#addChild">addChild</a>(child2);
 <span class="type"><a href="qlabel.html">QLabel</a></span><span class="operator">*</span> child3 <span class="operator">=</span> <span class="keyword">new</span> <span class="type"><a href="qlabel.html">QLabel</a></span>(<span class="string">&quot;CHILD&quot;</span><span class="operator">,</span> sv<span class="operator">-</span><span class="operator">&gt;</span>viewport());
 sv<span class="operator">-</span><span class="operator">&gt;</span><a href="q3scrollview.html#addChild">addChild</a>(child3);</pre>
<p>Here, the Q3ScrollView has four children: the <a href="q3scrollview.html#clipper">clipper</a>() (not the <a href="q3scrollview.html#viewport">viewport</a>() this time), the <a href="q3scrollview.html#verticalScrollBar">verticalScrollBar</a>(), the <a href="q3scrollview.html#horizontalScrollBar">horizontalScrollBar</a>() and a small <a href="q3scrollview.html#cornerWidget">cornerWidget</a>(). The <a href="q3scrollview.html#clipper">clipper</a>() has one child: the <a href="q3scrollview.html#viewport">viewport</a>(). The <a href="q3scrollview.html#viewport">viewport</a>() has the same three labels as child widgets. When the view is scrolled the <a href="q3scrollview.html#viewport">viewport</a>() is moved; its children move with it as child widgets normally do.</p>
<a name="allviews"></a><a name="details-relevant-for-all-views"></a>
<h3>Details Relevant for All Views</h3>
<p>Normally you will use the first or third method if you want any child widgets in the view.</p>
<p>Note that the widget you see in the scrolled area is the <a href="q3scrollview.html#viewport">viewport</a>() widget, not the Q3ScrollView itself. So to turn mouse tracking on, for example, use <a href="q3scrollview.html#viewport">viewport</a>()-&gt;setMouseTracking(true).</p>
<p>To enable drag-and-drop, you would setAcceptDrops(true) on the Q3ScrollView (because drag-and-drop events propagate to the parent). But to work out the logical position in the view, you would need to map the drop co-ordinate from being relative to the Q3ScrollView to being relative to the contents; use the function <a href="q3scrollview.html#viewportToContents">viewportToContents</a>() for this.</p>
<p>To handle mouse events on the scrolling area, subclass scrollview as you would subclass other widgets, but rather than reimplementing <a href="q3scrollview.html#mousePressEvent">mousePressEvent</a>(), reimplement <a href="q3scrollview.html#contentsMousePressEvent">contentsMousePressEvent</a>() instead. The contents specific event handlers provide translated events in the coordinate system of the scrollview. If you reimplement <a href="q3scrollview.html#mousePressEvent">mousePressEvent</a>(), you'll get called only when part of the Q3ScrollView is clicked: and the only such part is the &quot;corner&quot; (if you don't set a <a href="q3scrollview.html#cornerWidget">cornerWidget</a>()) and the frame; everything else is covered up by the viewport, clipper or scroll bars.</p>
<p>When you construct a Q3ScrollView, some of the window flags apply to the <a href="q3scrollview.html#viewport">viewport</a>() instead of being sent to the <a href="qwidget.html">QWidget</a> constructor for the Q3ScrollView.</p>
<ul>
<li>An image-manipulation widget would use <tt>WNoAutoErase|WStaticContents</tt> because the widget draws all pixels itself, and when its size increases, it only needs a paint event for the new part because the old part remains unchanged.</li>
<li>A scrolling game widget in which the background scrolls as the characters move might use <tt>WNoAutoErase</tt> (in addition to <tt>WStaticContents</tt>) so that the window system background does not flash in and out during scrolling.</li>
<li>A word processing widget might use <tt>WNoAutoErase</tt> and repaint itself line by line to get a less-flickery resizing. If the widget is in a mode in which no text justification can take place, it might use <tt>WStaticContents</tt> too, so that it would only get a repaint for the newly visible parts.</li>
</ul>
<p>Child widgets may be moved using <a href="q3scrollview.html#addChild">addChild</a>() or <a href="q3scrollview.html#moveChild">moveChild</a>(). Use <a href="q3scrollview.html#childX">childX</a>() and <a href="q3scrollview.html#childY">childY</a>() to get the position of a child widget.</p>
<p>A widget may be placed in the corner between the vertical and horizontal scroll bars with <a href="q3scrollview.html#setCornerWidget">setCornerWidget</a>(). You can get access to the scroll bars using <a href="q3scrollview.html#horizontalScrollBar">horizontalScrollBar</a>() and <a href="q3scrollview.html#verticalScrollBar">verticalScrollBar</a>(), and to the viewport with <a href="q3scrollview.html#viewport">viewport</a>(). The scroll view can be scrolled using <a href="q3scrollview.html#scrollBy">scrollBy</a>(), <a href="q3scrollview.html#ensureVisible">ensureVisible</a>(), <a href="q3scrollview.html#setContentsPos">setContentsPos</a>() or <a href="q3scrollview.html#center">center</a>().</p>
<p>The visible area is given by <a href="q3scrollview.html#visibleWidth-prop">visibleWidth</a>() and <a href="q3scrollview.html#visibleHeight-prop">visibleHeight</a>(), and the contents area by <a href="q3scrollview.html#contentsWidth-prop">contentsWidth</a>() and <a href="q3scrollview.html#contentsHeight-prop">contentsHeight</a>(). The contents may be repainted using one of the <a href="q3scrollview.html#repaintContents">repaintContents</a>() or <a href="q3scrollview.html#updateContents">updateContents</a>() functions.</p>
<p>Coordinate conversion is provided by <a href="q3scrollview.html#contentsToViewport">contentsToViewport</a>() and <a href="q3scrollview.html#viewportToContents">viewportToContents</a>().</p>
<p>The <a href="q3scrollview.html#contentsMoving">contentsMoving</a>() signal is emitted just before the contents are moved to a new position.</p>
<p><b>Warning:</b> Q3ScrollView currently does not erase the background when resized, i.e&#x2e; you must always clear the background manually in scrollview subclasses. This will change in a future version of Qt and we recommend specifying the <tt>WNoAutoErase</tt> flag explicitly.</p>
</div>
<!-- @@@Q3ScrollView -->
<div class="types">
<h2>Member Type Documentation</h2>
<!-- $$$ResizePolicy$$$Default$$$Manual$$$AutoOne$$$AutoOneFit -->
<h3 class="fn"><a name="ResizePolicy-enum"></a>enum Q3ScrollView::<span class="name">ResizePolicy</span></h3>
<p>This enum type is used to control a <a href="q3scrollview.html" class="compat">Q3ScrollView</a>'s reaction to resize events.</p>
<table class="valuelist"><tr valign="top" class="odd"><th class="tblConst">Constant</th><th class="tblval">Value</th><th class="tbldscr">Description</th></tr>
<tr><td class="topAlign"><tt>Q3ScrollView::Default</tt></td><td class="topAlign"><tt>0</tt></td><td class="topAlign">the <a href="q3scrollview.html" class="compat">Q3ScrollView</a> selects one of the other settings automatically when it has to. In this version of Qt, <a href="q3scrollview.html" class="compat">Q3ScrollView</a> changes to <tt>Manual</tt> if you resize the contents with <a href="q3scrollview.html#resizeContents">resizeContents</a>() and to <tt>AutoOne</tt> if a child is added.</td></tr>
<tr><td class="topAlign"><tt>Q3ScrollView::Manual</tt></td><td class="topAlign"><tt>1</tt></td><td class="topAlign">the contents stays the size set by <a href="q3scrollview.html#resizeContents">resizeContents</a>().</td></tr>
<tr><td class="topAlign"><tt>Q3ScrollView::AutoOne</tt></td><td class="topAlign"><tt>2</tt></td><td class="topAlign">if there is only one child widget the contents stays the size of that widget. Otherwise the behavior is undefined.</td></tr>
<tr><td class="topAlign"><tt>Q3ScrollView::AutoOneFit</tt></td><td class="topAlign"><tt>3</tt></td><td class="topAlign">if there is only one child widget the contents stays the size of that widget's <a href="q3scrollview.html#sizeHint">sizeHint</a>(). If the scrollview is resized larger than the child's <a href="q3scrollview.html#sizeHint">sizeHint</a>(), the child will be resized to fit. If there is more than one child, the behavior is undefined.</td></tr>
</table>
<!-- @@@ResizePolicy -->
<!-- $$$ScrollBarMode$$$Auto$$$AlwaysOff$$$AlwaysOn -->
<h3 class="fn"><a name="ScrollBarMode-enum"></a>enum Q3ScrollView::<span class="name">ScrollBarMode</span></h3>
<p>This enum type describes the various modes of <a href="q3scrollview.html" class="compat">Q3ScrollView</a>'s scroll bars.</p>
<table class="valuelist"><tr valign="top" class="odd"><th class="tblConst">Constant</th><th class="tblval">Value</th><th class="tbldscr">Description</th></tr>
<tr><td class="topAlign"><tt>Q3ScrollView::Auto</tt></td><td class="topAlign"><tt>0</tt></td><td class="topAlign"><a href="q3scrollview.html" class="compat">Q3ScrollView</a> shows a scroll bar when the content is too large to fit and not otherwise. This is the default.</td></tr>
<tr><td class="topAlign"><tt>Q3ScrollView::AlwaysOff</tt></td><td class="topAlign"><tt>1</tt></td><td class="topAlign"><a href="q3scrollview.html" class="compat">Q3ScrollView</a> never shows a scroll bar.</td></tr>
<tr><td class="topAlign"><tt>Q3ScrollView::AlwaysOn</tt></td><td class="topAlign"><tt>2</tt></td><td class="topAlign"><a href="q3scrollview.html" class="compat">Q3ScrollView</a> always shows a scroll bar.</td></tr>
</table>
<p>(The modes for the horizontal and vertical scroll bars are independent.)</p>
<!-- @@@ScrollBarMode -->
</div>
<div class="prop">
<h2>Property Documentation</h2>
<!-- $$$contentsHeight-prop$$$contentsHeight -->
<h3 class="fn"><a name="contentsHeight-prop"></a><span class="name">contentsHeight</span> : const <span class="type">int</span></h3>
<p>This property holds the height of the contents area.</p>
<p><b>Access functions:</b></p>
<table class="alignedsummary">
<tr><td class="memItemLeft topAlign rightAlign"> int </td><td class="memItemRight bottomAlign"><span class="name"><b>contentsHeight</b></span> () const</td></tr>
</table>
<!-- @@@contentsHeight -->
<!-- $$$contentsWidth-prop$$$contentsWidth -->
<h3 class="fn"><a name="contentsWidth-prop"></a><span class="name">contentsWidth</span> : const <span class="type">int</span></h3>
<p>This property holds the width of the contents area.</p>
<p><b>Access functions:</b></p>
<table class="alignedsummary">
<tr><td class="memItemLeft topAlign rightAlign"> int </td><td class="memItemRight bottomAlign"><span class="name"><b>contentsWidth</b></span> () const</td></tr>
</table>
<!-- @@@contentsWidth -->
<!-- $$$contentsX-prop$$$contentsX -->
<h3 class="fn"><a name="contentsX-prop"></a><span class="name">contentsX</span> : const <span class="type">int</span></h3>
<p>This property holds the X coordinate of the contents that are at the left edge of the viewport.</p>
<p><b>Access functions:</b></p>
<table class="alignedsummary">
<tr><td class="memItemLeft topAlign rightAlign"> int </td><td class="memItemRight bottomAlign"><span class="name"><b>contentsX</b></span> () const</td></tr>
</table>
<!-- @@@contentsX -->
<!-- $$$contentsY-prop$$$contentsY -->
<h3 class="fn"><a name="contentsY-prop"></a><span class="name">contentsY</span> : const <span class="type">int</span></h3>
<p>This property holds the Y coordinate of the contents that are at the top edge of the viewport.</p>
<p><b>Access functions:</b></p>
<table class="alignedsummary">
<tr><td class="memItemLeft topAlign rightAlign"> int </td><td class="memItemRight bottomAlign"><span class="name"><b>contentsY</b></span> () const</td></tr>
</table>
<!-- @@@contentsY -->
<!-- $$$dragAutoScroll-prop$$$dragAutoScroll$$$setDragAutoScrollbool -->
<h3 class="fn"><a name="dragAutoScroll-prop"></a><span class="name">dragAutoScroll</span> : <span class="type">bool</span></h3>
<p>This property holds whether autoscrolling in drag move events is enabled.</p>
<p>If this property is set to true (the default), the <a href="q3scrollview.html" class="compat">Q3ScrollView</a> automatically scrolls the contents in drag move events if the user moves the cursor close to a border of the view. Of course this works only if the viewport accepts drops. Specifying false disables this autoscroll feature.</p>
<p><b>Access functions:</b></p>
<table class="alignedsummary">
<tr><td class="memItemLeft topAlign rightAlign"> bool </td><td class="memItemRight bottomAlign"><span class="name"><b>dragAutoScroll</b></span> () const</td></tr>
<tr><td class="memItemLeft topAlign rightAlign"> virtual void </td><td class="memItemRight bottomAlign"><span class="name"><b>setDragAutoScroll</b></span> ( bool <i>b</i> )</td></tr>
</table>
<!-- @@@dragAutoScroll -->
<!-- $$$hScrollBarMode-prop$$$hScrollBarMode$$$setHScrollBarModeScrollBarMode -->
<h3 class="fn"><a name="hScrollBarMode-prop"></a><span class="name">hScrollBarMode</span> : <span class="type"><a href="q3scrollview.html#ScrollBarMode-enum">ScrollBarMode</a></span></h3>
<p>This property holds the mode for the horizontal scroll bar.</p>
<p>The default mode is <a href="q3scrollview.html#ScrollBarMode-enum">Q3ScrollView::Auto</a>.</p>
<p><b>Access functions:</b></p>
<table class="alignedsummary">
<tr><td class="memItemLeft topAlign rightAlign"> ScrollBarMode </td><td class="memItemRight bottomAlign"><span class="name"><b>hScrollBarMode</b></span> () const</td></tr>
<tr><td class="memItemLeft topAlign rightAlign"> virtual void </td><td class="memItemRight bottomAlign"><span class="name"><b>setHScrollBarMode</b></span> ( ScrollBarMode )</td></tr>
</table>
<p><b>See also </b><a href="q3scrollview.html#vScrollBarMode-prop">vScrollBarMode</a>.</p>
<!-- @@@hScrollBarMode -->
<!-- $$$resizePolicy-prop$$$resizePolicy$$$setResizePolicyResizePolicy -->
<h3 class="fn"><a name="resizePolicy-prop"></a><span class="name">resizePolicy</span> : <span class="type"><a href="q3scrollview.html#ResizePolicy-enum">ResizePolicy</a></span></h3>
<p>This property holds the resize policy.</p>
<p>The default is <tt>Default</tt>.</p>
<p><b>Access functions:</b></p>
<table class="alignedsummary">
<tr><td class="memItemLeft topAlign rightAlign"> ResizePolicy </td><td class="memItemRight bottomAlign"><span class="name"><b>resizePolicy</b></span> () const</td></tr>
<tr><td class="memItemLeft topAlign rightAlign"> virtual void </td><td class="memItemRight bottomAlign"><span class="name"><b>setResizePolicy</b></span> ( ResizePolicy )</td></tr>
</table>
<p><b>See also </b><a href="q3scrollview.html#ResizePolicy-enum">ResizePolicy</a>.</p>
<!-- @@@resizePolicy -->
<!-- $$$vScrollBarMode-prop$$$vScrollBarMode$$$setVScrollBarModeScrollBarMode -->
<h3 class="fn"><a name="vScrollBarMode-prop"></a><span class="name">vScrollBarMode</span> : <span class="type"><a href="q3scrollview.html#ScrollBarMode-enum">ScrollBarMode</a></span></h3>
<p>This property holds the mode for the vertical scroll bar.</p>
<p>The default mode is <a href="q3scrollview.html#ScrollBarMode-enum">Q3ScrollView::Auto</a>.</p>
<p><b>Access functions:</b></p>
<table class="alignedsummary">
<tr><td class="memItemLeft topAlign rightAlign"> ScrollBarMode </td><td class="memItemRight bottomAlign"><span class="name"><b>vScrollBarMode</b></span> () const</td></tr>
<tr><td class="memItemLeft topAlign rightAlign"> virtual void </td><td class="memItemRight bottomAlign"><span class="name"><b>setVScrollBarMode</b></span> ( ScrollBarMode )</td></tr>
</table>
<p><b>See also </b><a href="q3scrollview.html#hScrollBarMode-prop">hScrollBarMode</a>.</p>
<!-- @@@vScrollBarMode -->
<!-- $$$visibleHeight-prop$$$visibleHeight -->
<h3 class="fn"><a name="visibleHeight-prop"></a><span class="name">visibleHeight</span> : const <span class="type">int</span></h3>
<p>This property holds the vertical amount of the content that is visible.</p>
<p><b>Access functions:</b></p>
<table class="alignedsummary">
<tr><td class="memItemLeft topAlign rightAlign"> int </td><td class="memItemRight bottomAlign"><span class="name"><b>visibleHeight</b></span> () const</td></tr>
</table>
<!-- @@@visibleHeight -->
<!-- $$$visibleWidth-prop$$$visibleWidth -->
<h3 class="fn"><a name="visibleWidth-prop"></a><span class="name">visibleWidth</span> : const <span class="type">int</span></h3>
<p>This property holds the horizontal amount of the content that is visible.</p>
<p><b>Access functions:</b></p>
<table class="alignedsummary">
<tr><td class="memItemLeft topAlign rightAlign"> int </td><td class="memItemRight bottomAlign"><span class="name"><b>visibleWidth</b></span> () const</td></tr>
</table>
<!-- @@@visibleWidth -->
</div>
<div class="func">
<h2>Member Function Documentation</h2>
<!-- $$$Q3ScrollView[overload1]$$$Q3ScrollViewQWidget*constchar*Qt::WindowFlags -->
<h3 class="fn"><a name="Q3ScrollView"></a>Q3ScrollView::<span class="name">Q3ScrollView</span> ( <span class="type"><a href="qwidget.html">QWidget</a></span> * <i>parent</i> = 0, const <span class="type">char</span> * <i>name</i> = 0, <span class="type"><a href="qt.html#WindowType-enum">Qt::WindowFlags</a></span> <i>f</i> = 0 )</h3>
<p>Constructs a <a href="q3scrollview.html" class="compat">Q3ScrollView</a> called <i>name</i> with parent <i>parent</i> and widget flags <i>f</i>.</p>
<p>The widget flags <tt>WStaticContents</tt>, <tt>WNoAutoErase</tt> and <tt>WPaintClever</tt> are propagated to the <a href="q3scrollview.html#viewport">viewport</a>() widget. The other widget flags are propagated to the parent constructor as usual.</p>
<!-- @@@Q3ScrollView -->
<!-- $$$~Q3ScrollView[overload1]$$$~Q3ScrollView -->
<h3 class="fn"><a name="dtor.Q3ScrollView"></a>Q3ScrollView::<span class="name">~Q3ScrollView</span> ()</h3>
<p>Destroys the <a href="q3scrollview.html" class="compat">Q3ScrollView</a>. Any children added with <a href="q3scrollview.html#addChild">addChild</a>() will be deleted.</p>
<!-- @@@~Q3ScrollView -->
<!-- $$$addChild[overload1]$$$addChildQWidget*intint -->
<h3 class="fn"><a name="addChild"></a><span class="type">void</span> Q3ScrollView::<span class="name">addChild</span> ( <span class="type"><a href="qwidget.html">QWidget</a></span> * <i>child</i>, <span class="type">int</span> <i>x</i> = 0, <span class="type">int</span> <i>y</i> = 0 )<tt> [virtual]</tt></h3>
<p>Inserts the widget, <i>child</i>, into the scrolled area positioned at (<i>x</i>, <i>y</i>). The position defaults to (0, 0). If the child is already in the view, it is just moved.</p>
<p>You may want to call enableClipper(true) if you add a large number of widgets.</p>
<!-- @@@addChild -->
<!-- $$$bottomMargin[overload1]$$$bottomMargin -->
<h3 class="fn"><a name="bottomMargin"></a><span class="type">int</span> Q3ScrollView::<span class="name">bottomMargin</span> () const</h3>
<p>Returns the bottom margin.</p>
<p><b>See also </b><a href="q3scrollview.html#setMargins">setMargins</a>().</p>
<!-- @@@bottomMargin -->
<!-- $$$center[overload1]$$$centerintint -->
<h3 class="fn"><a name="center"></a><span class="type">void</span> Q3ScrollView::<span class="name">center</span> ( <span class="type">int</span> <i>x</i>, <span class="type">int</span> <i>y</i> )<tt> [slot]</tt></h3>
<p>Scrolls the content so that the point (<i>x</i>, <i>y</i>) is in the center of visible area.</p>
<!-- @@@center -->
<!-- $$$center$$$centerintintfloatfloat -->
<h3 class="fn"><a name="center-2"></a><span class="type">void</span> Q3ScrollView::<span class="name">center</span> ( <span class="type">int</span> <i>x</i>, <span class="type">int</span> <i>y</i>, <span class="type">float</span> <i>xmargin</i>, <span class="type">float</span> <i>ymargin</i> )<tt> [slot]</tt></h3>
<p>This is an overloaded function.</p>
<p>Scrolls the content so that the point (<i>x</i>, <i>y</i>) is visible with the <i>xmargin</i> and <i>ymargin</i> margins (as fractions of visible the area).</p>
<p>For example:</p>
<ul>
<li>Margin 0.0 allows (x, y) to be on the edge of the visible area.</li>
<li>Margin 0.5 ensures that (x, y) is in middle 50% of the visible area.</li>
<li>Margin 1.0 ensures that (x, y) is in the center of the visible area.</li>
</ul>
<!-- @@@center -->
<!-- $$$childX[overload1]$$$childXQWidget* -->
<h3 class="fn"><a name="childX"></a><span class="type">int</span> Q3ScrollView::<span class="name">childX</span> ( <span class="type"><a href="qwidget.html">QWidget</a></span> * <i>child</i> )</h3>
<p>Returns the X position of the given <i>child</i> widget. Use this rather than <a href="qwidget.html#x-prop">QWidget::x</a>() for widgets added to the view.</p>
<p>This function returns 0 if <i>child</i> has not been added to the view.</p>
<!-- @@@childX -->
<!-- $$$childY[overload1]$$$childYQWidget* -->
<h3 class="fn"><a name="childY"></a><span class="type">int</span> Q3ScrollView::<span class="name">childY</span> ( <span class="type"><a href="qwidget.html">QWidget</a></span> * <i>child</i> )</h3>
<p>Returns the Y position of the given <i>child</i> widget. Use this rather than <a href="qwidget.html#y-prop">QWidget::y</a>() for widgets added to the view.</p>
<p>This function returns 0 if <i>child</i> has not been added to the view.</p>
<!-- @@@childY -->
<!-- $$$clipper[overload1]$$$clipper -->
<h3 class="fn"><a name="clipper"></a><span class="type"><a href="qwidget.html">QWidget</a></span> * Q3ScrollView::<span class="name">clipper</span> () const</h3>
<p>Returns the clipper widget. Contents in the scrollview are ultimately clipped to be inside the clipper widget.</p>
<p>You should not need to use this function.</p>
<p><b>See also </b><a href="q3scrollview.html#visibleWidth-prop">visibleWidth</a>() and <a href="q3scrollview.html#visibleHeight-prop">visibleHeight</a>().</p>
<!-- @@@clipper -->
<!-- $$$contentsContextMenuEvent[overload1]$$$contentsContextMenuEventQContextMenuEvent* -->
<h3 class="fn"><a name="contentsContextMenuEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">contentsContextMenuEvent</span> ( <span class="type"><a href="qcontextmenuevent.html">QContextMenuEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>This event handler is called whenever the <a href="q3scrollview.html" class="compat">Q3ScrollView</a> receives a <a href="q3scrollview.html#contextMenuEvent">contextMenuEvent</a>() in <i>e</i>: the mouse position is translated to be a point on the contents.</p>
<!-- @@@contentsContextMenuEvent -->
<!-- $$$contentsDragEnterEvent[overload1]$$$contentsDragEnterEventQDragEnterEvent* -->
<h3 class="fn"><a name="contentsDragEnterEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">contentsDragEnterEvent</span> ( <span class="type"><a href="qdragenterevent.html">QDragEnterEvent</a></span> * <i>event</i> )<tt> [virtual protected]</tt></h3>
<p>This event handler is called whenever the <a href="q3scrollview.html" class="compat">Q3ScrollView</a> receives a <a href="qwidget.html#dragEnterEvent">dragEnterEvent</a>(): the drag position is translated to be a point on the contents.</p>
<p>The default implementation does nothing. The <i>event</i> parameter is ignored.</p>
<!-- @@@contentsDragEnterEvent -->
<!-- $$$contentsDragLeaveEvent[overload1]$$$contentsDragLeaveEventQDragLeaveEvent* -->
<h3 class="fn"><a name="contentsDragLeaveEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">contentsDragLeaveEvent</span> ( <span class="type"><a href="qdragleaveevent.html">QDragLeaveEvent</a></span> * <i>event</i> )<tt> [virtual protected]</tt></h3>
<p>This event handler is called whenever the <a href="q3scrollview.html" class="compat">Q3ScrollView</a> receives a <a href="qwidget.html#dragLeaveEvent">dragLeaveEvent</a>(): the drag position is translated to be a point on the contents.</p>
<p>The default implementation does nothing. The <i>event</i> parameter is ignored.</p>
<!-- @@@contentsDragLeaveEvent -->
<!-- $$$contentsDragMoveEvent[overload1]$$$contentsDragMoveEventQDragMoveEvent* -->
<h3 class="fn"><a name="contentsDragMoveEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">contentsDragMoveEvent</span> ( <span class="type"><a href="qdragmoveevent.html">QDragMoveEvent</a></span> * <i>event</i> )<tt> [virtual protected]</tt></h3>
<p>This event handler is called whenever the <a href="q3scrollview.html" class="compat">Q3ScrollView</a> receives a <a href="qwidget.html#dragMoveEvent">dragMoveEvent</a>(): the drag position is translated to be a point on the contents.</p>
<p>The default implementation does nothing. The <i>event</i> parameter is ignored.</p>
<!-- @@@contentsDragMoveEvent -->
<!-- $$$contentsDropEvent[overload1]$$$contentsDropEventQDropEvent* -->
<h3 class="fn"><a name="contentsDropEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">contentsDropEvent</span> ( <span class="type"><a href="qdropevent.html">QDropEvent</a></span> * <i>event</i> )<tt> [virtual protected]</tt></h3>
<p>This event handler is called whenever the <a href="q3scrollview.html" class="compat">Q3ScrollView</a> receives a <a href="qwidget.html#dropEvent">dropEvent</a>(): the drop position is translated to be a point on the contents.</p>
<p>The default implementation does nothing. The <i>event</i> parameter is ignored.</p>
<!-- @@@contentsDropEvent -->
<!-- $$$contentsMouseDoubleClickEvent[overload1]$$$contentsMouseDoubleClickEventQMouseEvent* -->
<h3 class="fn"><a name="contentsMouseDoubleClickEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">contentsMouseDoubleClickEvent</span> ( <span class="type"><a href="qmouseevent.html">QMouseEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>This event handler is called whenever the <a href="q3scrollview.html" class="compat">Q3ScrollView</a> receives a <a href="q3scrollview.html#mouseDoubleClickEvent">mouseDoubleClickEvent</a>(): the click position in <i>e</i> is translated to be a point on the contents.</p>
<p>The default implementation generates a normal mouse press event.</p>
<!-- @@@contentsMouseDoubleClickEvent -->
<!-- $$$contentsMouseMoveEvent[overload1]$$$contentsMouseMoveEventQMouseEvent* -->
<h3 class="fn"><a name="contentsMouseMoveEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">contentsMouseMoveEvent</span> ( <span class="type"><a href="qmouseevent.html">QMouseEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>This event handler is called whenever the <a href="q3scrollview.html" class="compat">Q3ScrollView</a> receives a <a href="q3scrollview.html#mouseMoveEvent">mouseMoveEvent</a>(): the mouse position in <i>e</i> is translated to be a point on the contents.</p>
<!-- @@@contentsMouseMoveEvent -->
<!-- $$$contentsMousePressEvent[overload1]$$$contentsMousePressEventQMouseEvent* -->
<h3 class="fn"><a name="contentsMousePressEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">contentsMousePressEvent</span> ( <span class="type"><a href="qmouseevent.html">QMouseEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>This event handler is called whenever the <a href="q3scrollview.html" class="compat">Q3ScrollView</a> receives a <a href="q3scrollview.html#mousePressEvent">mousePressEvent</a>(): the press position in <i>e</i> is translated to be a point on the contents.</p>
<!-- @@@contentsMousePressEvent -->
<!-- $$$contentsMouseReleaseEvent[overload1]$$$contentsMouseReleaseEventQMouseEvent* -->
<h3 class="fn"><a name="contentsMouseReleaseEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">contentsMouseReleaseEvent</span> ( <span class="type"><a href="qmouseevent.html">QMouseEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>This event handler is called whenever the <a href="q3scrollview.html" class="compat">Q3ScrollView</a> receives a <a href="q3scrollview.html#mouseReleaseEvent">mouseReleaseEvent</a>(): the release position in <i>e</i> is translated to be a point on the contents.</p>
<!-- @@@contentsMouseReleaseEvent -->
<!-- $$$contentsMoving[overload1]$$$contentsMovingintint -->
<h3 class="fn"><a name="contentsMoving"></a><span class="type">void</span> Q3ScrollView::<span class="name">contentsMoving</span> ( <span class="type">int</span> <i>x</i>, <span class="type">int</span> <i>y</i> )<tt> [signal]</tt></h3>
<p>This signal is emitted just before the contents are moved to position (<i>x</i>, <i>y</i>).</p>
<p><b>See also </b><a href="q3scrollview.html#contentsX-prop">contentsX</a>() and <a href="q3scrollview.html#contentsY-prop">contentsY</a>().</p>
<!-- @@@contentsMoving -->
<!-- $$$contentsToViewport[overload1]$$$contentsToViewportintintint&int& -->
<h3 class="fn"><a name="contentsToViewport"></a><span class="type">void</span> Q3ScrollView::<span class="name">contentsToViewport</span> ( <span class="type">int</span> <i>x</i>, <span class="type">int</span> <i>y</i>, <span class="type">int</span> &amp; <i>vx</i>, <span class="type">int</span> &amp; <i>vy</i> ) const</h3>
<p>Translates a point (<i>x</i>, <i>y</i>) in the contents to a point (<i>vx</i>, <i>vy</i>) on the <a href="q3scrollview.html#viewport">viewport</a>() widget.</p>
<!-- @@@contentsToViewport -->
<!-- $$$contentsToViewport$$$contentsToViewportconstQPoint& -->
<h3 class="fn"><a name="contentsToViewport-2"></a><span class="type"><a href="qpoint.html">QPoint</a></span> Q3ScrollView::<span class="name">contentsToViewport</span> ( const <span class="type"><a href="qpoint.html">QPoint</a></span> &amp; <i>p</i> ) const</h3>
<p>This is an overloaded function.</p>
<p>Returns the point <i>p</i> translated to a point on the <a href="q3scrollview.html#viewport">viewport</a>() widget.</p>
<!-- @@@contentsToViewport -->
<!-- $$$contentsWheelEvent[overload1]$$$contentsWheelEventQWheelEvent* -->
<h3 class="fn"><a name="contentsWheelEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">contentsWheelEvent</span> ( <span class="type"><a href="qwheelevent.html">QWheelEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>This event handler is called whenever the <a href="q3scrollview.html" class="compat">Q3ScrollView</a> receives a <a href="q3scrollview.html#wheelEvent">wheelEvent</a>() in <i>e</i>: the mouse position is translated to be a point on the contents.</p>
<!-- @@@contentsWheelEvent -->
<!-- $$$contextMenuEvent[overload1]$$$contextMenuEventQContextMenuEvent* -->
<h3 class="fn"><a name="contextMenuEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">contextMenuEvent</span> ( <span class="type"><a href="qcontextmenuevent.html">QContextMenuEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#contextMenuEvent">QWidget::contextMenuEvent</a>().</p>
<!-- @@@contextMenuEvent -->
<!-- $$$cornerWidget[overload1]$$$cornerWidget -->
<h3 class="fn"><a name="cornerWidget"></a><span class="type"><a href="qwidget.html">QWidget</a></span> * Q3ScrollView::<span class="name">cornerWidget</span> () const</h3>
<p>Returns the widget in the corner between the two scroll bars.</p>
<p>By default, no corner widget is present.</p>
<p><b>See also </b><a href="q3scrollview.html#setCornerWidget">setCornerWidget</a>().</p>
<!-- @@@cornerWidget -->
<!-- $$$drawContents[overload1]$$$drawContentsQPainter*intintintint -->
<h3 class="fn"><a name="drawContents"></a><span class="type">void</span> Q3ScrollView::<span class="name">drawContents</span> ( <span class="type"><a href="qpainter.html">QPainter</a></span> * <i>p</i>, <span class="type">int</span> <i>clipx</i>, <span class="type">int</span> <i>clipy</i>, <span class="type">int</span> <i>clipw</i>, <span class="type">int</span> <i>cliph</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplement this function if you are viewing a drawing area rather than a widget.</p>
<p>The function should draw the rectangle (<i>clipx</i>, <i>clipy</i>, <i>clipw</i>, <i>cliph</i>) of the contents using painter <i>p</i>. The clip rectangle is in the scrollview's coordinates.</p>
<p>For example:</p>
<pre class="cpp"> {
     <span class="comment">// Fill a 40000 by 50000 rectangle at (100000,150000)</span>

     <span class="comment">// Calculate the coordinates...</span>
     <span class="type">int</span> x1 <span class="operator">=</span> <span class="number">100000</span><span class="operator">,</span> y1 <span class="operator">=</span> <span class="number">150000</span>;
     <span class="type">int</span> x2 <span class="operator">=</span> x1<span class="operator">+</span><span class="number">40000</span><span class="operator">-</span><span class="number">1</span><span class="operator">,</span> y2 <span class="operator">=</span> y1<span class="operator">+</span><span class="number">50000</span><span class="operator">-</span><span class="number">1</span>;

     <span class="comment">// Clip the coordinates so X/Windows will not have problems...</span>
     <span class="keyword">if</span> (x1 <span class="operator">&lt;</span> clipx) x1<span class="operator">=</span>clipx;
     <span class="keyword">if</span> (y1 <span class="operator">&lt;</span> clipy) y1<span class="operator">=</span>clipy;
     <span class="keyword">if</span> (x2 <span class="operator">&gt;</span> clipx<span class="operator">+</span>clipw<span class="operator">-</span><span class="number">1</span>) x2<span class="operator">=</span>clipx<span class="operator">+</span>clipw<span class="operator">-</span><span class="number">1</span>;
     <span class="keyword">if</span> (y2 <span class="operator">&gt;</span> clipy<span class="operator">+</span>cliph<span class="operator">-</span><span class="number">1</span>) y2<span class="operator">=</span>clipy<span class="operator">+</span>cliph<span class="operator">-</span><span class="number">1</span>;

     <span class="comment">// Paint using the small coordinates...</span>
     <span class="keyword">if</span> (x2 <span class="operator">&gt;</span><span class="operator">=</span> x1 <span class="operator">&amp;</span><span class="operator">&amp;</span> y2 <span class="operator">&gt;</span><span class="operator">=</span> y1)
         p<span class="operator">-</span><span class="operator">&gt;</span>fillRect(x1<span class="operator">,</span> y1<span class="operator">,</span> x2<span class="operator">-</span>x1<span class="operator">+</span><span class="number">1</span><span class="operator">,</span> y2<span class="operator">-</span>y1<span class="operator">+</span><span class="number">1</span><span class="operator">,</span> red);
 }</pre>
<p>The clip rectangle and translation of the painter <i>p</i> is already set appropriately.</p>
<!-- @@@drawContents -->
<!-- $$$drawContentsOffset[overload1]$$$drawContentsOffsetQPainter*intintintintintint -->
<h3 class="fn"><a name="drawContentsOffset"></a><span class="type">void</span> Q3ScrollView::<span class="name">drawContentsOffset</span> ( <span class="type"><a href="qpainter.html">QPainter</a></span> * <i>p</i>, <span class="type">int</span> <i>offsetx</i>, <span class="type">int</span> <i>offsety</i>, <span class="type">int</span> <i>clipx</i>, <span class="type">int</span> <i>clipy</i>, <span class="type">int</span> <i>clipw</i>, <span class="type">int</span> <i>cliph</i> )<tt> [virtual protected]</tt></h3>
<p>For backward-compatibility only. It is easier to use drawContents(<a href="qpainter.html">QPainter</a>*,int,int,int,int).</p>
<p>The default implementation translates the painter appropriately and calls drawContents(<a href="qpainter.html">QPainter</a>*,int,int,int,int). See <a href="q3scrollview.html#drawContents">drawContents</a>() for an explanation of the parameters <i>p</i>, <i>offsetx</i>, <i>offsety</i>, <i>clipx</i>, <i>clipy</i>, <i>clipw</i> and <i>cliph</i>.</p>
<!-- @@@drawContentsOffset -->
<!-- $$$enableClipper[overload1]$$$enableClipperbool -->
<h3 class="fn"><a name="enableClipper"></a><span class="type">void</span> Q3ScrollView::<span class="name">enableClipper</span> ( <span class="type">bool</span> <i>y</i> )</h3>
<p>When a large numbers of child widgets are in a scrollview, especially if they are close together, the scrolling performance can suffer greatly. If <i>y</i> is true the scrollview will use an extra widget to group child widgets.</p>
<p>Note that you may only call enableClipper() prior to adding widgets.</p>
<!-- @@@enableClipper -->
<!-- $$$ensureVisible[overload1]$$$ensureVisibleintint -->
<h3 class="fn"><a name="ensureVisible"></a><span class="type">void</span> Q3ScrollView::<span class="name">ensureVisible</span> ( <span class="type">int</span> <i>x</i>, <span class="type">int</span> <i>y</i> )<tt> [slot]</tt></h3>
<p>Scrolls the content so that the point (<i>x</i>, <i>y</i>) is visible with at least 50-pixel margins (if possible, otherwise centered).</p>
<!-- @@@ensureVisible -->
<!-- $$$ensureVisible$$$ensureVisibleintintintint -->
<h3 class="fn"><a name="ensureVisible-2"></a><span class="type">void</span> Q3ScrollView::<span class="name">ensureVisible</span> ( <span class="type">int</span> <i>x</i>, <span class="type">int</span> <i>y</i>, <span class="type">int</span> <i>xmargin</i>, <span class="type">int</span> <i>ymargin</i> )<tt> [slot]</tt></h3>
<p>This is an overloaded function.</p>
<p>Scrolls the content so that the point (<i>x</i>, <i>y</i>) is visible with at least the <i>xmargin</i> and <i>ymargin</i> margins (if possible, otherwise centered).</p>
<!-- @@@ensureVisible -->
<!-- $$$eventFilter[overload1]$$$eventFilterQObject*QEvent* -->
<h3 class="fn"><a name="eventFilter"></a><span class="type">bool</span> Q3ScrollView::<span class="name">eventFilter</span> ( <span class="type"><a href="qobject.html">QObject</a></span> * <i>obj</i>, <span class="type"><a href="qevent.html">QEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qobject.html#eventFilter">QObject::eventFilter</a>().</p>
<p>This event filter ensures the scroll bars are updated when a single contents widget is resized, shown, hidden or destroyed; it passes mouse events to the <a href="q3scrollview.html" class="compat">Q3ScrollView</a>. The event is in <i>e</i> and the object is in <i>obj</i>.</p>
<!-- @@@eventFilter -->
<!-- $$$focusNextPrevChild[overload1]$$$focusNextPrevChildbool -->
<h3 class="fn"><a name="focusNextPrevChild"></a><span class="type">bool</span> Q3ScrollView::<span class="name">focusNextPrevChild</span> ( <span class="type">bool</span> <i>next</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#focusNextPrevChild">QWidget::focusNextPrevChild</a>().</p>
<!-- @@@focusNextPrevChild -->
<!-- $$$frameChanged[overload1]$$$frameChanged -->
<h3 class="fn"><a name="frameChanged"></a><span class="type">void</span> Q3ScrollView::<span class="name">frameChanged</span> ()<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="q3frame.html#frameChanged">Q3Frame::frameChanged</a>().</p>
<!-- @@@frameChanged -->
<!-- $$$hasStaticBackground[overload1]$$$hasStaticBackground -->
<h3 class="fn"><a name="hasStaticBackground"></a><span class="type">bool</span> Q3ScrollView::<span class="name">hasStaticBackground</span> () const</h3>
<p>Returns true if <a href="q3scrollview.html" class="compat">Q3ScrollView</a> uses a static background; otherwise returns false.</p>
<p><b>See also </b><a href="q3scrollview.html#setStaticBackground">setStaticBackground</a>().</p>
<!-- @@@hasStaticBackground -->
<!-- $$$horizontalScrollBar[overload1]$$$horizontalScrollBar -->
<h3 class="fn"><a name="horizontalScrollBar"></a><span class="type"><a href="qscrollbar.html">QScrollBar</a></span> * Q3ScrollView::<span class="name">horizontalScrollBar</span> () const</h3>
<p>Returns the component horizontal scroll bar. It is made available to allow accelerators, autoscrolling, etc.</p>
<p>It should not be used for other purposes.</p>
<p>This function never returns 0.</p>
<!-- @@@horizontalScrollBar -->
<!-- $$$horizontalSliderPressed[overload1]$$$horizontalSliderPressed -->
<h3 class="fn"><a name="horizontalSliderPressed"></a><span class="type">void</span> Q3ScrollView::<span class="name">horizontalSliderPressed</span> ()<tt> [signal]</tt></h3>
<p>This signal is emitted whenever the user presses the horizontal slider.</p>
<!-- @@@horizontalSliderPressed -->
<!-- $$$horizontalSliderReleased[overload1]$$$horizontalSliderReleased -->
<h3 class="fn"><a name="horizontalSliderReleased"></a><span class="type">void</span> Q3ScrollView::<span class="name">horizontalSliderReleased</span> ()<tt> [signal]</tt></h3>
<p>This signal is emitted whenever the user releases the horizontal slider.</p>
<!-- @@@horizontalSliderReleased -->
<!-- $$$isHorizontalSliderPressed[overload1]$$$isHorizontalSliderPressed -->
<h3 class="fn"><a name="isHorizontalSliderPressed"></a><span class="type">bool</span> Q3ScrollView::<span class="name">isHorizontalSliderPressed</span> ()</h3>
<p>Returns true if horizontal slider is pressed by user; otherwise returns false.</p>
<!-- @@@isHorizontalSliderPressed -->
<!-- $$$isVerticalSliderPressed[overload1]$$$isVerticalSliderPressed -->
<h3 class="fn"><a name="isVerticalSliderPressed"></a><span class="type">bool</span> Q3ScrollView::<span class="name">isVerticalSliderPressed</span> ()</h3>
<p>Returns true if vertical slider is pressed by user; otherwise returns false.</p>
<!-- @@@isVerticalSliderPressed -->
<!-- $$$leftMargin[overload1]$$$leftMargin -->
<h3 class="fn"><a name="leftMargin"></a><span class="type">int</span> Q3ScrollView::<span class="name">leftMargin</span> () const</h3>
<p>Returns the left margin.</p>
<p><b>See also </b><a href="q3scrollview.html#setMargins">setMargins</a>().</p>
<!-- @@@leftMargin -->
<!-- $$$minimumSizeHint[overload1]$$$minimumSizeHint -->
<h3 class="fn"><a name="minimumSizeHint"></a><span class="type"><a href="qsize.html">QSize</a></span> Q3ScrollView::<span class="name">minimumSizeHint</span> () const<tt> [virtual]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#minimumSizeHint-prop">QWidget::minimumSizeHint</a>().</p>
<!-- @@@minimumSizeHint -->
<!-- $$$mouseDoubleClickEvent[overload1]$$$mouseDoubleClickEventQMouseEvent* -->
<h3 class="fn"><a name="mouseDoubleClickEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">mouseDoubleClickEvent</span> ( <span class="type"><a href="qmouseevent.html">QMouseEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#mouseDoubleClickEvent">QWidget::mouseDoubleClickEvent</a>().</p>
<!-- @@@mouseDoubleClickEvent -->
<!-- $$$mouseMoveEvent[overload1]$$$mouseMoveEventQMouseEvent* -->
<h3 class="fn"><a name="mouseMoveEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">mouseMoveEvent</span> ( <span class="type"><a href="qmouseevent.html">QMouseEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#mouseMoveEvent">QWidget::mouseMoveEvent</a>().</p>
<!-- @@@mouseMoveEvent -->
<!-- $$$mousePressEvent[overload1]$$$mousePressEventQMouseEvent* -->
<h3 class="fn"><a name="mousePressEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">mousePressEvent</span> ( <span class="type"><a href="qmouseevent.html">QMouseEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#mousePressEvent">QWidget::mousePressEvent</a>().</p>
<!-- @@@mousePressEvent -->
<!-- $$$mouseReleaseEvent[overload1]$$$mouseReleaseEventQMouseEvent* -->
<h3 class="fn"><a name="mouseReleaseEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">mouseReleaseEvent</span> ( <span class="type"><a href="qmouseevent.html">QMouseEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#mouseReleaseEvent">QWidget::mouseReleaseEvent</a>().</p>
<!-- @@@mouseReleaseEvent -->
<!-- $$$moveChild[overload1]$$$moveChildQWidget*intint -->
<h3 class="fn"><a name="moveChild"></a><span class="type">void</span> Q3ScrollView::<span class="name">moveChild</span> ( <span class="type"><a href="qwidget.html">QWidget</a></span> * <i>child</i>, <span class="type">int</span> <i>x</i>, <span class="type">int</span> <i>y</i> )<tt> [virtual]</tt></h3>
<p>Repositions the <i>child</i> widget to (<i>x</i>, <i>y</i>). This function is the same as <a href="q3scrollview.html#addChild">addChild</a>().</p>
<!-- @@@moveChild -->
<!-- $$$removeChild[overload1]$$$removeChildQWidget* -->
<h3 class="fn"><a name="removeChild"></a><span class="type">void</span> Q3ScrollView::<span class="name">removeChild</span> ( <span class="type"><a href="qwidget.html">QWidget</a></span> * <i>child</i> )</h3>
<p>Removes the <i>child</i> widget from the scrolled area. Note that this happens automatically if the <i>child</i> is deleted.</p>
<!-- @@@removeChild -->
<!-- $$$repaintContents[overload1]$$$repaintContentsintintintintbool -->
<h3 class="fn"><a name="repaintContents"></a><span class="type">void</span> Q3ScrollView::<span class="name">repaintContents</span> ( <span class="type">int</span> <i>x</i>, <span class="type">int</span> <i>y</i>, <span class="type">int</span> <i>w</i>, <span class="type">int</span> <i>h</i>, <span class="type">bool</span> <i>erase</i> = true )</h3>
<p>Calls <a href="qwidget.html#repaint">repaint</a>() on a rectangle defined by <i>x</i>, <i>y</i>, <i>w</i>, <i>h</i>, translated appropriately. If the rectangle is not visible, nothing is repainted. If <i>erase</i> is true the background is cleared using the background color.</p>
<p><b>See also </b><a href="q3scrollview.html#updateContents">updateContents</a>().</p>
<!-- @@@repaintContents -->
<!-- $$$repaintContents$$$repaintContentsconstQRect&bool -->
<h3 class="fn"><a name="repaintContents-2"></a><span class="type">void</span> Q3ScrollView::<span class="name">repaintContents</span> ( const <span class="type"><a href="qrect.html">QRect</a></span> &amp; <i>r</i>, <span class="type">bool</span> <i>erase</i> = true )</h3>
<p>This is an overloaded function.</p>
<p>Repaints the contents of rectangle <i>r</i>. If <i>erase</i> is true the background is cleared using the background color.</p>
<!-- @@@repaintContents -->
<!-- $$$repaintContents$$$repaintContentsbool -->
<h3 class="fn"><a name="repaintContents-3"></a><span class="type">void</span> Q3ScrollView::<span class="name">repaintContents</span> ( <span class="type">bool</span> <i>erase</i> = true )</h3>
<p>This is an overloaded function.</p>
<p>Repaints the contents. If <i>erase</i> is true the background is cleared using the background color.</p>
<!-- @@@repaintContents -->
<!-- $$$resizeContents[overload1]$$$resizeContentsintint -->
<h3 class="fn"><a name="resizeContents"></a><span class="type">void</span> Q3ScrollView::<span class="name">resizeContents</span> ( <span class="type">int</span> <i>w</i>, <span class="type">int</span> <i>h</i> )<tt> [virtual slot]</tt></h3>
<p>Sets the size of the contents area to <i>w</i> pixels wide and <i>h</i> pixels high and updates the viewport accordingly.</p>
<!-- @@@resizeContents -->
<!-- $$$resizeEvent[overload1]$$$resizeEventQResizeEvent* -->
<h3 class="fn"><a name="resizeEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">resizeEvent</span> ( <span class="type"><a href="qresizeevent.html">QResizeEvent</a></span> * <i>event</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#resizeEvent">QWidget::resizeEvent</a>().</p>
<!-- @@@resizeEvent -->
<!-- $$$rightMargin[overload1]$$$rightMargin -->
<h3 class="fn"><a name="rightMargin"></a><span class="type">int</span> Q3ScrollView::<span class="name">rightMargin</span> () const</h3>
<p>Returns the right margin.</p>
<p><b>See also </b><a href="q3scrollview.html#setMargins">setMargins</a>().</p>
<!-- @@@rightMargin -->
<!-- $$$scrollBy[overload1]$$$scrollByintint -->
<h3 class="fn"><a name="scrollBy"></a><span class="type">void</span> Q3ScrollView::<span class="name">scrollBy</span> ( <span class="type">int</span> <i>dx</i>, <span class="type">int</span> <i>dy</i> )<tt> [slot]</tt></h3>
<p>Scrolls the content by <i>dx</i> to the left and <i>dy</i> upwards.</p>
<!-- @@@scrollBy -->
<!-- $$$setContentsPos[overload1]$$$setContentsPosintint -->
<h3 class="fn"><a name="setContentsPos"></a><span class="type">void</span> Q3ScrollView::<span class="name">setContentsPos</span> ( <span class="type">int</span> <i>x</i>, <span class="type">int</span> <i>y</i> )<tt> [virtual slot]</tt></h3>
<p>Scrolls the content so that the point (<i>x</i>, <i>y</i>) is in the top-left corner.</p>
<!-- @@@setContentsPos -->
<!-- $$$setCornerWidget[overload1]$$$setCornerWidgetQWidget* -->
<h3 class="fn"><a name="setCornerWidget"></a><span class="type">void</span> Q3ScrollView::<span class="name">setCornerWidget</span> ( <span class="type"><a href="qwidget.html">QWidget</a></span> * <i>corner</i> )<tt> [virtual]</tt></h3>
<p>Sets the widget in the <i>corner</i> between the two scroll bars.</p>
<p>You will probably also want to set at least one of the scroll bar modes to <tt>AlwaysOn</tt>.</p>
<p>Passing 0 shows no widget in the corner.</p>
<p>Any previous <i>corner</i> widget is hidden.</p>
<p>You may call setCornerWidget() with the same widget at different times.</p>
<p>All widgets set here will be deleted by the <a href="q3scrollview.html" class="compat">Q3ScrollView</a> when it is destroyed unless you separately reparent the widget after setting some other corner widget (or 0).</p>
<p>Any <i>newly</i> set widget should have no current parent.</p>
<p>By default, no corner widget is present.</p>
<p><b>See also </b><a href="q3scrollview.html#cornerWidget">cornerWidget</a>(), <a href="q3scrollview.html#vScrollBarMode-prop">setVScrollBarMode</a>(), and <a href="q3scrollview.html#hScrollBarMode-prop">setHScrollBarMode</a>().</p>
<!-- @@@setCornerWidget -->
<!-- $$$setHBarGeometry[overload1]$$$setHBarGeometryQScrollBar&intintintint -->
<h3 class="fn"><a name="setHBarGeometry"></a><span class="type">void</span> Q3ScrollView::<span class="name">setHBarGeometry</span> ( <span class="type"><a href="qscrollbar.html">QScrollBar</a></span> &amp; <i>hbar</i>, <span class="type">int</span> <i>x</i>, <span class="type">int</span> <i>y</i>, <span class="type">int</span> <i>w</i>, <span class="type">int</span> <i>h</i> )<tt> [virtual protected]</tt></h3>
<p>Called when the horizontal scroll bar geometry changes. This is provided as a protected function so that subclasses can do interesting things such as providing extra buttons in some of the space normally used by the scroll bars.</p>
<p>The default implementation simply gives all the space to <i>hbar</i>. The new geometry is given by <i>x</i>, <i>y</i>, <i>w</i> and <i>h</i>.</p>
<p><b>See also </b><a href="q3scrollview.html#setVBarGeometry">setVBarGeometry</a>().</p>
<!-- @@@setHBarGeometry -->
<!-- $$$setMargins[overload1]$$$setMarginsintintintint -->
<h3 class="fn"><a name="setMargins"></a><span class="type">void</span> Q3ScrollView::<span class="name">setMargins</span> ( <span class="type">int</span> <i>left</i>, <span class="type">int</span> <i>top</i>, <span class="type">int</span> <i>right</i>, <span class="type">int</span> <i>bottom</i> )<tt> [virtual]</tt></h3>
<p>Sets the margins around the scrolling area to <i>left</i>, <i>top</i>, <i>right</i> and <i>bottom</i>. This is useful for applications such as spreadsheets with &quot;locked&quot; rows and columns. The marginal space is <i>inside</i> the <a href="qframe.html#frameRect-prop">frameRect</a>() and is left blank; reimplement <a href="q3frame.html#drawFrame">drawFrame</a>() or put widgets in the unused area.</p>
<p>By default all margins are zero.</p>
<p><b>See also </b><a href="q3scrollview.html#frameChanged">frameChanged</a>().</p>
<!-- @@@setMargins -->
<!-- $$$setStaticBackground[overload1]$$$setStaticBackgroundbool -->
<h3 class="fn"><a name="setStaticBackground"></a><span class="type">void</span> Q3ScrollView::<span class="name">setStaticBackground</span> ( <span class="type">bool</span> <i>y</i> )</h3>
<p>Sets the scrollview to have a static background if <i>y</i> is true, or a scrolling background if <i>y</i> is false. By default, the background is scrolling.</p>
<p>Be aware that this mode is quite slow, as a full repaint of the visible area has to be triggered on every contents move.</p>
<p><b>See also </b><a href="q3scrollview.html#hasStaticBackground">hasStaticBackground</a>().</p>
<!-- @@@setStaticBackground -->
<!-- $$$setVBarGeometry[overload1]$$$setVBarGeometryQScrollBar&intintintint -->
<h3 class="fn"><a name="setVBarGeometry"></a><span class="type">void</span> Q3ScrollView::<span class="name">setVBarGeometry</span> ( <span class="type"><a href="qscrollbar.html">QScrollBar</a></span> &amp; <i>vbar</i>, <span class="type">int</span> <i>x</i>, <span class="type">int</span> <i>y</i>, <span class="type">int</span> <i>w</i>, <span class="type">int</span> <i>h</i> )<tt> [virtual protected]</tt></h3>
<p>Called when the vertical scroll bar geometry changes. This is provided as a protected function so that subclasses can do interesting things such as providing extra buttons in some of the space normally used by the scroll bars.</p>
<p>The default implementation simply gives all the space to <i>vbar</i>. The new geometry is given by <i>x</i>, <i>y</i>, <i>w</i> and <i>h</i>.</p>
<p><b>See also </b><a href="q3scrollview.html#setHBarGeometry">setHBarGeometry</a>().</p>
<!-- @@@setVBarGeometry -->
<!-- $$$setVisible[overload1]$$$setVisiblebool -->
<h3 class="fn"><a name="setVisible"></a><span class="type">void</span> Q3ScrollView::<span class="name">setVisible</span> ( <span class="type">bool</span> <i>visible</i> )<tt> [virtual]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#visible-prop">QWidget::setVisible</a>().</p>
<!-- @@@setVisible -->
<!-- $$$sizeHint[overload1]$$$sizeHint -->
<h3 class="fn"><a name="sizeHint"></a><span class="type"><a href="qsize.html">QSize</a></span> Q3ScrollView::<span class="name">sizeHint</span> () const<tt> [virtual]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#sizeHint-prop">QWidget::sizeHint</a>().</p>
<!-- @@@sizeHint -->
<!-- $$$topMargin[overload1]$$$topMargin -->
<h3 class="fn"><a name="topMargin"></a><span class="type">int</span> Q3ScrollView::<span class="name">topMargin</span> () const</h3>
<p>Returns the top margin.</p>
<p><b>See also </b><a href="q3scrollview.html#setMargins">setMargins</a>().</p>
<!-- @@@topMargin -->
<!-- $$$updateContents[overload1]$$$updateContentsintintintint -->
<h3 class="fn"><a name="updateContents"></a><span class="type">void</span> Q3ScrollView::<span class="name">updateContents</span> ( <span class="type">int</span> <i>x</i>, <span class="type">int</span> <i>y</i>, <span class="type">int</span> <i>w</i>, <span class="type">int</span> <i>h</i> )</h3>
<p>Calls <a href="qwidget.html#update">update</a>() on a rectangle defined by <i>x</i>, <i>y</i>, <i>w</i>, <i>h</i>, translated appropriately. If the rectangle is not visible, nothing is repainted.</p>
<p><b>See also </b><a href="q3scrollview.html#repaintContents">repaintContents</a>().</p>
<!-- @@@updateContents -->
<!-- $$$updateContents$$$updateContentsconstQRect& -->
<h3 class="fn"><a name="updateContents-2"></a><span class="type">void</span> Q3ScrollView::<span class="name">updateContents</span> ( const <span class="type"><a href="qrect.html">QRect</a></span> &amp; <i>r</i> )</h3>
<p>This is an overloaded function.</p>
<p>Updates the contents in rectangle <i>r</i></p>
<!-- @@@updateContents -->
<!-- $$$updateContents$$$updateContents -->
<h3 class="fn"><a name="updateContents-3"></a><span class="type">void</span> Q3ScrollView::<span class="name">updateContents</span> ()</h3>
<p>This is an overloaded function.</p>
<!-- @@@updateContents -->
<!-- $$$updateScrollBars[overload1]$$$updateScrollBars -->
<h3 class="fn"><a name="updateScrollBars"></a><span class="type">void</span> Q3ScrollView::<span class="name">updateScrollBars</span> ()<tt> [slot]</tt></h3>
<p>Updates scroll bars: all possibilities are considered. You should never need to call this in your code.</p>
<!-- @@@updateScrollBars -->
<!-- $$$verticalScrollBar[overload1]$$$verticalScrollBar -->
<h3 class="fn"><a name="verticalScrollBar"></a><span class="type"><a href="qscrollbar.html">QScrollBar</a></span> * Q3ScrollView::<span class="name">verticalScrollBar</span> () const</h3>
<p>Returns the component vertical scroll bar. It is made available to allow accelerators, autoscrolling, etc.</p>
<p>It should not be used for other purposes.</p>
<p>This function never returns 0.</p>
<!-- @@@verticalScrollBar -->
<!-- $$$verticalSliderPressed[overload1]$$$verticalSliderPressed -->
<h3 class="fn"><a name="verticalSliderPressed"></a><span class="type">void</span> Q3ScrollView::<span class="name">verticalSliderPressed</span> ()<tt> [signal]</tt></h3>
<p>This signal is emitted whenever the user presses the vertical slider.</p>
<!-- @@@verticalSliderPressed -->
<!-- $$$verticalSliderReleased[overload1]$$$verticalSliderReleased -->
<h3 class="fn"><a name="verticalSliderReleased"></a><span class="type">void</span> Q3ScrollView::<span class="name">verticalSliderReleased</span> ()<tt> [signal]</tt></h3>
<p>This signal is emitted whenever the user releases the vertical slider.</p>
<!-- @@@verticalSliderReleased -->
<!-- $$$viewport[overload1]$$$viewport -->
<h3 class="fn"><a name="viewport"></a><span class="type"><a href="qwidget.html">QWidget</a></span> * Q3ScrollView::<span class="name">viewport</span> () const</h3>
<p>Returns the viewport widget of the scrollview. This is the widget containing the contents widget or which is the drawing area.</p>
<!-- @@@viewport -->
<!-- $$$viewportPaintEvent[overload1]$$$viewportPaintEventQPaintEvent* -->
<h3 class="fn"><a name="viewportPaintEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">viewportPaintEvent</span> ( <span class="type"><a href="qpaintevent.html">QPaintEvent</a></span> * <i>pe</i> )<tt> [virtual protected]</tt></h3>
<p>This is a low-level painting routine that draws the viewport contents. Reimplement this if <a href="q3scrollview.html#drawContents">drawContents</a>() is too high-level (for example, if you don't want to open a <a href="qpainter.html">QPainter</a> on the viewport). The paint event is passed in <i>pe</i>.</p>
<!-- @@@viewportPaintEvent -->
<!-- $$$viewportResizeEvent[overload1]$$$viewportResizeEventQResizeEvent* -->
<h3 class="fn"><a name="viewportResizeEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">viewportResizeEvent</span> ( <span class="type"><a href="qresizeevent.html">QResizeEvent</a></span> * <i>event</i> )<tt> [virtual protected]</tt></h3>
<p>To provide simple processing of events on the contents, this function receives all resize events sent to the viewport.</p>
<p>The default implementation does nothing. The <i>event</i> parameter is ignored.</p>
<p><b>See also </b><a href="qwidget.html#resizeEvent">QWidget::resizeEvent</a>().</p>
<!-- @@@viewportResizeEvent -->
<!-- $$$viewportSize[overload1]$$$viewportSizeintint -->
<h3 class="fn"><a name="viewportSize"></a><span class="type"><a href="qsize.html">QSize</a></span> Q3ScrollView::<span class="name">viewportSize</span> ( <span class="type">int</span> <i>x</i>, <span class="type">int</span> <i>y</i> ) const</h3>
<p>Returns the viewport size for size (<i>x</i>, <i>y</i>).</p>
<p>The viewport size depends on (<i>x</i>, <i>y</i>) (the size of the contents), the size of this widget and the modes of the horizontal and vertical scroll bars.</p>
<p>This function permits widgets that can trade vertical and horizontal space for each other to control scroll bar appearance better. For example, a word processor or web browser can control the width of the right margin accurately, whether or not there needs to be a vertical scroll bar.</p>
<!-- @@@viewportSize -->
<!-- $$$viewportToContents[overload1]$$$viewportToContentsintintint&int& -->
<h3 class="fn"><a name="viewportToContents"></a><span class="type">void</span> Q3ScrollView::<span class="name">viewportToContents</span> ( <span class="type">int</span> <i>vx</i>, <span class="type">int</span> <i>vy</i>, <span class="type">int</span> &amp; <i>x</i>, <span class="type">int</span> &amp; <i>y</i> ) const</h3>
<p>Translates a point (<i>vx</i>, <i>vy</i>) on the <a href="q3scrollview.html#viewport">viewport</a>() widget to a point (<i>x</i>, <i>y</i>) in the contents.</p>
<!-- @@@viewportToContents -->
<!-- $$$viewportToContents$$$viewportToContentsconstQPoint& -->
<h3 class="fn"><a name="viewportToContents-2"></a><span class="type"><a href="qpoint.html">QPoint</a></span> Q3ScrollView::<span class="name">viewportToContents</span> ( const <span class="type"><a href="qpoint.html">QPoint</a></span> &amp; <i>vp</i> ) const</h3>
<p>This is an overloaded function.</p>
<p>Returns the point on the viewport <i>vp</i> translated to a point in the contents.</p>
<!-- @@@viewportToContents -->
<!-- $$$wheelEvent[overload1]$$$wheelEventQWheelEvent* -->
<h3 class="fn"><a name="wheelEvent"></a><span class="type">void</span> Q3ScrollView::<span class="name">wheelEvent</span> ( <span class="type"><a href="qwheelevent.html">QWheelEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#wheelEvent">QWidget::wheelEvent</a>().</p>
<!-- @@@wheelEvent -->
</div>
      </div>
    </div>
    </div> 
    <div class="ft">
      <span></span>
    </div>
  </div> 
  <div class="footer">
    <p>
      <acronym title="Copyright">&copy;</acronym> 2015 The Qt Company Ltd.
      Documentation contributions included herein are the copyrights of
      their respective owners.</p>
    <br />
    <p>
      The documentation provided herein is licensed under the terms of the
      <a href="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation
      License version 1.3</a> as published by the Free Software Foundation.</p>
    <p>
      Documentation sources may be obtained from <a href="http://www.qt-project.org">
      www.qt-project.org</a>.</p>
    <br />
    <p>
      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. <a title="Privacy Policy"
      href="http://en.gitorious.org/privacy_policy/">Privacy Policy</a></p>
  </div>

  <script src="scripts/functions.js" type="text/javascript"></script>
</body>
</html>