Sophie

Sophie

distrib > Fedora > 18 > x86_64 > by-pkgid > ff187cb994c94c614ecc64c5a8528b1b > files > 4573

qt-doc-4.8.5-10.fc18.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" />
<!-- q3iconview.cpp -->
  <title>Qt 4.8: Q3IconViewItem 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>Q3IconViewItem</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-functions">Public Functions</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">Q3IconViewItem Class Reference</h1>
<!-- $$$Q3IconViewItem-brief -->
<p>The Q3IconViewItem class provides a single item in a <a href="q3iconview.html">Q3IconView</a>. <a href="#details">More...</a></p>
<!-- @@@Q3IconViewItem -->
<pre class="cpp"> <span class="preprocessor">#include &lt;Q3IconViewItem&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">Porting to Qt 4</a> for more information.</p>
<ul>
<li><a href="q3iconviewitem-members.html">List of all members, including inherited members</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="q3iconviewitem.html#Q3IconViewItem">Q3IconViewItem</a></b> ( Q3IconView * <i>parent</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#Q3IconViewItem-2">Q3IconViewItem</a></b> ( Q3IconView * <i>parent</i>, Q3IconViewItem * <i>after</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#Q3IconViewItem-3">Q3IconViewItem</a></b> ( Q3IconView * <i>parent</i>, const QString &amp; <i>text</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#Q3IconViewItem-4">Q3IconViewItem</a></b> ( Q3IconView * <i>parent</i>, Q3IconViewItem * <i>after</i>, const QString &amp; <i>text</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#Q3IconViewItem-5">Q3IconViewItem</a></b> ( Q3IconView * <i>parent</i>, const QString &amp; <i>text</i>, const QPixmap &amp; <i>icon</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#Q3IconViewItem-6">Q3IconViewItem</a></b> ( Q3IconView * <i>parent</i>, Q3IconViewItem * <i>after</i>, const QString &amp; <i>text</i>, const QPixmap &amp; <i>icon</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#Q3IconViewItem-7">Q3IconViewItem</a></b> ( Q3IconView * <i>parent</i>, const QString &amp; <i>text</i>, const QPicture &amp; <i>picture</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#Q3IconViewItem-8">Q3IconViewItem</a></b> ( Q3IconView * <i>parent</i>, Q3IconViewItem * <i>after</i>, const QString &amp; <i>text</i>, const QPicture &amp; <i>picture</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#dtor.Q3IconViewItem">~Q3IconViewItem</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual bool </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#acceptDrop">acceptDrop</a></b> ( const QMimeSource * <i>mime</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual int </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#compare">compare</a></b> ( Q3IconViewItem * <i>i</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#contains">contains</a></b> ( const QPoint &amp; <i>pnt</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#dragEnabled">dragEnabled</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#dropEnabled">dropEnabled</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#height">height</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> Q3IconView * </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#iconView">iconView</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#index">index</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#intersects">intersects</a></b> ( const QRect &amp; <i>r</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#isSelectable">isSelectable</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#isSelected">isSelected</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual QString </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#key">key</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual bool </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#move">move</a></b> ( int <i>x</i>, int <i>y</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual bool </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#move-2">move</a></b> ( const QPoint &amp; <i>pnt</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#moveBy">moveBy</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="q3iconviewitem.html#moveBy-2">moveBy</a></b> ( const QPoint &amp; <i>pnt</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> Q3IconViewItem * </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#nextItem">nextItem</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual QPicture * </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#picture">picture</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual QPixmap * </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#pixmap">pixmap</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QRect </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#pixmapRect">pixmapRect</a></b> ( bool <i>relative</i> = true ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QPoint </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#pos">pos</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> Q3IconViewItem * </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#prevItem">prevItem</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QRect </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#rect">rect</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#rename">rename</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#renameEnabled">renameEnabled</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#repaint">repaint</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual int </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#rtti">rtti</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#setDragEnabled">setDragEnabled</a></b> ( bool <i>allow</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#setDropEnabled">setDropEnabled</a></b> ( bool <i>allow</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#setKey">setKey</a></b> ( const QString &amp; <i>k</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#setPicture">setPicture</a></b> ( const QPicture &amp; <i>icon</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#setPixmap">setPixmap</a></b> ( const QPixmap &amp; <i>icon</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#setPixmap-2">setPixmap</a></b> ( const QPixmap &amp; <i>icon</i>, bool <i>recalc</i>, bool <i>redraw</i> = true )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#setRenameEnabled">setRenameEnabled</a></b> ( bool <i>allow</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#setSelectable">setSelectable</a></b> ( bool <i>enable</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#setSelected">setSelected</a></b> ( bool <i>s</i>, bool <i>cb</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#setSelected-2">setSelected</a></b> ( bool <i>s</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#setText">setText</a></b> ( const QString &amp; <i>text</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#setText-2">setText</a></b> ( const QString &amp; <i>text</i>, bool <i>recalc</i>, bool <i>redraw</i> = true )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QSize </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#size">size</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual QString </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#text">text</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QRect </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#textRect">textRect</a></b> ( bool <i>relative</i> = true ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#width">width</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#x">x</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#y">y</a></b> () const</td></tr>
</table>
<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="q3iconviewitem.html#calcRect">calcRect</a></b> ( const QString &amp; <i>text_</i> = QString() )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#dragEntered">dragEntered</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#dragLeft">dragLeft</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#dropped">dropped</a></b> ( QDropEvent * <i>e</i>, const Q3ValueList&lt;Q3IconDragItem&gt; &amp; <i>lst</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#paintFocus">paintFocus</a></b> ( QPainter * <i>p</i>, const QColorGroup &amp; <i>cg</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#paintItem">paintItem</a></b> ( QPainter * <i>p</i>, const QColorGroup &amp; <i>cg</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#removeRenameBox">removeRenameBox</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3iconviewitem.html#setItemRect">setItemRect</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="q3iconviewitem.html#setPixmapRect">setPixmapRect</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="q3iconviewitem.html#setTextRect">setTextRect</a></b> ( const QRect &amp; <i>r</i> )</td></tr>
</table>
<a name="details"></a>
<!-- $$$Q3IconViewItem-description -->
<div class="descr">
<h2>Detailed Description</h2>
<p>The Q3IconViewItem class provides a single item in a <a href="q3iconview.html">Q3IconView</a>.</p>
<p>A Q3IconViewItem contains an icon, a string and optionally a sort key, and can display itself in a <a href="q3iconview.html">Q3IconView</a>.</p>
<p>The simplest way to create a Q3IconViewItem and insert it into a <a href="q3iconview.html">Q3IconView</a> is to construct the item passing the constructor a pointer to the icon view, a string and an icon:</p>
<pre class="cpp"> (<span class="type">void</span>) <span class="keyword">new</span> <span class="type">Q3IconViewItem</span>(
                 iconView<span class="operator">,</span>        <span class="comment">// A pointer to a Q3IconView</span>
                 <span class="string">&quot;This is the text of the item&quot;</span><span class="operator">,</span>
                 aPixmap);</pre>
<p>By default the text of an icon view item may not be edited by the user but calling setRenameEnabled(true) will allow the user to perform in-place editing of the item's text.</p>
<p>When the icon view is deleted all items in it are deleted automatically.</p>
<p>The <a href="q3iconview.html#firstItem">Q3IconView::firstItem</a>() and <a href="q3iconviewitem.html#nextItem">Q3IconViewItem::nextItem</a>() functions provide a means of iterating over all the items in a <a href="q3iconview.html">Q3IconView</a>:</p>
<pre class="cpp"> <span class="type">Q3IconViewItem</span> <span class="operator">*</span>item;
 <span class="keyword">for</span> (item <span class="operator">=</span> iconView<span class="operator">-</span><span class="operator">&gt;</span>firstItem(); item; item <span class="operator">=</span> item<span class="operator">-</span><span class="operator">&gt;</span>nextItem())
     do_something_with(item);</pre>
<p>The item's icon view is available from <a href="q3iconviewitem.html#iconView">iconView</a>(), and its position in the icon view from <a href="q3iconviewitem.html#index">index</a>().</p>
<p>The item's selection status is available from <a href="q3iconviewitem.html#isSelected">isSelected</a>() and is set and controlled by <a href="q3iconviewitem.html#setSelected">setSelected</a>() and <a href="q3iconviewitem.html#isSelectable">isSelectable</a>().</p>
<p>The text and icon can be set with <a href="q3iconviewitem.html#setText">setText</a>() and <a href="q3iconviewitem.html#setPixmap">setPixmap</a>() and retrieved with <a href="q3iconviewitem.html#text">text</a>() and <a href="q3iconviewitem.html#pixmap">pixmap</a>(). The item's sort key defaults to <a href="q3iconviewitem.html#text">text</a>() but may be set with <a href="q3iconviewitem.html#setKey">setKey</a>() and retrieved with <a href="q3iconviewitem.html#key">key</a>(). The comparison function, <a href="q3iconviewitem.html#compare">compare</a>() uses <a href="q3iconviewitem.html#key">key</a>().</p>
<p>Items may be repositioned with <a href="q3iconviewitem.html#move">move</a>() and <a href="q3iconviewitem.html#moveBy">moveBy</a>(). An item's geometry is available from <a href="q3iconviewitem.html#rect">rect</a>(), <a href="q3iconviewitem.html#x">x</a>(), <a href="q3iconviewitem.html#y">y</a>(), <a href="q3iconviewitem.html#width">width</a>(), <a href="q3iconviewitem.html#height">height</a>(), <a href="q3iconviewitem.html#size">size</a>(), <a href="q3iconviewitem.html#pos">pos</a>(), <a href="q3iconviewitem.html#textRect">textRect</a>() and <a href="q3iconviewitem.html#pixmapRect">pixmapRect</a>(). You can also test against the position of a point with <a href="q3iconviewitem.html#contains">contains</a>() and <a href="q3iconviewitem.html#intersects">intersects</a>().</p>
<p>To remove an item from an icon view, just delete the item. The Q3IconViewItem destructor removes it cleanly from its icon view.</p>
<p>Because the icon view is designed to use drag-and-drop, the icon view item also has functions for drag-and-drop which may be reimplemented.</p>
<p>The class is designed to be very similar to <a href="q3listview.html">Q3ListView</a> and <a href="q3listbox.html">Q3ListBox</a> in use, both via instantiation and subclassing.</p>
</div>
<!-- @@@Q3IconViewItem -->
<div class="func">
<h2>Member Function Documentation</h2>
<!-- $$$Q3IconViewItem[overload1]$$$Q3IconViewItemQ3IconView* -->
<h3 class="fn"><a name="Q3IconViewItem"></a>Q3IconViewItem::<span class="name">Q3IconViewItem</span> ( <span class="type"><a href="q3iconview.html">Q3IconView</a></span> * <i>parent</i> )</h3>
<p>Constructs a <a href="q3iconviewitem.html" class="compat">Q3IconViewItem</a> and inserts it into icon view <i>parent</i> with no text and a default icon.</p>
<!-- @@@Q3IconViewItem -->
<!-- $$$Q3IconViewItem$$$Q3IconViewItemQ3IconView*Q3IconViewItem* -->
<h3 class="fn"><a name="Q3IconViewItem-2"></a>Q3IconViewItem::<span class="name">Q3IconViewItem</span> ( <span class="type"><a href="q3iconview.html">Q3IconView</a></span> * <i>parent</i>, <span class="type">Q3IconViewItem</span> * <i>after</i> )</h3>
<p>Constructs a <a href="q3iconviewitem.html" class="compat">Q3IconViewItem</a> and inserts it into the icon view <i>parent</i> with no text and a default icon, after the icon view item <i>after</i>.</p>
<!-- @@@Q3IconViewItem -->
<!-- $$$Q3IconViewItem$$$Q3IconViewItemQ3IconView*constQString& -->
<h3 class="fn"><a name="Q3IconViewItem-3"></a>Q3IconViewItem::<span class="name">Q3IconViewItem</span> ( <span class="type"><a href="q3iconview.html">Q3IconView</a></span> * <i>parent</i>, const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>text</i> )</h3>
<p>Constructs an icon view item and inserts it into the icon view <i>parent</i> using <i>text</i> as the text and a default icon.</p>
<!-- @@@Q3IconViewItem -->
<!-- $$$Q3IconViewItem$$$Q3IconViewItemQ3IconView*Q3IconViewItem*constQString& -->
<h3 class="fn"><a name="Q3IconViewItem-4"></a>Q3IconViewItem::<span class="name">Q3IconViewItem</span> ( <span class="type"><a href="q3iconview.html">Q3IconView</a></span> * <i>parent</i>, <span class="type">Q3IconViewItem</span> * <i>after</i>, const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>text</i> )</h3>
<p>Constructs an icon view item and inserts it into the icon view <i>parent</i> using <i>text</i> as the text and a default icon, after the icon view item <i>after</i>.</p>
<!-- @@@Q3IconViewItem -->
<!-- $$$Q3IconViewItem$$$Q3IconViewItemQ3IconView*constQString&constQPixmap& -->
<h3 class="fn"><a name="Q3IconViewItem-5"></a>Q3IconViewItem::<span class="name">Q3IconViewItem</span> ( <span class="type"><a href="q3iconview.html">Q3IconView</a></span> * <i>parent</i>, const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>text</i>, const <span class="type"><a href="qpixmap.html">QPixmap</a></span> &amp; <i>icon</i> )</h3>
<p>Constructs an icon view item and inserts it into the icon view <i>parent</i> using <i>text</i> as the text and <i>icon</i> as the icon.</p>
<!-- @@@Q3IconViewItem -->
<!-- $$$Q3IconViewItem$$$Q3IconViewItemQ3IconView*Q3IconViewItem*constQString&constQPixmap& -->
<h3 class="fn"><a name="Q3IconViewItem-6"></a>Q3IconViewItem::<span class="name">Q3IconViewItem</span> ( <span class="type"><a href="q3iconview.html">Q3IconView</a></span> * <i>parent</i>, <span class="type">Q3IconViewItem</span> * <i>after</i>, const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>text</i>, const <span class="type"><a href="qpixmap.html">QPixmap</a></span> &amp; <i>icon</i> )</h3>
<p>Constructs an icon view item and inserts it into the icon view <i>parent</i> using <i>text</i> as the text and <i>icon</i> as the icon, after the icon view item <i>after</i>.</p>
<!-- @@@Q3IconViewItem -->
<!-- $$$Q3IconViewItem$$$Q3IconViewItemQ3IconView*constQString&constQPicture& -->
<h3 class="fn"><a name="Q3IconViewItem-7"></a>Q3IconViewItem::<span class="name">Q3IconViewItem</span> ( <span class="type"><a href="q3iconview.html">Q3IconView</a></span> * <i>parent</i>, const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>text</i>, const <span class="type"><a href="qpicture.html">QPicture</a></span> &amp; <i>picture</i> )</h3>
<p>Constructs an icon view item and inserts it into the icon view <i>parent</i> using <i>text</i> as the text and <i>picture</i> as the icon.</p>
<!-- @@@Q3IconViewItem -->
<!-- $$$Q3IconViewItem$$$Q3IconViewItemQ3IconView*Q3IconViewItem*constQString&constQPicture& -->
<h3 class="fn"><a name="Q3IconViewItem-8"></a>Q3IconViewItem::<span class="name">Q3IconViewItem</span> ( <span class="type"><a href="q3iconview.html">Q3IconView</a></span> * <i>parent</i>, <span class="type">Q3IconViewItem</span> * <i>after</i>, const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>text</i>, const <span class="type"><a href="qpicture.html">QPicture</a></span> &amp; <i>picture</i> )</h3>
<p>Constructs an icon view item and inserts it into the icon view <i>parent</i> using <i>text</i> as the text and <i>picture</i> as the icon, after the icon view item <i>after</i>.</p>
<!-- @@@Q3IconViewItem -->
<!-- $$$~Q3IconViewItem[overload1]$$$~Q3IconViewItem -->
<h3 class="fn"><a name="dtor.Q3IconViewItem"></a>Q3IconViewItem::<span class="name">~Q3IconViewItem</span> ()<tt> [virtual]</tt></h3>
<p>Destroys the icon view item and tells the parent icon view that the item has been destroyed.</p>
<!-- @@@~Q3IconViewItem -->
<!-- $$$acceptDrop[overload1]$$$acceptDropconstQMimeSource* -->
<h3 class="fn"><a name="acceptDrop"></a><span class="type">bool</span> Q3IconViewItem::<span class="name">acceptDrop</span> ( const <span class="type"><a href="qmimesource.html">QMimeSource</a></span> * <i>mime</i> ) const<tt> [virtual]</tt></h3>
<p>Returns true if you can drop things with a <a href="qmimesource.html" class="obsolete">QMimeSource</a> of <i>mime</i> onto this item; otherwise returns false.</p>
<p>The default implementation always returns false. You must subclass <a href="q3iconviewitem.html" class="compat">Q3IconViewItem</a> and reimplement acceptDrop() to accept drops.</p>
<!-- @@@acceptDrop -->
<!-- $$$calcRect[overload1]$$$calcRectconstQString& -->
<h3 class="fn"><a name="calcRect"></a><span class="type">void</span> Q3IconViewItem::<span class="name">calcRect</span> ( const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>text_</i> = QString() )<tt> [virtual protected]</tt></h3>
<p>This virtual function is responsible for calculating the rectangles returned by <a href="q3iconviewitem.html#rect">rect</a>(), <a href="q3iconviewitem.html#textRect">textRect</a>() and <a href="q3iconviewitem.html#pixmapRect">pixmapRect</a>(). setRect(), <a href="q3iconviewitem.html#setTextRect">setTextRect</a>() and <a href="q3iconviewitem.html#setPixmapRect">setPixmapRect</a>() are provided mainly for reimplementations of this function.</p>
<p><i>text_</i> is an internal parameter which defaults to an empty string.</p>
<!-- @@@calcRect -->
<!-- $$$compare[overload1]$$$compareQ3IconViewItem* -->
<h3 class="fn"><a name="compare"></a><span class="type">int</span> Q3IconViewItem::<span class="name">compare</span> ( <span class="type">Q3IconViewItem</span> * <i>i</i> ) const<tt> [virtual]</tt></h3>
<p>Compares this icon view item to <i>i</i>. Returns -1 if this item is less than <i>i</i>, 0 if they are equal, and 1 if this icon view item is greater than <i>i</i>.</p>
<p>The default implementation compares the item keys (<a href="q3iconviewitem.html#key">key</a>()) using <a href="qstring.html#localeAwareCompare">QString::localeAwareCompare</a>(). A reimplementation may use different values and a different comparison function. Here is a reimplementation that uses plain Unicode comparison:</p>
<pre class="cpp"> <span class="type">int</span> MyIconViewItem<span class="operator">::</span>compare(<span class="type"><a href="q3iconviewitem.html">Q3IconViewItem</a></span> <span class="operator">*</span>i) <span class="keyword">const</span>
 {
     <span class="keyword">return</span> key()<span class="operator">.</span>compare(i<span class="operator">-</span><span class="operator">&gt;</span>key());
 }</pre>
<p><b>See also </b><a href="q3iconviewitem.html#key">key</a>(), <a href="qstring.html#localeAwareCompare">QString::localeAwareCompare</a>(), and <a href="qstring.html#compare">QString::compare</a>().</p>
<!-- @@@compare -->
<!-- $$$contains[overload1]$$$containsconstQPoint& -->
<h3 class="fn"><a name="contains"></a><span class="type">bool</span> Q3IconViewItem::<span class="name">contains</span> ( const <span class="type"><a href="qpoint.html">QPoint</a></span> &amp; <i>pnt</i> ) const</h3>
<p>Returns true if the item contains the point <i>pnt</i> (in contents coordinates); otherwise returns false.</p>
<!-- @@@contains -->
<!-- $$$dragEnabled[overload1]$$$dragEnabled -->
<h3 class="fn"><a name="dragEnabled"></a><span class="type">bool</span> Q3IconViewItem::<span class="name">dragEnabled</span> () const</h3>
<p>Returns true if the user is allowed to drag the icon view item; otherwise returns false.</p>
<p><b>See also </b><a href="q3iconviewitem.html#setDragEnabled">setDragEnabled</a>().</p>
<!-- @@@dragEnabled -->
<!-- $$$dragEntered[overload1]$$$dragEntered -->
<h3 class="fn"><a name="dragEntered"></a><span class="type">void</span> Q3IconViewItem::<span class="name">dragEntered</span> ()<tt> [virtual protected]</tt></h3>
<p>This function is called when a drag enters the item's bounding rectangle.</p>
<p>The default implementation does nothing; subclasses may reimplement this function.</p>
<!-- @@@dragEntered -->
<!-- $$$dragLeft[overload1]$$$dragLeft -->
<h3 class="fn"><a name="dragLeft"></a><span class="type">void</span> Q3IconViewItem::<span class="name">dragLeft</span> ()<tt> [virtual protected]</tt></h3>
<p>This function is called when a drag leaves the item's bounding rectangle.</p>
<p>The default implementation does nothing; subclasses may reimplement this function.</p>
<!-- @@@dragLeft -->
<!-- $$$dropEnabled[overload1]$$$dropEnabled -->
<h3 class="fn"><a name="dropEnabled"></a><span class="type">bool</span> Q3IconViewItem::<span class="name">dropEnabled</span> () const</h3>
<p>Returns true if the user is allowed to drop something onto the item; otherwise returns false.</p>
<p><b>See also </b><a href="q3iconviewitem.html#setDropEnabled">setDropEnabled</a>().</p>
<!-- @@@dropEnabled -->
<!-- $$$dropped[overload1]$$$droppedQDropEvent*constQ3ValueList<Q3IconDragItem>& -->
<h3 class="fn"><a name="dropped"></a><span class="type">void</span> Q3IconViewItem::<span class="name">dropped</span> ( <span class="type"><a href="qdropevent.html">QDropEvent</a></span> * <i>e</i>, const <span class="type"><a href="q3valuelist.html">Q3ValueList</a></span>&lt;<span class="type"><a href="q3icondragitem.html">Q3IconDragItem</a></span>&gt; &amp; <i>lst</i> )<tt> [virtual protected]</tt></h3>
<p>This function is called when something is dropped on the item. <i>e</i> provides all the information about the drop. If the drag object of the drop was a <a href="q3icondrag.html" class="compat">Q3IconDrag</a>, <i>lst</i> contains the list of the dropped items. You can get the data by calling <a href="q3icondragitem.html#data">Q3IconDragItem::data</a>() on each item. If the <i>lst</i> is empty, i.e&#x2e; the drag was not a <a href="q3icondrag.html" class="compat">Q3IconDrag</a>, you must decode the data in <i>e</i> and work with that.</p>
<p>The default implementation does nothing; subclasses may reimplement this function.</p>
<!-- @@@dropped -->
<!-- $$$height[overload1]$$$height -->
<h3 class="fn"><a name="height"></a><span class="type">int</span> Q3IconViewItem::<span class="name">height</span> () const</h3>
<p>Returns the height of the item.</p>
<!-- @@@height -->
<!-- $$$iconView[overload1]$$$iconView -->
<h3 class="fn"><a name="iconView"></a><span class="type"><a href="q3iconview.html">Q3IconView</a></span> * Q3IconViewItem::<span class="name">iconView</span> () const</h3>
<p>Returns a pointer to this item's icon view parent.</p>
<!-- @@@iconView -->
<!-- $$$index[overload1]$$$index -->
<h3 class="fn"><a name="index"></a><span class="type">int</span> Q3IconViewItem::<span class="name">index</span> () const</h3>
<p>Returns the index of this item in the icon view, or -1 if an error occurred.</p>
<!-- @@@index -->
<!-- $$$intersects[overload1]$$$intersectsconstQRect& -->
<h3 class="fn"><a name="intersects"></a><span class="type">bool</span> Q3IconViewItem::<span class="name">intersects</span> ( const <span class="type"><a href="qrect.html">QRect</a></span> &amp; <i>r</i> ) const</h3>
<p>Returns true if the item intersects the rectangle <i>r</i> (in contents coordinates); otherwise returns false.</p>
<!-- @@@intersects -->
<!-- $$$isSelectable[overload1]$$$isSelectable -->
<h3 class="fn"><a name="isSelectable"></a><span class="type">bool</span> Q3IconViewItem::<span class="name">isSelectable</span> () const</h3>
<p>Returns true if the item is selectable; otherwise returns false.</p>
<p><b>See also </b><a href="q3iconviewitem.html#setSelectable">setSelectable</a>().</p>
<!-- @@@isSelectable -->
<!-- $$$isSelected[overload1]$$$isSelected -->
<h3 class="fn"><a name="isSelected"></a><span class="type">bool</span> Q3IconViewItem::<span class="name">isSelected</span> () const</h3>
<p>Returns true if the item is selected; otherwise returns false.</p>
<p><b>See also </b><a href="q3iconviewitem.html#setSelected">setSelected</a>().</p>
<!-- @@@isSelected -->
<!-- $$$key[overload1]$$$key -->
<h3 class="fn"><a name="key"></a><span class="type"><a href="qstring.html">QString</a></span> Q3IconViewItem::<span class="name">key</span> () const<tt> [virtual]</tt></h3>
<p>Returns the key of the icon view item or <a href="q3iconviewitem.html#text">text</a>() if no key has been explicitly set.</p>
<p><b>See also </b><a href="q3iconviewitem.html#setKey">setKey</a>() and <a href="q3iconviewitem.html#compare">compare</a>().</p>
<!-- @@@key -->
<!-- $$$move[overload1]$$$moveintint -->
<h3 class="fn"><a name="move"></a><span class="type">bool</span> Q3IconViewItem::<span class="name">move</span> ( <span class="type">int</span> <i>x</i>, <span class="type">int</span> <i>y</i> )<tt> [virtual]</tt></h3>
<p>Moves the item to position (<i>x</i>, <i>y</i>) in the icon view (these are contents coordinates). Returns true if the item is moved. Returns false if the item is already at the specified position.</p>
<!-- @@@move -->
<!-- $$$move$$$moveconstQPoint& -->
<h3 class="fn"><a name="move-2"></a><span class="type">bool</span> Q3IconViewItem::<span class="name">move</span> ( const <span class="type"><a href="qpoint.html">QPoint</a></span> &amp; <i>pnt</i> )<tt> [virtual]</tt></h3>
<p>This is an overloaded function.</p>
<p>Moves the item to the point <i>pnt</i>.</p>
<!-- @@@move -->
<!-- $$$moveBy[overload1]$$$moveByintint -->
<h3 class="fn"><a name="moveBy"></a><span class="type">void</span> Q3IconViewItem::<span class="name">moveBy</span> ( <span class="type">int</span> <i>dx</i>, <span class="type">int</span> <i>dy</i> )<tt> [virtual]</tt></h3>
<p>Moves the item <i>dx</i> pixels in the x-direction and <i>dy</i> pixels in the y-direction.</p>
<!-- @@@moveBy -->
<!-- $$$moveBy$$$moveByconstQPoint& -->
<h3 class="fn"><a name="moveBy-2"></a><span class="type">void</span> Q3IconViewItem::<span class="name">moveBy</span> ( const <span class="type"><a href="qpoint.html">QPoint</a></span> &amp; <i>pnt</i> )<tt> [virtual]</tt></h3>
<p>This is an overloaded function.</p>
<p>Moves the item by the x, y values in point <i>pnt</i>.</p>
<!-- @@@moveBy -->
<!-- $$$nextItem[overload1]$$$nextItem -->
<h3 class="fn"><a name="nextItem"></a><span class="type">Q3IconViewItem</span> * Q3IconViewItem::<span class="name">nextItem</span> () const</h3>
<p>Returns a pointer to the next item, or 0 if this is the last item in the icon view.</p>
<p>To find the first item use <a href="q3iconview.html#firstItem">Q3IconView::firstItem</a>().</p>
<p>Example:</p>
<pre class="cpp"> <span class="type"><a href="q3iconviewitem.html">Q3IconViewItem</a></span> <span class="operator">*</span>item;
 <span class="keyword">for</span> (item <span class="operator">=</span> iconView<span class="operator">-</span><span class="operator">&gt;</span>firstItem(); item; item <span class="operator">=</span> item<span class="operator">-</span><span class="operator">&gt;</span>nextItem())
     do_something_with(item);</pre>
<p><b>See also </b><a href="q3iconviewitem.html#prevItem">prevItem</a>().</p>
<!-- @@@nextItem -->
<!-- $$$paintFocus[overload1]$$$paintFocusQPainter*constQColorGroup& -->
<h3 class="fn"><a name="paintFocus"></a><span class="type">void</span> Q3IconViewItem::<span class="name">paintFocus</span> ( <span class="type"><a href="qpainter.html">QPainter</a></span> * <i>p</i>, const <span class="type"><a href="qcolorgroup.html">QColorGroup</a></span> &amp; <i>cg</i> )<tt> [virtual protected]</tt></h3>
<p>Paints the focus rectangle of the item using the painter <i>p</i> and the color group <i>cg</i>.</p>
<!-- @@@paintFocus -->
<!-- $$$paintItem[overload1]$$$paintItemQPainter*constQColorGroup& -->
<h3 class="fn"><a name="paintItem"></a><span class="type">void</span> Q3IconViewItem::<span class="name">paintItem</span> ( <span class="type"><a href="qpainter.html">QPainter</a></span> * <i>p</i>, const <span class="type"><a href="qcolorgroup.html">QColorGroup</a></span> &amp; <i>cg</i> )<tt> [virtual protected]</tt></h3>
<p>Paints the item using the painter <i>p</i> and the color group <i>cg</i>. If you want the item to be drawn with a different font or color, reimplement this function, change the values of the color group or the painter's font, and then call the Q3IconViewItem::paintItem() with the changed values.</p>
<!-- @@@paintItem -->
<!-- $$$picture[overload1]$$$picture -->
<h3 class="fn"><a name="picture"></a><span class="type"><a href="qpicture.html">QPicture</a></span> * Q3IconViewItem::<span class="name">picture</span> () const<tt> [virtual]</tt></h3>
<p>Returns the icon of the icon view item if it is a picture, or 0 if it is a pixmap. In the latter case use <a href="q3iconviewitem.html#pixmap">pixmap</a>() instead. Normally you set the picture of the item with <a href="q3iconviewitem.html#setPicture">setPicture</a>(), but sometimes it's inconvenient to call <a href="q3iconviewitem.html#setPicture">setPicture</a>() for every item. So you can subclass <a href="q3iconviewitem.html" class="compat">Q3IconViewItem</a>, reimplement this function and return a pointer to the item's picture. If you do this, you <i>must</i> call <a href="q3iconviewitem.html#calcRect">calcRect</a>() manually each time the size of this picture changes.</p>
<p><b>See also </b><a href="q3iconviewitem.html#setPicture">setPicture</a>().</p>
<!-- @@@picture -->
<!-- $$$pixmap[overload1]$$$pixmap -->
<h3 class="fn"><a name="pixmap"></a><span class="type"><a href="qpixmap.html">QPixmap</a></span> * Q3IconViewItem::<span class="name">pixmap</span> () const<tt> [virtual]</tt></h3>
<p>Returns the icon of the icon view item if it is a pixmap, or 0 if it is a picture. In the latter case use <a href="q3iconviewitem.html#picture">picture</a>() instead. Normally you set the pixmap of the item with <a href="q3iconviewitem.html#setPixmap">setPixmap</a>(), but sometimes it's inconvenient to call <a href="q3iconviewitem.html#setPixmap">setPixmap</a>() for every item. So you can subclass <a href="q3iconviewitem.html" class="compat">Q3IconViewItem</a>, reimplement this function and return a pointer to the item's pixmap. If you do this, you <i>must</i> call <a href="q3iconviewitem.html#calcRect">calcRect</a>() manually each time the size of this pixmap changes.</p>
<p><b>See also </b><a href="q3iconviewitem.html#setPixmap">setPixmap</a>().</p>
<!-- @@@pixmap -->
<!-- $$$pixmapRect[overload1]$$$pixmapRectbool -->
<h3 class="fn"><a name="pixmapRect"></a><span class="type"><a href="qrect.html">QRect</a></span> Q3IconViewItem::<span class="name">pixmapRect</span> ( <span class="type">bool</span> <i>relative</i> = true ) const</h3>
<p>Returns the bounding rectangle of the item's icon.</p>
<p>If <i>relative</i> is true, (the default), the rectangle is relative to the origin of the item's rectangle. If <i>relative</i> is false, the returned rectangle is relative to the origin of the icon view's contents coordinate system.</p>
<p><b>See also </b><a href="q3iconviewitem.html#setPixmapRect">setPixmapRect</a>().</p>
<!-- @@@pixmapRect -->
<!-- $$$pos[overload1]$$$pos -->
<h3 class="fn"><a name="pos"></a><span class="type"><a href="qpoint.html">QPoint</a></span> Q3IconViewItem::<span class="name">pos</span> () const</h3>
<p>Returns the position of the item (in contents coordinates).</p>
<!-- @@@pos -->
<!-- $$$prevItem[overload1]$$$prevItem -->
<h3 class="fn"><a name="prevItem"></a><span class="type">Q3IconViewItem</span> * Q3IconViewItem::<span class="name">prevItem</span> () const</h3>
<p>Returns a pointer to the previous item, or 0 if this is the first item in the icon view.</p>
<p><b>See also </b><a href="q3iconviewitem.html#nextItem">nextItem</a>() and <a href="q3iconview.html#firstItem">Q3IconView::firstItem</a>().</p>
<!-- @@@prevItem -->
<!-- $$$rect[overload1]$$$rect -->
<h3 class="fn"><a name="rect"></a><span class="type"><a href="qrect.html">QRect</a></span> Q3IconViewItem::<span class="name">rect</span> () const</h3>
<p>Returns the bounding rectangle of the item (in contents coordinates).</p>
<!-- @@@rect -->
<!-- $$$removeRenameBox[overload1]$$$removeRenameBox -->
<h3 class="fn"><a name="removeRenameBox"></a><span class="type">void</span> Q3IconViewItem::<span class="name">removeRenameBox</span> ()<tt> [virtual protected]</tt></h3>
<p>Removes the editbox that is used for in-place renaming.</p>
<!-- @@@removeRenameBox -->
<!-- $$$rename[overload1]$$$rename -->
<h3 class="fn"><a name="rename"></a><span class="type">void</span> Q3IconViewItem::<span class="name">rename</span> ()</h3>
<p>Starts in-place renaming of an icon, if allowed.</p>
<p>This function sets up the icon view so that the user can edit the item text, and then returns. When the user is done, <a href="q3iconviewitem.html#setText">setText</a>() will be called and <a href="q3iconview.html#itemRenamed">Q3IconView::itemRenamed</a>() will be emitted (unless the user canceled, e.g&#x2e; by pressing the Escape key).</p>
<p><b>See also </b><a href="q3iconviewitem.html#setRenameEnabled">setRenameEnabled</a>().</p>
<!-- @@@rename -->
<!-- $$$renameEnabled[overload1]$$$renameEnabled -->
<h3 class="fn"><a name="renameEnabled"></a><span class="type">bool</span> Q3IconViewItem::<span class="name">renameEnabled</span> () const</h3>
<p>Returns true if the item can be renamed by the user with in-place renaming; otherwise returns false.</p>
<p><b>See also </b><a href="q3iconviewitem.html#setRenameEnabled">setRenameEnabled</a>().</p>
<!-- @@@renameEnabled -->
<!-- $$$repaint[overload1]$$$repaint -->
<h3 class="fn"><a name="repaint"></a><span class="type">void</span> Q3IconViewItem::<span class="name">repaint</span> ()<tt> [virtual]</tt></h3>
<p>Repaints the item.</p>
<!-- @@@repaint -->
<!-- $$$rtti[overload1]$$$rtti -->
<h3 class="fn"><a name="rtti"></a><span class="type">int</span> Q3IconViewItem::<span class="name">rtti</span> () const<tt> [virtual]</tt></h3>
<p>Returns 0.</p>
<p>Make your derived classes return their own values for rtti(), so that you can distinguish between icon view item types. You should use values greater than 1000, preferably a large random number, to allow for extensions to this class.</p>
<!-- @@@rtti -->
<!-- $$$setDragEnabled[overload1]$$$setDragEnabledbool -->
<h3 class="fn"><a name="setDragEnabled"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setDragEnabled</span> ( <span class="type">bool</span> <i>allow</i> )<tt> [virtual]</tt></h3>
<p>If <i>allow</i> is true, the icon view permits the user to drag the icon view item either to another position within the icon view or to somewhere outside of it. If <i>allow</i> is false, the item cannot be dragged.</p>
<p><b>See also </b><a href="q3iconviewitem.html#dragEnabled">dragEnabled</a>().</p>
<!-- @@@setDragEnabled -->
<!-- $$$setDropEnabled[overload1]$$$setDropEnabledbool -->
<h3 class="fn"><a name="setDropEnabled"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setDropEnabled</span> ( <span class="type">bool</span> <i>allow</i> )<tt> [virtual]</tt></h3>
<p>If <i>allow</i> is true, the icon view lets the user drop something on this icon view item.</p>
<p><b>See also </b><a href="q3iconviewitem.html#dropEnabled">dropEnabled</a>().</p>
<!-- @@@setDropEnabled -->
<!-- $$$setItemRect[overload1]$$$setItemRectconstQRect& -->
<h3 class="fn"><a name="setItemRect"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setItemRect</span> ( const <span class="type"><a href="qrect.html">QRect</a></span> &amp; <i>r</i> )<tt> [protected]</tt></h3>
<p>Sets the bounding rectangle of the whole item to <i>r</i>. This function is provided for subclasses which reimplement <a href="q3iconviewitem.html#calcRect">calcRect</a>(), so that they can set the calculated rectangle. <i>Any other use is discouraged.</i></p>
<p><b>See also </b><a href="q3iconviewitem.html#calcRect">calcRect</a>(), <a href="q3iconviewitem.html#textRect">textRect</a>(), <a href="q3iconviewitem.html#setTextRect">setTextRect</a>(), <a href="q3iconviewitem.html#pixmapRect">pixmapRect</a>(), and <a href="q3iconviewitem.html#setPixmapRect">setPixmapRect</a>().</p>
<!-- @@@setItemRect -->
<!-- $$$setKey[overload1]$$$setKeyconstQString& -->
<h3 class="fn"><a name="setKey"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setKey</span> ( const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>k</i> )<tt> [virtual]</tt></h3>
<p>Sets <i>k</i> as the sort key of the icon view item. By default <a href="q3iconviewitem.html#text">text</a>() is used for sorting.</p>
<p><b>See also </b><a href="q3iconviewitem.html#key">key</a>() and <a href="q3iconviewitem.html#compare">compare</a>().</p>
<!-- @@@setKey -->
<!-- $$$setPicture[overload1]$$$setPictureconstQPicture& -->
<h3 class="fn"><a name="setPicture"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setPicture</span> ( const <span class="type"><a href="qpicture.html">QPicture</a></span> &amp; <i>icon</i> )<tt> [virtual]</tt></h3>
<p>Sets <i>icon</i> as the item's icon in the icon view. This function might be a no-op if you reimplement <a href="q3iconviewitem.html#picture">picture</a>().</p>
<p><b>See also </b><a href="q3iconviewitem.html#picture">picture</a>().</p>
<!-- @@@setPicture -->
<!-- $$$setPixmap[overload1]$$$setPixmapconstQPixmap& -->
<h3 class="fn"><a name="setPixmap"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setPixmap</span> ( const <span class="type"><a href="qpixmap.html">QPixmap</a></span> &amp; <i>icon</i> )<tt> [virtual]</tt></h3>
<p>Sets <i>icon</i> as the item's icon in the icon view. This function might be a no-op if you reimplement <a href="q3iconviewitem.html#pixmap">pixmap</a>().</p>
<p><b>See also </b><a href="q3iconviewitem.html#pixmap">pixmap</a>().</p>
<!-- @@@setPixmap -->
<!-- $$$setPixmap$$$setPixmapconstQPixmap&boolbool -->
<h3 class="fn"><a name="setPixmap-2"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setPixmap</span> ( const <span class="type"><a href="qpixmap.html">QPixmap</a></span> &amp; <i>icon</i>, <span class="type">bool</span> <i>recalc</i>, <span class="type">bool</span> <i>redraw</i> = true )<tt> [virtual]</tt></h3>
<p>This is an overloaded function.</p>
<p>Sets <i>icon</i> as the item's icon in the icon view. If <i>recalc</i> is true, the icon view's layout is recalculated. If <i>redraw</i> is true (the default), the icon view is repainted.</p>
<p><b>See also </b><a href="q3iconviewitem.html#pixmap">pixmap</a>().</p>
<!-- @@@setPixmap -->
<!-- $$$setPixmapRect[overload1]$$$setPixmapRectconstQRect& -->
<h3 class="fn"><a name="setPixmapRect"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setPixmapRect</span> ( const <span class="type"><a href="qrect.html">QRect</a></span> &amp; <i>r</i> )<tt> [protected]</tt></h3>
<p>Sets the bounding rectangle of the item's icon to <i>r</i>. This function is provided for subclasses which reimplement <a href="q3iconviewitem.html#calcRect">calcRect</a>(), so that they can set the calculated rectangle. <i>Any other use is discouraged.</i></p>
<p><b>See also </b><a href="q3iconviewitem.html#calcRect">calcRect</a>(), <a href="q3iconviewitem.html#pixmapRect">pixmapRect</a>(), <a href="q3iconviewitem.html#setItemRect">setItemRect</a>(), and <a href="q3iconviewitem.html#setTextRect">setTextRect</a>().</p>
<!-- @@@setPixmapRect -->
<!-- $$$setRenameEnabled[overload1]$$$setRenameEnabledbool -->
<h3 class="fn"><a name="setRenameEnabled"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setRenameEnabled</span> ( <span class="type">bool</span> <i>allow</i> )<tt> [virtual]</tt></h3>
<p>If <i>allow</i> is true, the user can rename the icon view item by clicking on the text (or pressing F2) while the item is selected (in-place renaming). If <i>allow</i> is false, in-place renaming is not possible.</p>
<p><b>See also </b><a href="q3iconviewitem.html#renameEnabled">renameEnabled</a>().</p>
<!-- @@@setRenameEnabled -->
<!-- $$$setSelectable[overload1]$$$setSelectablebool -->
<h3 class="fn"><a name="setSelectable"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setSelectable</span> ( <span class="type">bool</span> <i>enable</i> )<tt> [virtual]</tt></h3>
<p>Sets this item to be selectable if <i>enable</i> is true (the default) or unselectable if <i>enable</i> is false.</p>
<p>The user is unable to select a non-selectable item using either the keyboard or the mouse. (The application programmer can select an item in code regardless of this setting.)</p>
<p><b>See also </b><a href="q3iconviewitem.html#isSelectable">isSelectable</a>().</p>
<!-- @@@setSelectable -->
<!-- $$$setSelected[overload1]$$$setSelectedboolbool -->
<h3 class="fn"><a name="setSelected"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setSelected</span> ( <span class="type">bool</span> <i>s</i>, <span class="type">bool</span> <i>cb</i> )<tt> [virtual]</tt></h3>
<p>Selects or unselects the item, depending on <i>s</i>; it may also unselect other items, depending on <a href="q3iconview.html#selectionMode-prop">Q3IconView::selectionMode</a>() and <i>cb</i>.</p>
<p>If <i>s</i> is false, the item is unselected.</p>
<p>If <i>s</i> is true and <a href="q3iconview.html#selectionMode-prop">Q3IconView::selectionMode</a>() is <a href="q3iconview.html#SelectionMode-enum">Q3IconView::Single</a>, the item is selected and the item previously selected is unselected.</p>
<p>If <i>s</i> is true and <a href="q3iconview.html#selectionMode-prop">Q3IconView::selectionMode</a>() is <a href="q3iconview.html#SelectionMode-enum">Q3IconView::Extended</a>, the item is selected. If <i>cb</i> is true, the selection state of the other items is left unchanged. If <i>cb</i> is false (the default) all other items are unselected.</p>
<p>If <i>s</i> is true and <a href="q3iconview.html#selectionMode-prop">Q3IconView::selectionMode</a>() is <a href="q3iconview.html#SelectionMode-enum">Q3IconView::Multi</a>, the item is selected.</p>
<p>Note that <i>cb</i> is used only if <a href="q3iconview.html#selectionMode-prop">Q3IconView::selectionMode</a>() is <a href="q3iconview.html#SelectionMode-enum">Q3IconView::Extended</a>; cb defaults to false.</p>
<p>All items whose selection status changes repaint themselves.</p>
<p><b>See also </b><a href="q3iconviewitem.html#isSelected">isSelected</a>().</p>
<!-- @@@setSelected -->
<!-- $$$setSelected$$$setSelectedbool -->
<h3 class="fn"><a name="setSelected-2"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setSelected</span> ( <span class="type">bool</span> <i>s</i> )<tt> [virtual]</tt></h3>
<p>This is an overloaded function.</p>
<p>This variant is equivalent to calling the other variant with <i>cb</i> set to false.</p>
<!-- @@@setSelected -->
<!-- $$$setText[overload1]$$$setTextconstQString& -->
<h3 class="fn"><a name="setText"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setText</span> ( const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>text</i> )<tt> [virtual]</tt></h3>
<p>Sets <i>text</i> as the text of the icon view item. This function might be a no-op if you reimplement <a href="q3iconviewitem.html#text">text</a>().</p>
<p><b>See also </b><a href="q3iconviewitem.html#text">text</a>().</p>
<!-- @@@setText -->
<!-- $$$setText$$$setTextconstQString&boolbool -->
<h3 class="fn"><a name="setText-2"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setText</span> ( const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>text</i>, <span class="type">bool</span> <i>recalc</i>, <span class="type">bool</span> <i>redraw</i> = true )<tt> [virtual]</tt></h3>
<p>This is an overloaded function.</p>
<p>Sets <i>text</i> as the text of the icon view item. If <i>recalc</i> is true, the icon view's layout is recalculated. If <i>redraw</i> is true (the default), the icon view is repainted.</p>
<p><b>See also </b><a href="q3iconviewitem.html#text">text</a>().</p>
<!-- @@@setText -->
<!-- $$$setTextRect[overload1]$$$setTextRectconstQRect& -->
<h3 class="fn"><a name="setTextRect"></a><span class="type">void</span> Q3IconViewItem::<span class="name">setTextRect</span> ( const <span class="type"><a href="qrect.html">QRect</a></span> &amp; <i>r</i> )<tt> [protected]</tt></h3>
<p>Sets the bounding rectangle of the item's text to <i>r</i>. This function is provided for subclasses which reimplement <a href="q3iconviewitem.html#calcRect">calcRect</a>(), so that they can set the calculated rectangle. <i>Any other use is discouraged.</i></p>
<p><b>See also </b><a href="q3iconviewitem.html#calcRect">calcRect</a>(), <a href="q3iconviewitem.html#textRect">textRect</a>(), <a href="q3iconviewitem.html#setItemRect">setItemRect</a>(), and <a href="q3iconviewitem.html#setPixmapRect">setPixmapRect</a>().</p>
<!-- @@@setTextRect -->
<!-- $$$size[overload1]$$$size -->
<h3 class="fn"><a name="size"></a><span class="type"><a href="qsize.html">QSize</a></span> Q3IconViewItem::<span class="name">size</span> () const</h3>
<p>Returns the size of the item.</p>
<!-- @@@size -->
<!-- $$$text[overload1]$$$text -->
<h3 class="fn"><a name="text"></a><span class="type"><a href="qstring.html">QString</a></span> Q3IconViewItem::<span class="name">text</span> () const<tt> [virtual]</tt></h3>
<p>Returns the text of the icon view item. Normally you set the text of the item with <a href="q3iconviewitem.html#setText">setText</a>(), but sometimes it's inconvenient to call <a href="q3iconviewitem.html#setText">setText</a>() for every item; so you can subclass <a href="q3iconviewitem.html" class="compat">Q3IconViewItem</a>, reimplement this function, and return the text of the item. If you do this, you must call <a href="q3iconviewitem.html#calcRect">calcRect</a>() manually each time the text (and therefore its size) changes.</p>
<p><b>See also </b><a href="q3iconviewitem.html#setText">setText</a>().</p>
<!-- @@@text -->
<!-- $$$textRect[overload1]$$$textRectbool -->
<h3 class="fn"><a name="textRect"></a><span class="type"><a href="qrect.html">QRect</a></span> Q3IconViewItem::<span class="name">textRect</span> ( <span class="type">bool</span> <i>relative</i> = true ) const</h3>
<p>Returns the bounding rectangle of the item's text.</p>
<p>If <i>relative</i> is true, (the default), the returned rectangle is relative to the origin of the item's rectangle. If <i>relative</i> is false, the returned rectangle is relative to the origin of the icon view's contents coordinate system.</p>
<p><b>See also </b><a href="q3iconviewitem.html#setTextRect">setTextRect</a>().</p>
<!-- @@@textRect -->
<!-- $$$width[overload1]$$$width -->
<h3 class="fn"><a name="width"></a><span class="type">int</span> Q3IconViewItem::<span class="name">width</span> () const</h3>
<p>Returns the width of the item.</p>
<!-- @@@width -->
<!-- $$$x[overload1]$$$x -->
<h3 class="fn"><a name="x"></a><span class="type">int</span> Q3IconViewItem::<span class="name">x</span> () const</h3>
<p>Returns the x-coordinate of the item (in contents coordinates).</p>
<!-- @@@x -->
<!-- $$$y[overload1]$$$y -->
<h3 class="fn"><a name="y"></a><span class="type">int</span> Q3IconViewItem::<span class="name">y</span> () const</h3>
<p>Returns the y-coordinate of the item (in contents coordinates).</p>
<!-- @@@y -->
</div>
      </div>
    </div>
    </div> 
    <div class="ft">
      <span></span>
    </div>
  </div> 
  <div class="footer">
    <p>
      <acronym title="Copyright">&copy;</acronym> 2013 Digia Plc and/or its
      subsidiaries. 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>
      Digia, Qt and their respective logos are trademarks of Digia Plc 
      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>