Sophie

Sophie

distrib > Mageia > 7 > i586 > by-pkgid > 1dd17e0d683ef79b4bb6872bbf359d7f > files > 5677

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" />
<!-- qlistwidget.cpp -->
  <title>Qt 4.8: QListWidgetItem 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><a href="qtgui.html">QtGui</a></li>
<li>QListWidgetItem</li>
            </ul>
          </div>
          <div class="toolbuttons toolblock">
            <ul>
              <li id="smallA" class="t_button">A</li>
              <li id="medA" class="t_button active">A</li>
              <li id="bigA" class="t_button">A</li>
              <li id="print" class="t_button"><a href="javascript:this.print();">
                <span>Print</span></a></li>
            </ul>
        </div>
        </div>
        <div class="content mainContent">
<div class="toc">
<h3><a name="toc">Contents</a></h3>
<ul>
<li class="level1"><a href="#public-types">Public Types</a></li>
<li class="level1"><a href="#public-functions">Public Functions</a></li>
<li class="level1"><a href="#related-non-members">Related Non-Members</a></li>
<li class="level1"><a href="#details">Detailed Description</a></li>
<li class="level2"><a href="#subclassing">Subclassing</a></li>
</ul>
</div>
<h1 class="title">QListWidgetItem Class Reference</h1>
<!-- $$$QListWidgetItem-brief -->
<p>The QListWidgetItem class provides an item for use with the <a href="qlistwidget.html">QListWidget</a> item view class. <a href="#details">More...</a></p>
<!-- @@@QListWidgetItem -->
<pre class="cpp"> <span class="preprocessor">#include &lt;QListWidgetItem&gt;</span></pre><ul>
<li><a href="qlistwidgetitem-members.html">List of all members, including inherited members</a></li>
<li><a href="qlistwidgetitem-obsolete.html">Obsolete members</a></li>
</ul>
<a name="public-types"></a>
<h2>Public Types</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> enum </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#ItemType-enum">ItemType</a></b> { Type, UserType }</td></tr>
</table>
<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="qlistwidgetitem.html#QListWidgetItem">QListWidgetItem</a></b> ( QListWidget * <i>parent</i> = 0, int <i>type</i> = Type )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#QListWidgetItem-2">QListWidgetItem</a></b> ( const QString &amp; <i>text</i>, QListWidget * <i>parent</i> = 0, int <i>type</i> = Type )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#QListWidgetItem-3">QListWidgetItem</a></b> ( const QIcon &amp; <i>icon</i>, const QString &amp; <i>text</i>, QListWidget * <i>parent</i> = 0, int <i>type</i> = Type )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#QListWidgetItem-4">QListWidgetItem</a></b> ( const QListWidgetItem &amp; <i>other</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#dtor.QListWidgetItem">~QListWidgetItem</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QBrush </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#background">background</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> Qt::CheckState </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#checkState">checkState</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual QListWidgetItem * </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#clone">clone</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual QVariant </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#data">data</a></b> ( int <i>role</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> Qt::ItemFlags </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#flags">flags</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QFont </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#font">font</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QBrush </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#foreground">foreground</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QIcon </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#icon">icon</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#isHidden">isHidden</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#isSelected">isSelected</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QListWidget * </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#listWidget">listWidget</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#read">read</a></b> ( QDataStream &amp; <i>in</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setBackground">setBackground</a></b> ( const QBrush &amp; <i>brush</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setCheckState">setCheckState</a></b> ( Qt::CheckState <i>state</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setData">setData</a></b> ( int <i>role</i>, const QVariant &amp; <i>value</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setFlags">setFlags</a></b> ( Qt::ItemFlags <i>flags</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setFont">setFont</a></b> ( const QFont &amp; <i>font</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setForeground">setForeground</a></b> ( const QBrush &amp; <i>brush</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setHidden">setHidden</a></b> ( bool <i>hide</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setIcon">setIcon</a></b> ( const QIcon &amp; <i>icon</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setSelected">setSelected</a></b> ( bool <i>select</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setSizeHint">setSizeHint</a></b> ( const QSize &amp; <i>size</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setStatusTip">setStatusTip</a></b> ( const QString &amp; <i>statusTip</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setText">setText</a></b> ( const QString &amp; <i>text</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setTextAlignment">setTextAlignment</a></b> ( int <i>alignment</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setToolTip">setToolTip</a></b> ( const QString &amp; <i>toolTip</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#setWhatsThis">setWhatsThis</a></b> ( const QString &amp; <i>whatsThis</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QSize </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#sizeHint">sizeHint</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QString </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#statusTip">statusTip</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QString </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#text">text</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#textAlignment">textAlignment</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QString </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#toolTip">toolTip</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#type">type</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QString </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#whatsThis">whatsThis</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#write">write</a></b> ( QDataStream &amp; <i>out</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual bool </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#operator-lt">operator&lt;</a></b> ( const QListWidgetItem &amp; <i>other</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QListWidgetItem &amp; </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#operator-eq">operator=</a></b> ( const QListWidgetItem &amp; <i>other</i> )</td></tr>
</table>
<a name="related-non-members"></a>
<h2>Related Non-Members</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> QDataStream &amp; </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#operator-lt-lt-143">operator&lt;&lt;</a></b> ( QDataStream &amp; <i>out</i>, const QListWidgetItem &amp; <i>item</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QDataStream &amp; </td><td class="memItemRight bottomAlign"><b><a href="qlistwidgetitem.html#operator-gt-gt-76">operator&gt;&gt;</a></b> ( QDataStream &amp; <i>in</i>, QListWidgetItem &amp; <i>item</i> )</td></tr>
</table>
<a name="details"></a>
<!-- $$$QListWidgetItem-description -->
<div class="descr">
<h2>Detailed Description</h2>
<p>The QListWidgetItem class provides an item for use with the <a href="qlistwidget.html">QListWidget</a> item view class.</p>
<p>A QListWidgetItem represents a single item in a <a href="qlistwidget.html">QListWidget</a>. Each item can hold several pieces of information, and will display them appropriately.</p>
<p>The item view convenience classes use a classic item-based interface rather than a pure model/view approach. For a more flexible list view widget, consider using the <a href="qlistview.html">QListView</a> class with a standard model.</p>
<p>List items can be inserted automatically into a list, when they are constructed, by specifying the list widget:</p>
<pre class="cpp">     <span class="keyword">new</span> <span class="type">QListWidgetItem</span>(tr(<span class="string">&quot;Hazel&quot;</span>)<span class="operator">,</span> listWidget);</pre>
<p>Alternatively, list items can also be created without a parent widget, and later inserted into a list using <a href="qlistwidget.html#insertItem">QListWidget::insertItem</a>().</p>
<p>List items are typically used to display <a href="qlistwidgetitem.html#text">text</a>() and an <a href="qlistwidgetitem.html#icon">icon</a>(). These are set with the <a href="qlistwidgetitem.html#setText">setText</a>() and <a href="qlistwidgetitem.html#setIcon">setIcon</a>() functions. The appearance of the text can be customized with <a href="qlistwidgetitem.html#setFont">setFont</a>(), <a href="qlistwidgetitem.html#setForeground">setForeground</a>(), and <a href="qlistwidgetitem.html#setBackground">setBackground</a>(). Text in list items can be aligned using the <a href="qlistwidgetitem.html#setTextAlignment">setTextAlignment</a>() function. Tooltips, status tips and &quot;What's This?&quot; help can be added to list items with <a href="qlistwidgetitem.html#setToolTip">setToolTip</a>(), <a href="qlistwidgetitem.html#setStatusTip">setStatusTip</a>(), and <a href="qlistwidgetitem.html#setWhatsThis">setWhatsThis</a>().</p>
<p>By default, items are enabled, selectable, checkable, and can be the source of drag and drop operations.</p>
<p>Each item's flags can be changed by calling <a href="qlistwidgetitem.html#setFlags">setFlags</a>() with the appropriate value (see <a href="qt.html#ItemFlag-enum">Qt::ItemFlags</a>). Checkable items can be checked, unchecked and partially checked with the <a href="qlistwidgetitem.html#setCheckState">setCheckState</a>() function. The corresponding <a href="qlistwidgetitem.html#checkState">checkState</a>() function indicates the item's current check state.</p>
<p>The <a href="qlistwidgetitem.html#isHidden">isHidden</a>() function can be used to determine whether the item is hidden. To hide an item, use <a href="qlistwidgetitem.html#setHidden">setHidden</a>().</p>
<a name="subclassing"></a>
<h3>Subclassing</h3>
<p>When subclassing QListWidgetItem to provide custom items, it is possible to define new types for them enabling them to be distinguished from standard items. For subclasses that require this feature, ensure that you call the base class constructor with a new type value equal to or greater than <a href="qlistwidgetitem.html#ItemType-enum">UserType</a>, within <i>your</i> constructor.</p>
</div>
<p><b>See also </b><a href="qlistwidget.html">QListWidget</a>, <a href="model-view-programming.html">Model/View Programming</a>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, and <a href="qtablewidgetitem.html">QTableWidgetItem</a>.</p>
<!-- @@@QListWidgetItem -->
<div class="types">
<h2>Member Type Documentation</h2>
<!-- $$$ItemType$$$Type$$$UserType -->
<h3 class="fn"><a name="ItemType-enum"></a>enum QListWidgetItem::<span class="name">ItemType</span></h3>
<p>This enum describes the types that are used to describe list widget items.</p>
<table class="valuelist"><tr valign="top" class="odd"><th class="tblConst">Constant</th><th class="tblval">Value</th><th class="tbldscr">Description</th></tr>
<tr><td class="topAlign"><tt>QListWidgetItem::Type</tt></td><td class="topAlign"><tt>0</tt></td><td class="topAlign">The default type for list widget items.</td></tr>
<tr><td class="topAlign"><tt>QListWidgetItem::UserType</tt></td><td class="topAlign"><tt>1000</tt></td><td class="topAlign">The minimum value for custom types. Values below UserType are reserved by Qt.</td></tr>
</table>
<p>You can define new user types in <a href="qlistwidgetitem.html">QListWidgetItem</a> subclasses to ensure that custom items are treated specially.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#type">type</a>().</p>
<!-- @@@ItemType -->
</div>
<div class="func">
<h2>Member Function Documentation</h2>
<!-- $$$QListWidgetItem[overload1]$$$QListWidgetItemQListWidget*int -->
<h3 class="fn"><a name="QListWidgetItem"></a>QListWidgetItem::<span class="name">QListWidgetItem</span> ( <span class="type"><a href="qlistwidget.html">QListWidget</a></span> * <i>parent</i> = 0, <span class="type">int</span> <i>type</i> = Type )</h3>
<p>Constructs an empty list widget item of the specified <i>type</i> with the given <i>parent</i>. If <i>parent</i> is not specified, the item will need to be inserted into a list widget with <a href="qlistwidget.html#insertItem">QListWidget::insertItem</a>().</p>
<p>This constructor inserts the item into the model of the parent that is passed to the constructor. If the model is sorted then the behavior of the insert is undetermined since the model will call the <tt>'&lt;'</tt> operator method on the item which, at this point, is not yet constructed. To avoid the undetermined behavior, we recommend not to specify the parent and use <a href="qlistwidget.html#insertItem">QListWidget::insertItem</a>() instead.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#type">type</a>().</p>
<!-- @@@QListWidgetItem -->
<!-- $$$QListWidgetItem$$$QListWidgetItemconstQString&QListWidget*int -->
<h3 class="fn"><a name="QListWidgetItem-2"></a>QListWidgetItem::<span class="name">QListWidgetItem</span> ( const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>text</i>, <span class="type"><a href="qlistwidget.html">QListWidget</a></span> * <i>parent</i> = 0, <span class="type">int</span> <i>type</i> = Type )</h3>
<p>Constructs an empty list widget item of the specified <i>type</i> with the given <i>text</i> and <i>parent</i>. If the parent is not specified, the item will need to be inserted into a list widget with <a href="qlistwidget.html#insertItem">QListWidget::insertItem</a>().</p>
<p>This constructor inserts the item into the model of the parent that is passed to the constructor. If the model is sorted then the behavior of the insert is undetermined since the model will call the <tt>'&lt;'</tt> operator method on the item which, at this point, is not yet constructed. To avoid the undetermined behavior, we recommend not to specify the parent and use <a href="qlistwidget.html#insertItem">QListWidget::insertItem</a>() instead.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#type">type</a>().</p>
<!-- @@@QListWidgetItem -->
<!-- $$$QListWidgetItem$$$QListWidgetItemconstQIcon&constQString&QListWidget*int -->
<h3 class="fn"><a name="QListWidgetItem-3"></a>QListWidgetItem::<span class="name">QListWidgetItem</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>text</i>, <span class="type"><a href="qlistwidget.html">QListWidget</a></span> * <i>parent</i> = 0, <span class="type">int</span> <i>type</i> = Type )</h3>
<p>Constructs an empty list widget item of the specified <i>type</i> with the given <i>icon</i>, <i>text</i> and <i>parent</i>. If the parent is not specified, the item will need to be inserted into a list widget with <a href="qlistwidget.html#insertItem">QListWidget::insertItem</a>().</p>
<p>This constructor inserts the item into the model of the parent that is passed to the constructor. If the model is sorted then the behavior of the insert is undetermined since the model will call the <tt>'&lt;'</tt> operator method on the item which, at this point, is not yet constructed. To avoid the undetermined behavior, we recommend not to specify the parent and use <a href="qlistwidget.html#insertItem">QListWidget::insertItem</a>() instead.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#type">type</a>().</p>
<!-- @@@QListWidgetItem -->
<!-- $$$QListWidgetItem$$$QListWidgetItemconstQListWidgetItem& -->
<h3 class="fn"><a name="QListWidgetItem-4"></a>QListWidgetItem::<span class="name">QListWidgetItem</span> ( const <span class="type">QListWidgetItem</span> &amp; <i>other</i> )</h3>
<p>Constructs a copy of <i>other</i>. Note that <a href="qlistwidgetitem.html#type">type</a>() and <a href="qlistwidgetitem.html#listWidget">listWidget</a>() are not copied.</p>
<p>This function is useful when reimplementing <a href="qlistwidgetitem.html#clone">clone</a>().</p>
<p>This function was introduced in Qt 4.1.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#data">data</a>() and <a href="qlistwidgetitem.html#flags">flags</a>().</p>
<!-- @@@QListWidgetItem -->
<!-- $$$~QListWidgetItem[overload1]$$$~QListWidgetItem -->
<h3 class="fn"><a name="dtor.QListWidgetItem"></a>QListWidgetItem::<span class="name">~QListWidgetItem</span> ()<tt> [virtual]</tt></h3>
<p>Destroys the list item.</p>
<!-- @@@~QListWidgetItem -->
<!-- $$$background[overload1]$$$background -->
<h3 class="fn"><a name="background"></a><span class="type"><a href="qbrush.html">QBrush</a></span> QListWidgetItem::<span class="name">background</span> () const</h3>
<p>Returns the brush used to display the list item's background.</p>
<p>This function was introduced in Qt 4.2.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#setBackground">setBackground</a>() and <a href="qlistwidgetitem.html#foreground">foreground</a>().</p>
<!-- @@@background -->
<!-- $$$checkState[overload1]$$$checkState -->
<h3 class="fn"><a name="checkState"></a><span class="type"><a href="qt.html#CheckState-enum">Qt::CheckState</a></span> QListWidgetItem::<span class="name">checkState</span> () const</h3>
<p>Returns the checked state of the list item (see <a href="qt.html#CheckState-enum">Qt::CheckState</a>).</p>
<p><b>See also </b><a href="qlistwidgetitem.html#setCheckState">setCheckState</a>() and <a href="qlistwidgetitem.html#flags">flags</a>().</p>
<!-- @@@checkState -->
<!-- $$$clone[overload1]$$$clone -->
<h3 class="fn"><a name="clone"></a><span class="type">QListWidgetItem</span> * QListWidgetItem::<span class="name">clone</span> () const<tt> [virtual]</tt></h3>
<p>Creates an exact copy of the item.</p>
<!-- @@@clone -->
<!-- $$$data[overload1]$$$dataint -->
<h3 class="fn"><a name="data"></a><span class="type"><a href="qvariant.html">QVariant</a></span> QListWidgetItem::<span class="name">data</span> ( <span class="type">int</span> <i>role</i> ) const<tt> [virtual]</tt></h3>
<p>Returns the item's data for a given <i>role</i>. Reimplement this function if you need extra roles or special behavior for certain roles.</p>
<p><b>See also </b><a href="qt.html#ItemDataRole-enum">Qt::ItemDataRole</a> and <a href="qlistwidgetitem.html#setData">setData</a>().</p>
<!-- @@@data -->
<!-- $$$flags[overload1]$$$flags -->
<h3 class="fn"><a name="flags"></a><span class="type"><a href="qt.html#ItemFlag-enum">Qt::ItemFlags</a></span> QListWidgetItem::<span class="name">flags</span> () const</h3>
<p>Returns the item flags for this item (see <a href="qt.html#ItemFlag-enum">Qt::ItemFlags</a>).</p>
<p><b>See also </b><a href="qlistwidgetitem.html#setFlags">setFlags</a>().</p>
<!-- @@@flags -->
<!-- $$$font[overload1]$$$font -->
<h3 class="fn"><a name="font"></a><span class="type"><a href="qfont.html">QFont</a></span> QListWidgetItem::<span class="name">font</span> () const</h3>
<p>Returns the font used to display this list item's text.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#setFont">setFont</a>().</p>
<!-- @@@font -->
<!-- $$$foreground[overload1]$$$foreground -->
<h3 class="fn"><a name="foreground"></a><span class="type"><a href="qbrush.html">QBrush</a></span> QListWidgetItem::<span class="name">foreground</span> () const</h3>
<p>Returns the brush used to display the list item's foreground (e.g&#x2e; text).</p>
<p>This function was introduced in Qt 4.2.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#setForeground">setForeground</a>() and <a href="qlistwidgetitem.html#background">background</a>().</p>
<!-- @@@foreground -->
<!-- $$$icon[overload1]$$$icon -->
<h3 class="fn"><a name="icon"></a><span class="type"><a href="qicon.html">QIcon</a></span> QListWidgetItem::<span class="name">icon</span> () const</h3>
<p>Returns the list item's icon.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#setIcon">setIcon</a>() and <a href="qabstractitemview.html#iconSize-prop">iconSize</a>.</p>
<!-- @@@icon -->
<!-- $$$isHidden[overload1]$$$isHidden -->
<h3 class="fn"><a name="isHidden"></a><span class="type">bool</span> QListWidgetItem::<span class="name">isHidden</span> () const</h3>
<p>Returns true if the item is hidden; otherwise returns false.</p>
<p>This function was introduced in Qt 4.2.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#setHidden">setHidden</a>().</p>
<!-- @@@isHidden -->
<!-- $$$isSelected[overload1]$$$isSelected -->
<h3 class="fn"><a name="isSelected"></a><span class="type">bool</span> QListWidgetItem::<span class="name">isSelected</span> () const</h3>
<p>Returns true if the item is selected; otherwise returns false.</p>
<p>This function was introduced in Qt 4.2.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#setSelected">setSelected</a>().</p>
<!-- @@@isSelected -->
<!-- $$$listWidget[overload1]$$$listWidget -->
<h3 class="fn"><a name="listWidget"></a><span class="type"><a href="qlistwidget.html">QListWidget</a></span> * QListWidgetItem::<span class="name">listWidget</span> () const</h3>
<p>Returns the list widget containing the item.</p>
<!-- @@@listWidget -->
<!-- $$$read[overload1]$$$readQDataStream& -->
<h3 class="fn"><a name="read"></a><span class="type">void</span> QListWidgetItem::<span class="name">read</span> ( <span class="type"><a href="qdatastream.html">QDataStream</a></span> &amp; <i>in</i> )<tt> [virtual]</tt></h3>
<p>Reads the item from stream <i>in</i>.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#write">write</a>().</p>
<!-- @@@read -->
<!-- $$$setBackground[overload1]$$$setBackgroundconstQBrush& -->
<h3 class="fn"><a name="setBackground"></a><span class="type">void</span> QListWidgetItem::<span class="name">setBackground</span> ( const <span class="type"><a href="qbrush.html">QBrush</a></span> &amp; <i>brush</i> )</h3>
<p>Sets the background brush of the list item to the given <i>brush</i>.</p>
<p>This function was introduced in Qt 4.2.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#background">background</a>() and <a href="qlistwidgetitem.html#setForeground">setForeground</a>().</p>
<!-- @@@setBackground -->
<!-- $$$setCheckState[overload1]$$$setCheckStateQt::CheckState -->
<h3 class="fn"><a name="setCheckState"></a><span class="type">void</span> QListWidgetItem::<span class="name">setCheckState</span> ( <span class="type"><a href="qt.html#CheckState-enum">Qt::CheckState</a></span> <i>state</i> )</h3>
<p>Sets the check state of the list item to <i>state</i>.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#checkState">checkState</a>().</p>
<!-- @@@setCheckState -->
<!-- $$$setData[overload1]$$$setDataintconstQVariant& -->
<h3 class="fn"><a name="setData"></a><span class="type">void</span> QListWidgetItem::<span class="name">setData</span> ( <span class="type">int</span> <i>role</i>, const <span class="type"><a href="qvariant.html">QVariant</a></span> &amp; <i>value</i> )<tt> [virtual]</tt></h3>
<p>Sets the data for a given <i>role</i> to the given <i>value</i>. Reimplement this function if you need extra roles or special behavior for certain roles.</p>
<p><b>See also </b><a href="qt.html#ItemDataRole-enum">Qt::ItemDataRole</a> and <a href="qlistwidgetitem.html#data">data</a>().</p>
<!-- @@@setData -->
<!-- $$$setFlags[overload1]$$$setFlagsQt::ItemFlags -->
<h3 class="fn"><a name="setFlags"></a><span class="type">void</span> QListWidgetItem::<span class="name">setFlags</span> ( <span class="type"><a href="qt.html#ItemFlag-enum">Qt::ItemFlags</a></span> <i>flags</i> )</h3>
<p>Sets the item flags for the list item to <i>flags</i>.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#flags">flags</a>() and <a href="qt.html#ItemFlag-enum">Qt::ItemFlags</a>.</p>
<!-- @@@setFlags -->
<!-- $$$setFont[overload1]$$$setFontconstQFont& -->
<h3 class="fn"><a name="setFont"></a><span class="type">void</span> QListWidgetItem::<span class="name">setFont</span> ( const <span class="type"><a href="qfont.html">QFont</a></span> &amp; <i>font</i> )</h3>
<p>Sets the font used when painting the item to the given <i>font</i>.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#font">font</a>().</p>
<!-- @@@setFont -->
<!-- $$$setForeground[overload1]$$$setForegroundconstQBrush& -->
<h3 class="fn"><a name="setForeground"></a><span class="type">void</span> QListWidgetItem::<span class="name">setForeground</span> ( const <span class="type"><a href="qbrush.html">QBrush</a></span> &amp; <i>brush</i> )</h3>
<p>Sets the foreground brush of the list item to the given <i>brush</i>.</p>
<p>This function was introduced in Qt 4.2.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#foreground">foreground</a>() and <a href="qlistwidgetitem.html#setBackground">setBackground</a>().</p>
<!-- @@@setForeground -->
<!-- $$$setHidden[overload1]$$$setHiddenbool -->
<h3 class="fn"><a name="setHidden"></a><span class="type">void</span> QListWidgetItem::<span class="name">setHidden</span> ( <span class="type">bool</span> <i>hide</i> )</h3>
<p>Hides the item if <i>hide</i> is true; otherwise shows the item.</p>
<p>This function was introduced in Qt 4.2.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#isHidden">isHidden</a>().</p>
<!-- @@@setHidden -->
<!-- $$$setIcon[overload1]$$$setIconconstQIcon& -->
<h3 class="fn"><a name="setIcon"></a><span class="type">void</span> QListWidgetItem::<span class="name">setIcon</span> ( const <span class="type"><a href="qicon.html">QIcon</a></span> &amp; <i>icon</i> )</h3>
<p>Sets the icon for the list item to the given <i>icon</i>.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#icon">icon</a>(), <a href="qlistwidgetitem.html#text">text</a>(), and <a href="qabstractitemview.html#iconSize-prop">iconSize</a>.</p>
<!-- @@@setIcon -->
<!-- $$$setSelected[overload1]$$$setSelectedbool -->
<h3 class="fn"><a name="setSelected"></a><span class="type">void</span> QListWidgetItem::<span class="name">setSelected</span> ( <span class="type">bool</span> <i>select</i> )</h3>
<p>Sets the selected state of the item to <i>select</i>.</p>
<p>This function was introduced in Qt 4.2.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#isSelected">isSelected</a>().</p>
<!-- @@@setSelected -->
<!-- $$$setSizeHint[overload1]$$$setSizeHintconstQSize& -->
<h3 class="fn"><a name="setSizeHint"></a><span class="type">void</span> QListWidgetItem::<span class="name">setSizeHint</span> ( const <span class="type"><a href="qsize.html">QSize</a></span> &amp; <i>size</i> )</h3>
<p>Sets the size hint for the list item to be <i>size</i>. If no size hint is set, the item delegate will compute the size hint based on the item data.</p>
<p>This function was introduced in Qt 4.1.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#sizeHint">sizeHint</a>().</p>
<!-- @@@setSizeHint -->
<!-- $$$setStatusTip[overload1]$$$setStatusTipconstQString& -->
<h3 class="fn"><a name="setStatusTip"></a><span class="type">void</span> QListWidgetItem::<span class="name">setStatusTip</span> ( const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>statusTip</i> )</h3>
<p>Sets the status tip for the list item to the text specified by <i>statusTip</i>. <a href="qlistwidget.html">QListWidget</a> mouseTracking needs to be enabled for this feature to work.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#statusTip">statusTip</a>(), <a href="qlistwidgetitem.html#setToolTip">setToolTip</a>(), <a href="qlistwidgetitem.html#setWhatsThis">setWhatsThis</a>(), and <a href="qwidget.html#mouseTracking-prop">QWidget::setMouseTracking</a>().</p>
<!-- @@@setStatusTip -->
<!-- $$$setText[overload1]$$$setTextconstQString& -->
<h3 class="fn"><a name="setText"></a><span class="type">void</span> QListWidgetItem::<span class="name">setText</span> ( const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>text</i> )</h3>
<p>Sets the text for the list widget item's to the given <i>text</i>.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#text">text</a>().</p>
<!-- @@@setText -->
<!-- $$$setTextAlignment[overload1]$$$setTextAlignmentint -->
<h3 class="fn"><a name="setTextAlignment"></a><span class="type">void</span> QListWidgetItem::<span class="name">setTextAlignment</span> ( <span class="type">int</span> <i>alignment</i> )</h3>
<p>Sets the list item's text alignment to <i>alignment</i>.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#textAlignment">textAlignment</a>() and <a href="qt.html#AlignmentFlag-enum">Qt::AlignmentFlag</a>.</p>
<!-- @@@setTextAlignment -->
<!-- $$$setToolTip[overload1]$$$setToolTipconstQString& -->
<h3 class="fn"><a name="setToolTip"></a><span class="type">void</span> QListWidgetItem::<span class="name">setToolTip</span> ( const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>toolTip</i> )</h3>
<p>Sets the tooltip for the list item to the text specified by <i>toolTip</i>.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#toolTip">toolTip</a>(), <a href="qlistwidgetitem.html#setStatusTip">setStatusTip</a>(), and <a href="qlistwidgetitem.html#setWhatsThis">setWhatsThis</a>().</p>
<!-- @@@setToolTip -->
<!-- $$$setWhatsThis[overload1]$$$setWhatsThisconstQString& -->
<h3 class="fn"><a name="setWhatsThis"></a><span class="type">void</span> QListWidgetItem::<span class="name">setWhatsThis</span> ( const <span class="type"><a href="qstring.html">QString</a></span> &amp; <i>whatsThis</i> )</h3>
<p>Sets the &quot;What's This?&quot; help for the list item to the text specified by <i>whatsThis</i>.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#whatsThis">whatsThis</a>(), <a href="qlistwidgetitem.html#setStatusTip">setStatusTip</a>(), and <a href="qlistwidgetitem.html#setToolTip">setToolTip</a>().</p>
<!-- @@@setWhatsThis -->
<!-- $$$sizeHint[overload1]$$$sizeHint -->
<h3 class="fn"><a name="sizeHint"></a><span class="type"><a href="qsize.html">QSize</a></span> QListWidgetItem::<span class="name">sizeHint</span> () const</h3>
<p>Returns the size hint set for the list item.</p>
<p>This function was introduced in Qt 4.1.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#setSizeHint">setSizeHint</a>().</p>
<!-- @@@sizeHint -->
<!-- $$$statusTip[overload1]$$$statusTip -->
<h3 class="fn"><a name="statusTip"></a><span class="type"><a href="qstring.html">QString</a></span> QListWidgetItem::<span class="name">statusTip</span> () const</h3>
<p>Returns the list item's status tip.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#setStatusTip">setStatusTip</a>().</p>
<!-- @@@statusTip -->
<!-- $$$text[overload1]$$$text -->
<h3 class="fn"><a name="text"></a><span class="type"><a href="qstring.html">QString</a></span> QListWidgetItem::<span class="name">text</span> () const</h3>
<p>Returns the list item's text.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#setText">setText</a>().</p>
<!-- @@@text -->
<!-- $$$textAlignment[overload1]$$$textAlignment -->
<h3 class="fn"><a name="textAlignment"></a><span class="type">int</span> QListWidgetItem::<span class="name">textAlignment</span> () const</h3>
<p>Returns the text alignment for the list item.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#setTextAlignment">setTextAlignment</a>() and <a href="qt.html#AlignmentFlag-enum">Qt::AlignmentFlag</a>.</p>
<!-- @@@textAlignment -->
<!-- $$$toolTip[overload1]$$$toolTip -->
<h3 class="fn"><a name="toolTip"></a><span class="type"><a href="qstring.html">QString</a></span> QListWidgetItem::<span class="name">toolTip</span> () const</h3>
<p>Returns the list item's tooltip.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#setToolTip">setToolTip</a>(), <a href="qlistwidgetitem.html#statusTip">statusTip</a>(), and <a href="qlistwidgetitem.html#whatsThis">whatsThis</a>().</p>
<!-- @@@toolTip -->
<!-- $$$type[overload1]$$$type -->
<h3 class="fn"><a name="type"></a><span class="type">int</span> QListWidgetItem::<span class="name">type</span> () const</h3>
<p>Returns the type passed to the <a href="qlistwidgetitem.html">QListWidgetItem</a> constructor.</p>
<!-- @@@type -->
<!-- $$$whatsThis[overload1]$$$whatsThis -->
<h3 class="fn"><a name="whatsThis"></a><span class="type"><a href="qstring.html">QString</a></span> QListWidgetItem::<span class="name">whatsThis</span> () const</h3>
<p>Returns the list item's &quot;What's This?&quot; help text.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#setWhatsThis">setWhatsThis</a>(), <a href="qlistwidgetitem.html#statusTip">statusTip</a>(), and <a href="qlistwidgetitem.html#toolTip">toolTip</a>().</p>
<!-- @@@whatsThis -->
<!-- $$$write[overload1]$$$writeQDataStream& -->
<h3 class="fn"><a name="write"></a><span class="type">void</span> QListWidgetItem::<span class="name">write</span> ( <span class="type"><a href="qdatastream.html">QDataStream</a></span> &amp; <i>out</i> ) const<tt> [virtual]</tt></h3>
<p>Writes the item to stream <i>out</i>.</p>
<p><b>See also </b><a href="qlistwidgetitem.html#read">read</a>().</p>
<!-- @@@write -->
<!-- $$$operator<[overload1]$$$operator<constQListWidgetItem& -->
<h3 class="fn"><a name="operator-lt"></a><span class="type">bool</span> QListWidgetItem::<span class="name">operator&lt;</span> ( const <span class="type">QListWidgetItem</span> &amp; <i>other</i> ) const<tt> [virtual]</tt></h3>
<p>Returns true if this item's text is less then <i>other</i> item's text; otherwise returns false.</p>
<!-- @@@operator< -->
<!-- $$$operator=[overload1]$$$operator=constQListWidgetItem& -->
<h3 class="fn"><a name="operator-eq"></a><span class="type">QListWidgetItem</span> &amp; QListWidgetItem::<span class="name">operator=</span> ( const <span class="type">QListWidgetItem</span> &amp; <i>other</i> )</h3>
<p>Assigns <i>other</i>'s data and flags to this item. Note that <a href="qlistwidgetitem.html#type">type</a>() and <a href="qlistwidgetitem.html#listWidget">listWidget</a>() are not copied.</p>
<p>This function is useful when reimplementing <a href="qlistwidgetitem.html#clone">clone</a>().</p>
<p><b>See also </b><a href="qlistwidgetitem.html#data">data</a>() and <a href="qlistwidgetitem.html#flags">flags</a>().</p>
<!-- @@@operator= -->
</div>
<div class="relnonmem">
<h2>Related Non-Members</h2>
<!-- $$$operator<<$$$operator<<QDataStream&constQListWidgetItem& -->
<h3 class="fn"><a name="operator-lt-lt-143"></a><span class="type"><a href="qdatastream.html">QDataStream</a></span> &amp; <span class="name">operator&lt;&lt;</span> ( <span class="type"><a href="qdatastream.html">QDataStream</a></span> &amp; <i>out</i>, const <span class="type">QListWidgetItem</span> &amp; <i>item</i> )</h3>
<p>Writes the list widget item <i>item</i> to stream <i>out</i>.</p>
<p>This operator uses <a href="qlistwidgetitem.html#write">QListWidgetItem::write</a>().</p>
<p><b>See also </b><a href="datastreamformat.html">Serializing Qt Data Types</a>.</p>
<!-- @@@operator<< -->
<!-- $$$operator>>$$$operator>>QDataStream&QListWidgetItem& -->
<h3 class="fn"><a name="operator-gt-gt-76"></a><span class="type"><a href="qdatastream.html">QDataStream</a></span> &amp; <span class="name">operator&gt;&gt;</span> ( <span class="type"><a href="qdatastream.html">QDataStream</a></span> &amp; <i>in</i>, <span class="type">QListWidgetItem</span> &amp; <i>item</i> )</h3>
<p>Reads a list widget item from stream <i>in</i> into <i>item</i>.</p>
<p>This operator uses <a href="qlistwidgetitem.html#read">QListWidgetItem::read</a>().</p>
<p><b>See also </b><a href="datastreamformat.html">Serializing Qt Data Types</a>.</p>
<!-- @@@operator>> -->
</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>