Sophie

Sophie

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

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" />
<!-- q3header.cpp -->
  <title>Qt 4.8: Q3Header 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>Q3Header</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="#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>
</ul>
</div>
<h1 class="title">Q3Header Class Reference</h1>
<!-- $$$Q3Header-brief -->
<p>The Q3Header class provides a header row or column, e.g&#x2e; for tables and listviews. <a href="#details">More...</a></p>
<!-- @@@Q3Header -->
<pre class="cpp"> <span class="preprocessor">#include &lt;Q3Header&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#qheader">Porting to Qt 4</a> for more information.</p>
<p><b>Inherits: </b><a href="qwidget.html">QWidget</a>.</p>
<ul>
<li><a href="q3header-members.html">List of all members, including inherited members</a></li>
</ul>
<a name="properties"></a>
<h2>Properties</h2>
<table class="propsummary">
<tr><td class="topAlign"><ul>
<li class="fn"><b><a href="q3header.html#count-prop">count</a></b> : const int</li>
<li class="fn"><b><a href="q3header.html#moving-prop">moving</a></b> : bool</li>
<li class="fn"><b><a href="q3header.html#offset-prop">offset</a></b> : int</li>
</ul></td><td class="topAlign"><ul>
<li class="fn"><b><a href="q3header.html#orientation-prop">orientation</a></b> : Qt::Orientation</li>
<li class="fn"><b><a href="q3header.html#stretching-prop">stretching</a></b> : bool</li>
<li class="fn"><b><a href="q3header.html#tracking-prop">tracking</a></b> : bool</li>
</ul>
</td></tr>
</table>
<ul>
<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="q3header.html#Q3Header">Q3Header</a></b> ( QWidget * <i>parent</i> = 0, const char * <i>name</i> = 0 )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#Q3Header-2">Q3Header</a></b> ( int <i>n</i>, QWidget * <i>parent</i> = 0, const char * <i>name</i> = 0 )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#dtor.Q3Header">~Q3Header</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#addLabel">addLabel</a></b> ( const QString &amp; <i>s</i>, int <i>size</i> = -1 )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#addLabel-2">addLabel</a></b> ( const QIcon &amp; <i>icon</i>, const QString &amp; <i>s</i>, int <i>size</i> = -1 )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#adjustHeaderSize">adjustHeaderSize</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#cellAt">cellAt</a></b> ( int <i>pos</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#cellPos">cellPos</a></b> ( int <i>i</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#cellSize">cellSize</a></b> ( int <i>i</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#count-prop">count</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#headerWidth">headerWidth</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QIcon * </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#iconSet">iconSet</a></b> ( int <i>section</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#isClickEnabled">isClickEnabled</a></b> ( int <i>section</i> = -1 ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#moving-prop">isMovingEnabled</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#isResizeEnabled">isResizeEnabled</a></b> ( int <i>section</i> = -1 ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#stretching-prop">isStretchEnabled</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#stretching-prop">isStretchEnabled</a></b> ( int <i>section</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QString </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#label">label</a></b> ( int <i>section</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#mapToActual">mapToActual</a></b> ( int <i>l</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#mapToIndex">mapToIndex</a></b> ( int <i>section</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#mapToLogical">mapToLogical</a></b> ( int <i>a</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#mapToSection">mapToSection</a></b> ( int <i>index</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#moveCell">moveCell</a></b> ( int <i>fromIdx</i>, int <i>toIdx</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#moveSection">moveSection</a></b> ( int <i>section</i>, int <i>toIndex</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#offset-prop">offset</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> Qt::Orientation </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#orientation-prop">orientation</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#removeLabel">removeLabel</a></b> ( int <i>section</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#resizeSection">resizeSection</a></b> ( int <i>section</i>, int <i>s</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#sectionAt">sectionAt</a></b> ( int <i>pos</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#sectionPos">sectionPos</a></b> ( int <i>section</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QRect </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#sectionRect">sectionRect</a></b> ( int <i>section</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#sectionSize">sectionSize</a></b> ( int <i>section</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#setCellSize">setCellSize</a></b> ( int <i>section</i>, int <i>s</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#setClickEnabled">setClickEnabled</a></b> ( bool <i>enable</i>, int <i>section</i> = -1 )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#setLabel">setLabel</a></b> ( int <i>section</i>, const QString &amp; <i>s</i>, int <i>size</i> = -1 )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#setLabel-2">setLabel</a></b> ( int <i>section</i>, const QIcon &amp; <i>icon</i>, const QString &amp; <i>s</i>, int <i>size</i> = -1 )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#moving-prop">setMovingEnabled</a></b> ( bool )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#orientation-prop">setOrientation</a></b> ( Qt::Orientation )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#setResizeEnabled">setResizeEnabled</a></b> ( bool <i>enable</i>, int <i>section</i> = -1 )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#setSortIndicator">setSortIndicator</a></b> ( int <i>section</i>, Qt::SortOrder <i>order</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#setSortIndicator-2">setSortIndicator</a></b> ( int <i>section</i>, bool <i>ascending</i> = true )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#stretching-prop">setStretchEnabled</a></b> ( bool <i>b</i>, int <i>section</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#stretching-prop">setStretchEnabled</a></b> ( bool <i>b</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#tracking-prop">setTracking</a></b> ( bool <i>enable</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> Qt::SortOrder </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#sortIndicatorOrder">sortIndicatorOrder</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#sortIndicatorSection">sortIndicatorSection</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#tracking-prop">tracking</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="q3header.html#sizeHint">sizeHint</a></b> () const</td></tr>
</table>
<ul>
<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"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#offset-prop">setOffset</a></b> ( int <i>pos</i> )</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="q3header.html#clicked">clicked</a></b> ( int <i>section</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#indexChange">indexChange</a></b> ( int <i>section</i>, int <i>fromIndex</i>, int <i>toIndex</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#moved">moved</a></b> ( int <i>fromIndex</i>, int <i>toIndex</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#pressed">pressed</a></b> ( int <i>section</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#released">released</a></b> ( int <i>section</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#sectionClicked">sectionClicked</a></b> ( int <i>index</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#sectionHandleDoubleClicked">sectionHandleDoubleClicked</a></b> ( int <i>section</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#sizeChange">sizeChange</a></b> ( int <i>section</i>, int <i>oldSize</i>, int <i>newSize</i> )</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="q3header.html#paintSection">paintSection</a></b> ( QPainter * <i>p</i>, int <i>index</i>, const QRect &amp; <i>fr</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#paintSectionLabel">paintSectionLabel</a></b> ( QPainter * <i>p</i>, int <i>index</i>, const QRect &amp; <i>fr</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QRect </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#sRect">sRect</a></b> ( int <i>index</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="q3header.html#changeEvent">changeEvent</a></b> ( QEvent * <i>ev</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#keyPressEvent">keyPressEvent</a></b> ( QKeyEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#keyReleaseEvent">keyReleaseEvent</a></b> ( QKeyEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.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="q3header.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="q3header.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="q3header.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="q3header.html#paintEvent">paintEvent</a></b> ( QPaintEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#resizeEvent">resizeEvent</a></b> ( QResizeEvent * <i>e</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3header.html#showEvent">showEvent</a></b> ( QShowEvent * <i>e</i> )</td></tr>
</table>
<ul>
<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>
<!-- $$$Q3Header-description -->
<div class="descr">
<h2>Detailed Description</h2>
<p>The Q3Header class provides a header row or column, e.g&#x2e; for tables and listviews.</p>
<p>This class provides a header, e.g&#x2e; a vertical header to display row labels, or a horizontal header to display column labels. It is used by <a href="q3table.html">Q3Table</a> and <a href="q3listview.html">Q3ListView</a> for example.</p>
<p>A header is composed of one or more <i>sections</i>, each of which can display a text label and an <a href="qicon.html">icon</a>. A sort indicator (an arrow) can also be displayed using <a href="q3header.html#setSortIndicator">setSortIndicator</a>().</p>
<p>Sections are added with <a href="q3header.html#addLabel">addLabel</a>() and removed with <a href="q3header.html#removeLabel">removeLabel</a>(). The label and icon are set in <a href="q3header.html#addLabel">addLabel</a>() and can be changed later with <a href="q3header.html#setLabel">setLabel</a>(). Use <a href="q3header.html#count-prop">count</a>() to retrieve the number of sections in the header.</p>
<p>The orientation of the header is set with <a href="q3header.html#orientation-prop">setOrientation</a>(). If <a href="q3header.html#stretching-prop">setStretchEnabled</a>() is true, the sections will expand to take up the full width (height for vertical headers) of the header. The user can resize the sections manually if <a href="q3header.html#setResizeEnabled">setResizeEnabled</a>() is true. Call <a href="q3header.html#adjustHeaderSize">adjustHeaderSize</a>() to have the sections resize to occupy the full width (or height).</p>
<p>A section can be moved with <a href="q3header.html#moveSection">moveSection</a>(). If <a href="q3header.html#moving-prop">setMovingEnabled</a>() is true (the default)the user may drag a section from one position to another. If a section is moved, the index positions at which sections were added (with <a href="q3header.html#addLabel">addLabel</a>()), may not be the same after the move. You don't have to worry about this in practice because the Q3Header API works in terms of section numbers, so it doesn't matter where a particular section has been moved to.</p>
<p>If you want the current index position of a section call <a href="q3header.html#mapToIndex">mapToIndex</a>() giving it the section number. (This is the number returned by the <a href="q3header.html#addLabel">addLabel</a>() call which created the section.) If you want to get the section number of a section at a particular index position call <a href="q3header.html#mapToSection">mapToSection</a>() giving it the index number.</p>
<p>Here's an example to clarify <a href="q3header.html#mapToSection">mapToSection</a>() and <a href="q3header.html#mapToIndex">mapToIndex</a>():</p>
<table class="generic">
<thead><tr class="qt-style"><th  colspan="4">Index positions</th></tr></thead>
<tr valign="top" class="odd"><td >0</td><td >1</td><td >2</td><td >3</td></tr>
<thead><tr class="qt-style"><th  colspan="4">Original section ordering</th></tr></thead>
<tr valign="top" class="even"><td >Sect 0</td><td >Sect 1</td><td >Sect 2</td><td >Sect 3</td></tr>
<thead><tr class="qt-style"><th  colspan="4">Ordering after the user moves a section</th></tr></thead>
<tr valign="top" class="odd"><td >Sect 0</td><td >Sect 2</td><td >Sect 3</td><td >Sect 1</td></tr>
</table>
<table class="generic">
<thead><tr class="qt-style"><th ><i>k</i></th><th >mapToSection(<i>k</i>)</th><th >mapToIndex(<i>k</i>)</th></tr></thead>
<tr valign="top" class="odd"><td >0</td><td >0</td><td >0</td></tr>
<tr valign="top" class="even"><td >1</td><td >2</td><td >3</td></tr>
<tr valign="top" class="odd"><td >2</td><td >3</td><td >1</td></tr>
<tr valign="top" class="even"><td >3</td><td >1</td><td >2</td></tr>
</table>
<p>In the example above, if we wanted to find out which section is at index position 3 we'd call mapToSection(3) and get a section number of 1 since section 1 was moved. Similarly, if we wanted to know which index position section 2 occupied we'd call mapToIndex(2) and get an index of 1.</p>
<p>Q3Header provides the <a href="q3header.html#clicked">clicked</a>(), <a href="q3header.html#pressed">pressed</a>() and <a href="q3header.html#released">released</a>() signals. If the user changes the size of a section, the <a href="q3header.html#sizeChange">sizeChange</a>() signal is emitted. If you want to have a <a href="q3header.html#sizeChange">sizeChange</a>() signal emitted continuously whilst the user is resizing (rather than just after the resizing is finished), use <a href="q3header.html#tracking-prop">setTracking</a>(). If the user moves a section the <a href="q3header.html#indexChange">indexChange</a>() signal is emitted.</p>
</div>
<p><b>See also </b><a href="q3listview.html">Q3ListView</a> and <a href="q3table.html">Q3Table</a>.</p>
<!-- @@@Q3Header -->
<div class="prop">
<h2>Property Documentation</h2>
<!-- $$$count-prop$$$count -->
<h3 class="fn"><a name="count-prop"></a><span class="name">count</span> : const <span class="type">int</span></h3>
<p>This property holds the number of sections in the header.</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>count</b></span> () const</td></tr>
</table>
<!-- @@@count -->
<!-- $$$moving-prop$$$isMovingEnabled$$$setMovingEnabledbool -->
<h3 class="fn"><a name="moving-prop"></a><span class="name">moving</span> : <span class="type">bool</span></h3>
<p>This property holds whether the header sections can be moved.</p>
<p>If this property is true (the default) the user can move sections. If the user moves a section the <a href="q3header.html#indexChange">indexChange</a>() signal is emitted.</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>isMovingEnabled</b></span> () const</td></tr>
<tr><td class="memItemLeft topAlign rightAlign"> virtual void </td><td class="memItemRight bottomAlign"><span class="name"><b>setMovingEnabled</b></span> ( bool )</td></tr>
</table>
<p><b>See also </b><a href="q3header.html#setClickEnabled">setClickEnabled</a>() and <a href="q3header.html#setResizeEnabled">setResizeEnabled</a>().</p>
<!-- @@@moving -->
<!-- $$$offset-prop$$$offset$$$setOffsetint -->
<h3 class="fn"><a name="offset-prop"></a><span class="name">offset</span> : <span class="type">int</span></h3>
<p>This property holds the header's left-most (or top-most) visible pixel.</p>
<p>Setting this property will scroll the header so that <i>offset</i> becomes the left-most (or top-most for vertical headers) visible pixel.</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>offset</b></span> () const</td></tr>
<tr><td class="memItemLeft topAlign rightAlign"> virtual void </td><td class="memItemRight bottomAlign"><span class="name"><b>setOffset</b></span> ( int <i>pos</i> )</td></tr>
</table>
<!-- @@@offset -->
<!-- $$$orientation-prop$$$orientation$$$setOrientationQt::Orientation -->
<h3 class="fn"><a name="orientation-prop"></a><span class="name">orientation</span> : <span class="type"><a href="qt.html#Orientation-enum">Qt::Orientation</a></span></h3>
<p>This property holds the header's orientation.</p>
<p>The orientation is either <a href="qt.html#Orientation-enum">Qt::Vertical</a> or <a href="qt.html#Orientation-enum">Qt::Horizontal</a> (the default).</p>
<p>Call setOrientation() before adding labels if you don't provide a size parameter otherwise the sizes will be incorrect.</p>
<p><b>Access functions:</b></p>
<table class="alignedsummary">
<tr><td class="memItemLeft topAlign rightAlign"> Qt::Orientation </td><td class="memItemRight bottomAlign"><span class="name"><b>orientation</b></span> () const</td></tr>
<tr><td class="memItemLeft topAlign rightAlign"> virtual void </td><td class="memItemRight bottomAlign"><span class="name"><b>setOrientation</b></span> ( Qt::Orientation )</td></tr>
</table>
<!-- @@@orientation -->
<!-- $$$stretching-prop$$$isStretchEnabled$$$isStretchEnabledint$$$setStretchEnabledboolint$$$setStretchEnabledbool -->
<h3 class="fn"><a name="stretching-prop"></a><span class="name">stretching</span> : <span class="type">bool</span></h3>
<p>This property holds whether the header sections always take up the full width (or height) of the header.</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>isStretchEnabled</b></span> () const</td></tr>
<tr><td class="memItemLeft topAlign rightAlign"> bool </td><td class="memItemRight bottomAlign"><span class="name"><b>isStretchEnabled</b></span> ( int <i>section</i> ) const</td></tr>
<tr><td class="memItemLeft topAlign rightAlign"> virtual void </td><td class="memItemRight bottomAlign"><span class="name"><b>setStretchEnabled</b></span> ( bool <i>b</i>, int <i>section</i> )</td></tr>
<tr><td class="memItemLeft topAlign rightAlign"> void </td><td class="memItemRight bottomAlign"><span class="name"><b>setStretchEnabled</b></span> ( bool <i>b</i> )</td></tr>
</table>
<!-- @@@stretching -->
<!-- $$$tracking-prop$$$tracking$$$setTrackingbool -->
<h3 class="fn"><a name="tracking-prop"></a><span class="name">tracking</span> : <span class="type">bool</span></h3>
<p>This property holds whether the sizeChange() signal is emitted continuously.</p>
<p>If tracking is on, the <a href="q3header.html#sizeChange">sizeChange</a>() signal is emitted continuously while the mouse is moved (i.e&#x2e; when the header is resized), otherwise it is only emitted when the mouse button is released at the end of resizing.</p>
<p>Tracking defaults to false.</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>tracking</b></span> () const</td></tr>
<tr><td class="memItemLeft topAlign rightAlign"> virtual void </td><td class="memItemRight bottomAlign"><span class="name"><b>setTracking</b></span> ( bool <i>enable</i> )</td></tr>
</table>
<!-- @@@tracking -->
</div>
<div class="func">
<h2>Member Function Documentation</h2>
<!-- $$$Q3Header[overload1]$$$Q3HeaderQWidget*constchar* -->
<h3 class="fn"><a name="Q3Header"></a>Q3Header::<span class="name">Q3Header</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 )</h3>
<p>Constructs a horizontal header called <i>name</i>, with parent <i>parent</i>.</p>
<!-- @@@Q3Header -->
<!-- $$$Q3Header$$$Q3HeaderintQWidget*constchar* -->
<h3 class="fn"><a name="Q3Header-2"></a>Q3Header::<span class="name">Q3Header</span> ( <span class="type">int</span> <i>n</i>, <span class="type"><a href="qwidget.html">QWidget</a></span> * <i>parent</i> = 0, const <span class="type">char</span> * <i>name</i> = 0 )</h3>
<p>Constructs a horizontal header called <i>name</i>, with <i>n</i> sections and parent <i>parent</i>.</p>
<!-- @@@Q3Header -->
<!-- $$$~Q3Header[overload1]$$$~Q3Header -->
<h3 class="fn"><a name="dtor.Q3Header"></a>Q3Header::<span class="name">~Q3Header</span> ()</h3>
<p>Destroys the header and all its sections.</p>
<!-- @@@~Q3Header -->
<!-- $$$addLabel[overload1]$$$addLabelconstQString&int -->
<h3 class="fn"><a name="addLabel"></a><span class="type">int</span> Q3Header::<span class="name">addLabel</span> ( const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>s</i>, <span class="type">int</span> <i>size</i> = -1 )</h3>
<p>Adds a new section with label text <i>s</i>. Returns the index position where the section was added (at the right for horizontal headers, at the bottom for vertical headers). The section's width is set to <i>size</i>. If <i>size</i> &lt; 0, an appropriate size for the text <i>s</i> is chosen.</p>
<!-- @@@addLabel -->
<!-- $$$addLabel$$$addLabelconstQIcon&constQString&int -->
<h3 class="fn"><a name="addLabel-2"></a><span class="type">int</span> Q3Header::<span class="name">addLabel</span> ( const <span class="type"><a href="qicon.html">QIcon</a></span> &amp; <i>icon</i>, const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>s</i>, <span class="type">int</span> <i>size</i> = -1 )</h3>
<p>This is an overloaded function.</p>
<p>Adds a new section with icon <i>icon</i> and label text <i>s</i>. Returns the index position where the section was added (at the right for horizontal headers, at the bottom for vertical headers). The section's width is set to <i>size</i>, unless size is negative in which case the size is calculated taking account of the size of the text.</p>
<!-- @@@addLabel -->
<!-- $$$adjustHeaderSize[overload1]$$$adjustHeaderSize -->
<h3 class="fn"><a name="adjustHeaderSize"></a><span class="type">void</span> Q3Header::<span class="name">adjustHeaderSize</span> ()</h3>
<p>Adjusts the size of the sections to fit the size of the header as completely as possible. Only sections for which <a href="q3header.html#stretching-prop">isStretchEnabled</a>() is true will be resized.</p>
<!-- @@@adjustHeaderSize -->
<!-- $$$cellAt[overload1]$$$cellAtint -->
<h3 class="fn"><a name="cellAt"></a><span class="type">int</span> Q3Header::<span class="name">cellAt</span> ( <span class="type">int</span> <i>pos</i> ) const</h3>
<p>Use <a href="q3header.html#sectionAt">sectionAt</a>() instead.</p>
<p>Returns the index at which the section is displayed, which contains <i>pos</i> in widget coordinates, or -1 if <i>pos</i> is outside the header sections.</p>
<!-- @@@cellAt -->
<!-- $$$cellPos[overload1]$$$cellPosint -->
<h3 class="fn"><a name="cellPos"></a><span class="type">int</span> Q3Header::<span class="name">cellPos</span> ( <span class="type">int</span> <i>i</i> ) const</h3>
<p>Use <a href="q3header.html#sectionPos">sectionPos</a>() instead.</p>
<p>Returns the position in pixels of the section that is displayed at the index <i>i</i>. The position is measured from the start of the header.</p>
<!-- @@@cellPos -->
<!-- $$$cellSize[overload1]$$$cellSizeint -->
<h3 class="fn"><a name="cellSize"></a><span class="type">int</span> Q3Header::<span class="name">cellSize</span> ( <span class="type">int</span> <i>i</i> ) const</h3>
<p>Use <a href="q3header.html#sectionSize">sectionSize</a>() instead.</p>
<p>Returns the size in pixels of the section that is displayed at the index <i>i</i>.</p>
<p><b>See also </b><a href="q3header.html#setCellSize">setCellSize</a>().</p>
<!-- @@@cellSize -->
<!-- $$$changeEvent[overload1]$$$changeEventQEvent* -->
<h3 class="fn"><a name="changeEvent"></a><span class="type">void</span> Q3Header::<span class="name">changeEvent</span> ( <span class="type"><a href="qevent.html">QEvent</a></span> * <i>ev</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#changeEvent">QWidget::changeEvent</a>().</p>
<!-- @@@changeEvent -->
<!-- $$$clicked[overload1]$$$clickedint -->
<h3 class="fn"><a name="clicked"></a><span class="type">void</span> Q3Header::<span class="name">clicked</span> ( <span class="type">int</span> <i>section</i> )<tt> [signal]</tt></h3>
<p>If <a href="q3header.html#isClickEnabled">isClickEnabled</a>() is true, this signal is emitted when the user clicks section <i>section</i>.</p>
<p><b>See also </b><a href="q3header.html#pressed">pressed</a>() and <a href="q3header.html#released">released</a>().</p>
<!-- @@@clicked -->
<!-- $$$headerWidth[overload1]$$$headerWidth -->
<h3 class="fn"><a name="headerWidth"></a><span class="type">int</span> Q3Header::<span class="name">headerWidth</span> () const</h3>
<p>Returns the total width of all the header columns.</p>
<!-- @@@headerWidth -->
<!-- $$$iconSet[overload1]$$$iconSetint -->
<h3 class="fn"><a name="iconSet"></a><span class="type"><a href="qicon.html">QIcon</a></span> * Q3Header::<span class="name">iconSet</span> ( <span class="type">int</span> <i>section</i> ) const</h3>
<p>Returns the icon set for section <i>section</i>. If the section does not exist, 0 is returned.</p>
<!-- @@@iconSet -->
<!-- $$$indexChange[overload1]$$$indexChangeintintint -->
<h3 class="fn"><a name="indexChange"></a><span class="type">void</span> Q3Header::<span class="name">indexChange</span> ( <span class="type">int</span> <i>section</i>, <span class="type">int</span> <i>fromIndex</i>, <span class="type">int</span> <i>toIndex</i> )<tt> [signal]</tt></h3>
<p>This signal is emitted when the user moves section <i>section</i> from index position <i>fromIndex</i>, to index position <i>toIndex</i>.</p>
<!-- @@@indexChange -->
<!-- $$$isClickEnabled[overload1]$$$isClickEnabledint -->
<h3 class="fn"><a name="isClickEnabled"></a><span class="type">bool</span> Q3Header::<span class="name">isClickEnabled</span> ( <span class="type">int</span> <i>section</i> = -1 ) const</h3>
<p>Returns true if section <i>section</i> is clickable; otherwise returns false.</p>
<p>If <i>section</i> is out of range (negative or larger than <a href="q3header.html#count-prop">count</a>() - 1): returns true if all sections are clickable; otherwise returns false.</p>
<p><b>See also </b><a href="q3header.html#setClickEnabled">setClickEnabled</a>().</p>
<!-- @@@isClickEnabled -->
<!-- $$$isResizeEnabled[overload1]$$$isResizeEnabledint -->
<h3 class="fn"><a name="isResizeEnabled"></a><span class="type">bool</span> Q3Header::<span class="name">isResizeEnabled</span> ( <span class="type">int</span> <i>section</i> = -1 ) const</h3>
<p>Returns true if section <i>section</i> is resizeable; otherwise returns false.</p>
<p>If <i>section</i> is -1 then this function applies to all sections, i.e&#x2e; returns true if all sections are resizeable; otherwise returns false.</p>
<p><b>See also </b><a href="q3header.html#setResizeEnabled">setResizeEnabled</a>().</p>
<!-- @@@isResizeEnabled -->
<!-- $$$keyPressEvent[overload1]$$$keyPressEventQKeyEvent* -->
<h3 class="fn"><a name="keyPressEvent"></a><span class="type">void</span> Q3Header::<span class="name">keyPressEvent</span> ( <span class="type"><a href="qkeyevent.html">QKeyEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#keyPressEvent">QWidget::keyPressEvent</a>().</p>
<!-- @@@keyPressEvent -->
<!-- $$$keyReleaseEvent[overload1]$$$keyReleaseEventQKeyEvent* -->
<h3 class="fn"><a name="keyReleaseEvent"></a><span class="type">void</span> Q3Header::<span class="name">keyReleaseEvent</span> ( <span class="type"><a href="qkeyevent.html">QKeyEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#keyReleaseEvent">QWidget::keyReleaseEvent</a>().</p>
<!-- @@@keyReleaseEvent -->
<!-- $$$label[overload1]$$$labelint -->
<h3 class="fn"><a name="label"></a><span class="type"><a href="qstring.html">QString</a></span> Q3Header::<span class="name">label</span> ( <span class="type">int</span> <i>section</i> ) const</h3>
<p>Returns the text for section <i>section</i>. If the section does not exist, returns an empty string.</p>
<p><b>See also </b><a href="q3header.html#setLabel">setLabel</a>().</p>
<!-- @@@label -->
<!-- $$$mapToActual[overload1]$$$mapToActualint -->
<h3 class="fn"><a name="mapToActual"></a><span class="type">int</span> Q3Header::<span class="name">mapToActual</span> ( <span class="type">int</span> <i>l</i> ) const</h3>
<p>Use <a href="q3header.html#mapToIndex">mapToIndex</a>() instead.</p>
<p>Translates from logical index <i>l</i> to actual index (index at which the section <i>l</i> is displayed) . Returns -1 if <i>l</i> is outside the legal range.</p>
<p><b>See also </b><a href="q3header.html#mapToLogical">mapToLogical</a>().</p>
<!-- @@@mapToActual -->
<!-- $$$mapToIndex[overload1]$$$mapToIndexint -->
<h3 class="fn"><a name="mapToIndex"></a><span class="type">int</span> Q3Header::<span class="name">mapToIndex</span> ( <span class="type">int</span> <i>section</i> ) const</h3>
<p>Returns the index position at which section <i>section</i> is displayed.</p>
<!-- @@@mapToIndex -->
<!-- $$$mapToLogical[overload1]$$$mapToLogicalint -->
<h3 class="fn"><a name="mapToLogical"></a><span class="type">int</span> Q3Header::<span class="name">mapToLogical</span> ( <span class="type">int</span> <i>a</i> ) const</h3>
<p>Use <a href="q3header.html#mapToSection">mapToSection</a>() instead.</p>
<p>Translates from actual index <i>a</i> (index at which the section is displayed) to logical index of the section. Returns -1 if <i>a</i> is outside the legal range.</p>
<p><b>See also </b><a href="q3header.html#mapToActual">mapToActual</a>().</p>
<!-- @@@mapToLogical -->
<!-- $$$mapToSection[overload1]$$$mapToSectionint -->
<h3 class="fn"><a name="mapToSection"></a><span class="type">int</span> Q3Header::<span class="name">mapToSection</span> ( <span class="type">int</span> <i>index</i> ) const</h3>
<p>Returns the number of the section that is displayed at index position <i>index</i>.</p>
<!-- @@@mapToSection -->
<!-- $$$mouseDoubleClickEvent[overload1]$$$mouseDoubleClickEventQMouseEvent* -->
<h3 class="fn"><a name="mouseDoubleClickEvent"></a><span class="type">void</span> Q3Header::<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> Q3Header::<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> Q3Header::<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> Q3Header::<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 -->
<!-- $$$moveCell[overload1]$$$moveCellintint -->
<h3 class="fn"><a name="moveCell"></a><span class="type">void</span> Q3Header::<span class="name">moveCell</span> ( <span class="type">int</span> <i>fromIdx</i>, <span class="type">int</span> <i>toIdx</i> )<tt> [virtual]</tt></h3>
<p>Use <a href="q3header.html#moveSection">moveSection</a>() instead.</p>
<p>Moves the section that is currently displayed at index <i>fromIdx</i> to index <i>toIdx</i>.</p>
<!-- @@@moveCell -->
<!-- $$$moveSection[overload1]$$$moveSectionintint -->
<h3 class="fn"><a name="moveSection"></a><span class="type">void</span> Q3Header::<span class="name">moveSection</span> ( <span class="type">int</span> <i>section</i>, <span class="type">int</span> <i>toIndex</i> )</h3>
<p>Moves section <i>section</i> to index position <i>toIndex</i>.</p>
<!-- @@@moveSection -->
<!-- $$$moved[overload1]$$$movedintint -->
<h3 class="fn"><a name="moved"></a><span class="type">void</span> Q3Header::<span class="name">moved</span> ( <span class="type">int</span> <i>fromIndex</i>, <span class="type">int</span> <i>toIndex</i> )<tt> [signal]</tt></h3>
<p>Use <a href="q3header.html#indexChange">indexChange</a>() instead.</p>
<p>This signal is emitted when the user has moved the section which is displayed at the index <i>fromIndex</i> to the index <i>toIndex</i>.</p>
<!-- @@@moved -->
<!-- $$$paintEvent[overload1]$$$paintEventQPaintEvent* -->
<h3 class="fn"><a name="paintEvent"></a><span class="type">void</span> Q3Header::<span class="name">paintEvent</span> ( <span class="type"><a href="qpaintevent.html">QPaintEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#paintEvent">QWidget::paintEvent</a>().</p>
<!-- @@@paintEvent -->
<!-- $$$paintSection[overload1]$$$paintSectionQPainter*intconstQRect& -->
<h3 class="fn"><a name="paintSection"></a><span class="type">void</span> Q3Header::<span class="name">paintSection</span> ( <span class="type"><a href="qpainter.html">QPainter</a></span> * <i>p</i>, <span class="type">int</span> <i>index</i>, const <span class="type"><a href="qrect.html">QRect</a></span> &amp; <i>fr</i> )<tt> [virtual protected]</tt></h3>
<p>Paints the section at position <i>index</i>, inside rectangle <i>fr</i> (which uses widget coordinates) using painter <i>p</i>.</p>
<p>Calls <a href="q3header.html#paintSectionLabel">paintSectionLabel</a>().</p>
<!-- @@@paintSection -->
<!-- $$$paintSectionLabel[overload1]$$$paintSectionLabelQPainter*intconstQRect& -->
<h3 class="fn"><a name="paintSectionLabel"></a><span class="type">void</span> Q3Header::<span class="name">paintSectionLabel</span> ( <span class="type"><a href="qpainter.html">QPainter</a></span> * <i>p</i>, <span class="type">int</span> <i>index</i>, const <span class="type"><a href="qrect.html">QRect</a></span> &amp; <i>fr</i> )<tt> [virtual protected]</tt></h3>
<p>Paints the label of the section at position <i>index</i>, inside rectangle <i>fr</i> (which uses widget coordinates) using painter <i>p</i>.</p>
<p>Called by <a href="q3header.html#paintSection">paintSection</a>()</p>
<!-- @@@paintSectionLabel -->
<!-- $$$pressed[overload1]$$$pressedint -->
<h3 class="fn"><a name="pressed"></a><span class="type">void</span> Q3Header::<span class="name">pressed</span> ( <span class="type">int</span> <i>section</i> )<tt> [signal]</tt></h3>
<p>This signal is emitted when the user presses section <i>section</i> down.</p>
<p><b>See also </b><a href="q3header.html#released">released</a>().</p>
<!-- @@@pressed -->
<!-- $$$released[overload1]$$$releasedint -->
<h3 class="fn"><a name="released"></a><span class="type">void</span> Q3Header::<span class="name">released</span> ( <span class="type">int</span> <i>section</i> )<tt> [signal]</tt></h3>
<p>This signal is emitted when section <i>section</i> is released.</p>
<p><b>See also </b><a href="q3header.html#pressed">pressed</a>().</p>
<!-- @@@released -->
<!-- $$$removeLabel[overload1]$$$removeLabelint -->
<h3 class="fn"><a name="removeLabel"></a><span class="type">void</span> Q3Header::<span class="name">removeLabel</span> ( <span class="type">int</span> <i>section</i> )</h3>
<p>Removes section <i>section</i>. If the section does not exist, nothing happens.</p>
<!-- @@@removeLabel -->
<!-- $$$resizeEvent[overload1]$$$resizeEventQResizeEvent* -->
<h3 class="fn"><a name="resizeEvent"></a><span class="type">void</span> Q3Header::<span class="name">resizeEvent</span> ( <span class="type"><a href="qresizeevent.html">QResizeEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#resizeEvent">QWidget::resizeEvent</a>().</p>
<!-- @@@resizeEvent -->
<!-- $$$resizeSection[overload1]$$$resizeSectionintint -->
<h3 class="fn"><a name="resizeSection"></a><span class="type">void</span> Q3Header::<span class="name">resizeSection</span> ( <span class="type">int</span> <i>section</i>, <span class="type">int</span> <i>s</i> )</h3>
<p>Resizes section <i>section</i> to <i>s</i> pixels wide (or high).</p>
<!-- @@@resizeSection -->
<!-- $$$sRect[overload1]$$$sRectint -->
<h3 class="fn"><a name="sRect"></a><span class="type"><a href="qrect.html">QRect</a></span> Q3Header::<span class="name">sRect</span> ( <span class="type">int</span> <i>index</i> )<tt> [protected]</tt></h3>
<p>Returns the rectangle covered by the section at index <i>index</i>.</p>
<!-- @@@sRect -->
<!-- $$$sectionAt[overload1]$$$sectionAtint -->
<h3 class="fn"><a name="sectionAt"></a><span class="type">int</span> Q3Header::<span class="name">sectionAt</span> ( <span class="type">int</span> <i>pos</i> ) const</h3>
<p>Returns the index of the section which contains the position <i>pos</i> given in pixels from the left (or top).</p>
<p><b>See also </b><a href="q3header.html#offset-prop">offset</a>().</p>
<!-- @@@sectionAt -->
<!-- $$$sectionClicked[overload1]$$$sectionClickedint -->
<h3 class="fn"><a name="sectionClicked"></a><span class="type">void</span> Q3Header::<span class="name">sectionClicked</span> ( <span class="type">int</span> <i>index</i> )<tt> [signal]</tt></h3>
<p>Use <a href="q3header.html#clicked">clicked</a>() instead.</p>
<p>This signal is emitted when a part of the header is clicked. <i>index</i> is the index at which the section is displayed.</p>
<p>In a list view this signal would typically be connected to a slot that sorts the specified column (or row).</p>
<!-- @@@sectionClicked -->
<!-- $$$sectionHandleDoubleClicked[overload1]$$$sectionHandleDoubleClickedint -->
<h3 class="fn"><a name="sectionHandleDoubleClicked"></a><span class="type">void</span> Q3Header::<span class="name">sectionHandleDoubleClicked</span> ( <span class="type">int</span> <i>section</i> )<tt> [signal]</tt></h3>
<p>This signal is emitted when the user doubleclicks on the edge (handle) of section <i>section</i>.</p>
<!-- @@@sectionHandleDoubleClicked -->
<!-- $$$sectionPos[overload1]$$$sectionPosint -->
<h3 class="fn"><a name="sectionPos"></a><span class="type">int</span> Q3Header::<span class="name">sectionPos</span> ( <span class="type">int</span> <i>section</i> ) const</h3>
<p>Returns the position (in pixels) at which the <i>section</i> starts.</p>
<p><b>See also </b><a href="q3header.html#offset-prop">offset</a>().</p>
<!-- @@@sectionPos -->
<!-- $$$sectionRect[overload1]$$$sectionRectint -->
<h3 class="fn"><a name="sectionRect"></a><span class="type"><a href="qrect.html">QRect</a></span> Q3Header::<span class="name">sectionRect</span> ( <span class="type">int</span> <i>section</i> ) const</h3>
<p>Returns the rectangle covered by section <i>section</i>.</p>
<!-- @@@sectionRect -->
<!-- $$$sectionSize[overload1]$$$sectionSizeint -->
<h3 class="fn"><a name="sectionSize"></a><span class="type">int</span> Q3Header::<span class="name">sectionSize</span> ( <span class="type">int</span> <i>section</i> ) const</h3>
<p>Returns the width (or height) of the <i>section</i> in pixels.</p>
<!-- @@@sectionSize -->
<!-- $$$setCellSize[overload1]$$$setCellSizeintint -->
<h3 class="fn"><a name="setCellSize"></a><span class="type">void</span> Q3Header::<span class="name">setCellSize</span> ( <span class="type">int</span> <i>section</i>, <span class="type">int</span> <i>s</i> )<tt> [virtual]</tt></h3>
<p>Use <a href="q3header.html#resizeSection">resizeSection</a>() instead.</p>
<p>Sets the size of the section <i>section</i> to <i>s</i> pixels.</p>
<p><b>Warning:</b> does not repaint or send out signals</p>
<p><b>See also </b><a href="q3header.html#cellSize">cellSize</a>().</p>
<!-- @@@setCellSize -->
<!-- $$$setClickEnabled[overload1]$$$setClickEnabledboolint -->
<h3 class="fn"><a name="setClickEnabled"></a><span class="type">void</span> Q3Header::<span class="name">setClickEnabled</span> ( <span class="type">bool</span> <i>enable</i>, <span class="type">int</span> <i>section</i> = -1 )<tt> [virtual]</tt></h3>
<p>If <i>enable</i> is true, any clicks on section <i>section</i> will result in <a href="q3header.html#clicked">clicked</a>() signals being emitted; otherwise the section will ignore clicks.</p>
<p>If <i>section</i> is -1 (the default) then the <i>enable</i> value is set for all existing sections and will be applied to any new sections that are added.</p>
<p><b>See also </b><a href="q3header.html#isClickEnabled">isClickEnabled</a>(), <a href="q3header.html#moving-prop">setMovingEnabled</a>(), and <a href="q3header.html#setResizeEnabled">setResizeEnabled</a>().</p>
<!-- @@@setClickEnabled -->
<!-- $$$setLabel[overload1]$$$setLabelintconstQString&int -->
<h3 class="fn"><a name="setLabel"></a><span class="type">void</span> Q3Header::<span class="name">setLabel</span> ( <span class="type">int</span> <i>section</i>, const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>s</i>, <span class="type">int</span> <i>size</i> = -1 )<tt> [virtual]</tt></h3>
<p>Sets the text of section <i>section</i> to <i>s</i>. The section's width is set to <i>size</i> if <i>size</i> &gt;= 0; otherwise it is left unchanged. Any icon set that has been set for this section remains unchanged.</p>
<p>If the section does not exist, nothing happens.</p>
<p><b>See also </b><a href="q3header.html#label">label</a>().</p>
<!-- @@@setLabel -->
<!-- $$$setLabel$$$setLabelintconstQIcon&constQString&int -->
<h3 class="fn"><a name="setLabel-2"></a><span class="type">void</span> Q3Header::<span class="name">setLabel</span> ( <span class="type">int</span> <i>section</i>, const <span class="type"><a href="qicon.html">QIcon</a></span> &amp; <i>icon</i>, const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>s</i>, <span class="type">int</span> <i>size</i> = -1 )<tt> [virtual]</tt></h3>
<p>This is an overloaded function.</p>
<p>Sets the icon for section <i>section</i> to <i>icon</i> and the text to <i>s</i>. The section's width is set to <i>size</i> if <i>size</i> &gt;= 0; otherwise it is left unchanged.</p>
<p>If the section does not exist, nothing happens.</p>
<!-- @@@setLabel -->
<!-- $$$setResizeEnabled[overload1]$$$setResizeEnabledboolint -->
<h3 class="fn"><a name="setResizeEnabled"></a><span class="type">void</span> Q3Header::<span class="name">setResizeEnabled</span> ( <span class="type">bool</span> <i>enable</i>, <span class="type">int</span> <i>section</i> = -1 )<tt> [virtual]</tt></h3>
<p>If <i>enable</i> is true the user may resize section <i>section</i>; otherwise the section may not be manually resized.</p>
<p>If <i>section</i> is negative (the default) then the <i>enable</i> value is set for all existing sections and will be applied to any new sections that are added. Example:</p>
<pre class="cpp"> <span class="comment">// Allow resizing of all current and future sections</span>
 header<span class="operator">-</span><span class="operator">&gt;</span>setResizeEnabled(<span class="keyword">true</span>);
 <span class="comment">// Disable resizing of section 3, (the fourth section added)</span>
 header<span class="operator">-</span><span class="operator">&gt;</span>setResizeEnabled(<span class="keyword">false</span><span class="operator">,</span> <span class="number">3</span>);</pre>
<p>If the user resizes a section, a <a href="q3header.html#sizeChange">sizeChange</a>() signal is emitted.</p>
<p><b>See also </b><a href="q3header.html#isResizeEnabled">isResizeEnabled</a>(), <a href="q3header.html#moving-prop">setMovingEnabled</a>(), <a href="q3header.html#setClickEnabled">setClickEnabled</a>(), and <a href="q3header.html#tracking-prop">setTracking</a>().</p>
<!-- @@@setResizeEnabled -->
<!-- $$$setSortIndicator[overload1]$$$setSortIndicatorintQt::SortOrder -->
<h3 class="fn"><a name="setSortIndicator"></a><span class="type">void</span> Q3Header::<span class="name">setSortIndicator</span> ( <span class="type">int</span> <i>section</i>, <span class="type"><a href="qt.html#SortOrder-enum">Qt::SortOrder</a></span> <i>order</i> )</h3>
<p>Sets a sort indicator onto the specified <i>section</i>. The indicator's <i>order</i> is either Ascending or Descending.</p>
<p>Only one section can show a sort indicator at any one time. If you don't want any section to show a sort indicator pass a <i>section</i> number of -1.</p>
<p><b>See also </b><a href="q3header.html#sortIndicatorSection">sortIndicatorSection</a>() and <a href="q3header.html#sortIndicatorOrder">sortIndicatorOrder</a>().</p>
<!-- @@@setSortIndicator -->
<!-- $$$setSortIndicator$$$setSortIndicatorintbool -->
<h3 class="fn"><a name="setSortIndicator-2"></a><span class="type">void</span> Q3Header::<span class="name">setSortIndicator</span> ( <span class="type">int</span> <i>section</i>, <span class="type">bool</span> <i>ascending</i> = true )</h3>
<p>This is an overloaded function.</p>
<p>Sets the sort indicator to <i>ascending</i>. Use the other overload instead.</p>
<!-- @@@setSortIndicator -->
<!-- $$$showEvent[overload1]$$$showEventQShowEvent* -->
<h3 class="fn"><a name="showEvent"></a><span class="type">void</span> Q3Header::<span class="name">showEvent</span> ( <span class="type"><a href="qshowevent.html">QShowEvent</a></span> * <i>e</i> )<tt> [virtual protected]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#showEvent">QWidget::showEvent</a>().</p>
<!-- @@@showEvent -->
<!-- $$$sizeChange[overload1]$$$sizeChangeintintint -->
<h3 class="fn"><a name="sizeChange"></a><span class="type">void</span> Q3Header::<span class="name">sizeChange</span> ( <span class="type">int</span> <i>section</i>, <span class="type">int</span> <i>oldSize</i>, <span class="type">int</span> <i>newSize</i> )<tt> [signal]</tt></h3>
<p>This signal is emitted when the user has changed the size of a <i>section</i> from <i>oldSize</i> to <i>newSize</i>. This signal is typically connected to a slot that repaints the table or list that contains the header.</p>
<!-- @@@sizeChange -->
<!-- $$$sizeHint[overload1]$$$sizeHint -->
<h3 class="fn"><a name="sizeHint"></a><span class="type"><a href="qsize.html">QSize</a></span> Q3Header::<span class="name">sizeHint</span> () const<tt> [virtual]</tt></h3>
<p>Reimplemented from <a href="qwidget.html#sizeHint-prop">QWidget::sizeHint</a>().</p>
<!-- @@@sizeHint -->
<!-- $$$sortIndicatorOrder[overload1]$$$sortIndicatorOrder -->
<h3 class="fn"><a name="sortIndicatorOrder"></a><span class="type"><a href="qt.html#SortOrder-enum">Qt::SortOrder</a></span> Q3Header::<span class="name">sortIndicatorOrder</span> () const</h3>
<p>Returns the implied sort order of the Q3Headers sort indicator.</p>
<p><b>See also </b><a href="q3header.html#setSortIndicator">setSortIndicator</a>() and <a href="q3header.html#sortIndicatorSection">sortIndicatorSection</a>().</p>
<!-- @@@sortIndicatorOrder -->
<!-- $$$sortIndicatorSection[overload1]$$$sortIndicatorSection -->
<h3 class="fn"><a name="sortIndicatorSection"></a><span class="type">int</span> Q3Header::<span class="name">sortIndicatorSection</span> () const</h3>
<p>Returns the section showing the sort indicator or -1 if there is no sort indicator.</p>
<p><b>See also </b><a href="q3header.html#setSortIndicator">setSortIndicator</a>() and <a href="q3header.html#sortIndicatorOrder">sortIndicatorOrder</a>().</p>
<!-- @@@sortIndicatorSection -->
</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>