1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215
|
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd">
<html><head><title>QTreeWidget Class Reference</title><style>h3.fn,span.fn { margin-left: 1cm; text-indent: -1cm }
a:link { color: #004faf; text-decoration: none }
a:visited { color: #672967; text-decoration: none }
td.postheader { font-family: sans-serif }
tr.address { font-family: sans-serif }
body { background: #ffffff; color: black; }
</style></head><body><table border="0" cellpadding="0" cellspacing="0" width="100%"><tr /><td align="left" valign="top" width="32"><img align="left" border="0" height="32" src="images/rb-logo.png" width="32" /></td><td width="1">  </td><td class="postheader" valign="center"><a href="../pyqt4ref.html"><font color="#004faf">Home</font></a> · <a href="classes.html"><font color="#004faf">All Classes</font></a> · <a href="modules.html"><font color="#004faf">Modules</font></a></td></table><h1 align="center">QTreeWidget Class Reference<br /><sup><sup>[<a href="qtgui.html">QtGui</a> module]</sup></sup></h1><p>The QTreeWidget class provides a tree view that uses a predefined tree model. <a href="#details">More...</a></p>
<p>Inherits <a href="qtreeview.html">QTreeView</a>.</p><h3>Methods</h3><ul><li><div class="fn" /><b><a href="qtreewidget.html#QTreeWidget">__init__</a></b> (<i>self</i>, QWidget <i>parent</i> = None)</li><li><div class="fn" /><b><a href="qtreewidget.html#addTopLevelItem">addTopLevelItem</a></b> (<i>self</i>, QTreeWidgetItem)</li><li><div class="fn" /><b><a href="qtreewidget.html#addTopLevelItems">addTopLevelItems</a></b> (<i>self</i>, list-of-QTreeWidgetItem)</li><li><div class="fn" /><b><a href="qtreewidget.html#clear">clear</a></b> (<i>self</i>)</li><li><div class="fn" /><b><a href="qtreewidget.html#closePersistentEditor">closePersistentEditor</a></b> (<i>self</i>, QTreeWidgetItem, int <i>column</i> = 0)</li><li><div class="fn" /><b><a href="qtreewidget.html#collapseItem">collapseItem</a></b> (<i>self</i>, QTreeWidgetItem)</li><li><div class="fn" />int <b><a href="qtreewidget.html#columnCount">columnCount</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qtreewidget.html#currentColumn">currentColumn</a></b> (<i>self</i>)</li><li><div class="fn" />QTreeWidgetItem <b><a href="qtreewidget.html#currentItem">currentItem</a></b> (<i>self</i>)</li><li><div class="fn" /><b><a href="qtreewidget.html#dropEvent">dropEvent</a></b> (<i>self</i>, QDropEvent)</li><li><div class="fn" />bool <b><a href="qtreewidget.html#dropMimeData">dropMimeData</a></b> (<i>self</i>, QTreeWidgetItem, int, QMimeData, Qt.DropAction)</li><li><div class="fn" /><b><a href="qtreewidget.html#editItem">editItem</a></b> (<i>self</i>, QTreeWidgetItem, int <i>column</i> = 0)</li><li><div class="fn" />bool <b><a href="qtreewidget.html#event">event</a></b> (<i>self</i>, QEvent)</li><li><div class="fn" /><b><a href="qtreewidget.html#expandItem">expandItem</a></b> (<i>self</i>, QTreeWidgetItem)</li><li><div class="fn" />list-of-QTreeWidgetItem <b><a href="qtreewidget.html#findItems">findItems</a></b> (<i>self</i>, QString, Qt.MatchFlags, int <i>column</i> = 0)</li><li><div class="fn" />QTreeWidgetItem <b><a href="qtreewidget.html#headerItem">headerItem</a></b> (<i>self</i>)</li><li><div class="fn" />QModelIndex <b><a href="qtreewidget.html#indexFromItem">indexFromItem</a></b> (<i>self</i>, QTreeWidgetItem, int <i>column</i> = 0)</li><li><div class="fn" />int <b><a href="qtreewidget.html#indexOfTopLevelItem">indexOfTopLevelItem</a></b> (<i>self</i>, QTreeWidgetItem)</li><li><div class="fn" /><b><a href="qtreewidget.html#insertTopLevelItem">insertTopLevelItem</a></b> (<i>self</i>, int, QTreeWidgetItem)</li><li><div class="fn" /><b><a href="qtreewidget.html#insertTopLevelItems">insertTopLevelItems</a></b> (<i>self</i>, int, list-of-QTreeWidgetItem)</li><li><div class="fn" />QTreeWidgetItem <b><a href="qtreewidget.html#invisibleRootItem">invisibleRootItem</a></b> (<i>self</i>)</li><li><div class="fn" />bool <b><a href="qtreewidget.html#isFirstItemColumnSpanned">isFirstItemColumnSpanned</a></b> (<i>self</i>, QTreeWidgetItem)</li><li><div class="fn" />bool <b><a href="qtreewidget.html#isItemExpanded">isItemExpanded</a></b> (<i>self</i>, QTreeWidgetItem)</li><li><div class="fn" />bool <b><a href="qtreewidget.html#isItemHidden">isItemHidden</a></b> (<i>self</i>, QTreeWidgetItem)</li><li><div class="fn" />bool <b><a href="qtreewidget.html#isItemSelected">isItemSelected</a></b> (<i>self</i>, QTreeWidgetItem)</li><li><div class="fn" />bool <b><a href="qtreewidget.html#isSortingEnabled">isSortingEnabled</a></b> (<i>self</i>)</li><li><div class="fn" />QTreeWidgetItem <b><a href="qtreewidget.html#itemAbove">itemAbove</a></b> (<i>self</i>, QTreeWidgetItem)</li><li><div class="fn" />QTreeWidgetItem <b><a href="qtreewidget.html#itemAt">itemAt</a></b> (<i>self</i>, QPoint)</li><li><div class="fn" />QTreeWidgetItem <b><a href="qtreewidget.html#itemAt-2">itemAt</a></b> (<i>self</i>, int, int)</li><li><div class="fn" />QTreeWidgetItem <b><a href="qtreewidget.html#itemBelow">itemBelow</a></b> (<i>self</i>, QTreeWidgetItem)</li><li><div class="fn" />QTreeWidgetItem <b><a href="qtreewidget.html#itemFromIndex">itemFromIndex</a></b> (<i>self</i>, QModelIndex)</li><li><div class="fn" />list-of-QTreeWidgetItem <b><a href="qtreewidget.html#items">items</a></b> (<i>self</i>, QMimeData)</li><li><div class="fn" />QWidget <b><a href="qtreewidget.html#itemWidget">itemWidget</a></b> (<i>self</i>, QTreeWidgetItem, int)</li><li><div class="fn" />QMimeData <b><a href="qtreewidget.html#mimeData">mimeData</a></b> (<i>self</i>, list-of-QTreeWidgetItem)</li><li><div class="fn" />QStringList <b><a href="qtreewidget.html#mimeTypes">mimeTypes</a></b> (<i>self</i>)</li><li><div class="fn" /><b><a href="qtreewidget.html#openPersistentEditor">openPersistentEditor</a></b> (<i>self</i>, QTreeWidgetItem, int <i>column</i> = 0)</li><li><div class="fn" /><b><a href="qtreewidget.html#removeItemWidget">removeItemWidget</a></b> (<i>self</i>, QTreeWidgetItem, int)</li><li><div class="fn" /><b><a href="qtreewidget.html#scrollToItem">scrollToItem</a></b> (<i>self</i>, QTreeWidgetItem, QAbstractItemView.ScrollHint <i>hint</i> = QAbstractItemView.EnsureVisible)</li><li><div class="fn" />list-of-QTreeWidgetItem <b><a href="qtreewidget.html#selectedItems">selectedItems</a></b> (<i>self</i>)</li><li><div class="fn" /><b><a href="qtreewidget.html#setColumnCount">setColumnCount</a></b> (<i>self</i>, int)</li><li><div class="fn" /><b><a href="qtreewidget.html#setCurrentItem">setCurrentItem</a></b> (<i>self</i>, QTreeWidgetItem)</li><li><div class="fn" /><b><a href="qtreewidget.html#setCurrentItem-2">setCurrentItem</a></b> (<i>self</i>, QTreeWidgetItem, int)</li><li><div class="fn" /><b><a href="qtreewidget.html#setCurrentItem-3">setCurrentItem</a></b> (<i>self</i>, QTreeWidgetItem, int, QItemSelectionModel.SelectionFlags)</li><li><div class="fn" /><b><a href="qtreewidget.html#setFirstItemColumnSpanned">setFirstItemColumnSpanned</a></b> (<i>self</i>, QTreeWidgetItem, bool)</li><li><div class="fn" /><b><a href="qtreewidget.html#setHeaderItem">setHeaderItem</a></b> (<i>self</i>, QTreeWidgetItem)</li><li><div class="fn" /><b><a href="qtreewidget.html#setHeaderLabel">setHeaderLabel</a></b> (<i>self</i>, QString)</li><li><div class="fn" /><b><a href="qtreewidget.html#setHeaderLabels">setHeaderLabels</a></b> (<i>self</i>, QStringList)</li><li><div class="fn" /><b><a href="qtreewidget.html#setItemExpanded">setItemExpanded</a></b> (<i>self</i>, QTreeWidgetItem, bool)</li><li><div class="fn" /><b><a href="qtreewidget.html#setItemHidden">setItemHidden</a></b> (<i>self</i>, QTreeWidgetItem, bool)</li><li><div class="fn" /><b><a href="qtreewidget.html#setItemSelected">setItemSelected</a></b> (<i>self</i>, QTreeWidgetItem, bool)</li><li><div class="fn" /><b><a href="qtreewidget.html#setItemWidget">setItemWidget</a></b> (<i>self</i>, QTreeWidgetItem, int, QWidget)</li><li><div class="fn" /><b><a href="qtreewidget.html#setSelectionModel">setSelectionModel</a></b> (<i>self</i>, QItemSelectionModel)</li><li><div class="fn" /><b><a href="qtreewidget.html#setSortingEnabled">setSortingEnabled</a></b> (<i>self</i>, bool)</li><li><div class="fn" />int <b><a href="qtreewidget.html#sortColumn">sortColumn</a></b> (<i>self</i>)</li><li><div class="fn" /><b><a href="qtreewidget.html#sortItems">sortItems</a></b> (<i>self</i>, int, Qt.SortOrder)</li><li><div class="fn" />Qt.DropActions <b><a href="qtreewidget.html#supportedDropActions">supportedDropActions</a></b> (<i>self</i>)</li><li><div class="fn" />QTreeWidgetItem <b><a href="qtreewidget.html#takeTopLevelItem">takeTopLevelItem</a></b> (<i>self</i>, int)</li><li><div class="fn" />QTreeWidgetItem <b><a href="qtreewidget.html#topLevelItem">topLevelItem</a></b> (<i>self</i>, int)</li><li><div class="fn" />int <b><a href="qtreewidget.html#topLevelItemCount">topLevelItemCount</a></b> (<i>self</i>)</li><li><div class="fn" />QRect <b><a href="qtreewidget.html#visualItemRect">visualItemRect</a></b> (<i>self</i>, QTreeWidgetItem)</li></ul><h3>Qt Signals</h3><ul><li><div class="fn" />void <b><a href="qtreewidget.html#currentItemChanged">currentItemChanged</a></b> (QTreeWidgetItem *,QTreeWidgetItem *)</li><li><div class="fn" />void <b><a href="qtreewidget.html#itemActivated">itemActivated</a></b> (QTreeWidgetItem *,int)</li><li><div class="fn" />void <b><a href="qtreewidget.html#itemChanged">itemChanged</a></b> (QTreeWidgetItem *,int)</li><li><div class="fn" />void <b><a href="qtreewidget.html#itemClicked">itemClicked</a></b> (QTreeWidgetItem *,int)</li><li><div class="fn" />void <b><a href="qtreewidget.html#itemCollapsed">itemCollapsed</a></b> (QTreeWidgetItem *)</li><li><div class="fn" />void <b><a href="qtreewidget.html#itemDoubleClicked">itemDoubleClicked</a></b> (QTreeWidgetItem *,int)</li><li><div class="fn" />void <b><a href="qtreewidget.html#itemEntered">itemEntered</a></b> (QTreeWidgetItem *,int)</li><li><div class="fn" />void <b><a href="qtreewidget.html#itemExpanded">itemExpanded</a></b> (QTreeWidgetItem *)</li><li><div class="fn" />void <b><a href="qtreewidget.html#itemPressed">itemPressed</a></b> (QTreeWidgetItem *,int)</li><li><div class="fn" />void <b><a href="qtreewidget.html#itemSelectionChanged">itemSelectionChanged</a></b> ()</li></ul><a name="details" /><hr /><h2>Detailed Description</h2><p>The QTreeWidget class provides a tree view that uses a predefined tree model.</p>
<p>The QTreeWidget class is a convenience class that provides a standard tree widget with a classic item-based interface similar to that used by the <a href="qlistview.html">QListView</a> class in Qt 3. This class is based on Qt's Model/View architecture and uses a default model to hold items, each of which is a <a href="qtreewidgetitem.html">QTreeWidgetItem</a>.</p>
<p>Developers who do not need the flexibility of the Model/View framework can use this class to create simple hierarchical lists very easily. A more flexible approach involves combining a <a href="qtreeview.html">QTreeView</a> with a standard item model. This allows the storage of data to be separated from its representation.</p>
<p>In its simplest form, a tree widget can be constructed in the following way:</p>
<pre> QTreeWidget *treeWidget = new QTreeWidget();
treeWidget->setColumnCount(1);
QList<QTreeWidgetItem *> items;
for (int i = 0; i < 10; ++i)
items.append(new QTreeWidgetItem((QTreeWidget*)0, QStringList(QString("item: %1").arg(i))));
treeWidget->insertTopLevelItems(0, items);</pre>
<p>Before items can be added to the tree widget, the number of columns must be set with <a href="qtreewidget.html#columnCount-prop">setColumnCount</a>(). This allows each item to have one or more labels or other decorations. The number of columns in use can be found with the <a href="qtreewidget.html#columnCount-prop">columnCount</a>() function.</p>
<p>The tree can have a header that contains a section for each column in the widget. It is easiest to set up the labels for each section by supplying a list of strings with <a href="qtreewidget.html#setHeaderLabels">setHeaderLabels</a>(), but a custom header can be constructed with a <a href="qtreewidgetitem.html">QTreeWidgetItem</a> and inserted into the tree with the <a href="qtreewidget.html#setHeaderItem">setHeaderItem</a>() function.</p>
<p>The items in the tree can be sorted by column according to a predefined sort order. If sorting is enabled, the user can sort the items by clicking on a column header. Sorting can be enabled or disabled by calling <a href="qtreeview.html#sortingEnabled-prop">setSortingEnabled()</a>. The <a href="qtreeview.html#sortingEnabled-prop">isSortingEnabled()</a> function indicates whether sorting is enabled.</p>
<p><table align="center" border="0" cellpadding="2" cellspacing="1" class="generic" width="100%">
<tr class="odd" valign="top"><td><img alt="Screenshot of a Windows XP style tree widget" src="images/windowsxp-treeview.png" /></td><td><img alt="Screenshot of a Macintosh style tree widget" src="images/macintosh-treeview.png" /></td><td><img alt="Screenshot of a Plastique style tree widget" src="images/plastique-treeview.png" /></td></tr>
<tr class="even" valign="top"><td>A <a href="gallery-windowsxp.html">Windows XP style</a> tree widget.</td><td>A <a href="gallery-macintosh.html">Macintosh style</a> tree widget.</td><td>A <a href="gallery-plastique.html">Plastique style</a> tree widget.</td></tr>
</table></p>
<p>See also <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, <a href="qtreewidgetitemiterator.html">QTreeWidgetItemIterator</a>, <a href="qtreeview.html">QTreeView</a>, <a href="model-view-programming.html">Model/View Programming</a>, and <a href="tools-settingseditor.html">Settings Editor Example</a>.</p>
<hr /><h2>Method Documentation</h2><h3 class="fn"><a name="QTreeWidget" />QTreeWidget.__init__ (<i>self</i>, <a href="qwidget.html">QWidget</a> <i>parent</i> = None)</h3><p>The <i>parent</i> argument, if not None, causes <i>self</i> to be owned by Qt instead of PyQt.</p><p>Constructs a tree widget with the given <i>parent</i>.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/~QTreeWidget" />
<h3 class="fn"><a name="addTopLevelItem" />QTreeWidget.addTopLevelItem (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>)</h3><p>The <i>QTreeWidgetItem</i> argument has it's ownership transferred to Qt.</p><p>Appends the <i>item</i> as a top-level item in the widget.</p>
<p>This function was introduced in Qt 4.1.</p>
<p>See also <a href="qtreewidget.html#insertTopLevelItem">insertTopLevelItem</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/addTopLevelItems" />
<h3 class="fn"><a name="addTopLevelItems" />QTreeWidget.addTopLevelItems (<i>self</i>, list-of-QTreeWidgetItem)</h3><p>The <i>list-of-QTreeWidgetItem</i> argument has it's ownership transferred to Qt.</p><p>Appends the list of <i>items</i> as a top-level items in the widget.</p>
<p>See also <a href="qtreewidget.html#insertTopLevelItems">insertTopLevelItems</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/clear" />
<h3 class="fn"><a name="clear" />QTreeWidget.clear (<i>self</i>)</h3><p>This method is also a Qt slot with the C++ signature <tt>void clear()</tt>.</p><p>Clears the tree widget by removing all of its items and selections.</p>
<p><b>Note:</b> Since each item is removed from the tree widget before being deleted, the return value of <a href="qtreewidgetitem.html#treeWidget">QTreeWidgetItem.treeWidget</a>() will be invalid when called from an item's destructor.</p>
<p>See also <a href="qtreewidget.html#takeTopLevelItem">takeTopLevelItem</a>(), <a href="qtreewidget.html#topLevelItemCount-prop">topLevelItemCount</a>(), and <a href="qtreewidget.html#columnCount-prop">columnCount</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/closePersistentEditor" />
<h3 class="fn"><a name="closePersistentEditor" />QTreeWidget.closePersistentEditor (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, int <i>column</i> = 0)</h3><p>Closes the persistent editor for the <i>item</i> in the given <i>column</i>.</p>
<p>This function has no effect if no persistent editor is open for this combination of item and column.</p>
<p>See also <a href="qtreewidget.html#openPersistentEditor">openPersistentEditor</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/collapseItem" />
<h3 class="fn"><a name="collapseItem" />QTreeWidget.collapseItem (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>)</h3><p>This method is also a Qt slot with the C++ signature <tt>void collapseItem(const QTreeWidgetItem *)</tt>.</p><p>Closes the <i>item</i>. This causes the tree containing the item's children to be collapsed.</p>
<p>See also <a href="qtreewidget.html#expandItem">expandItem</a>(), <a href="qtreewidget.html#currentItem">currentItem</a>(), <a href="qtreewidget.html#itemAt">itemAt</a>(), and <a href="qtreewidget.html#topLevelItem">topLevelItem</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/currentColumn" />
<h3 class="fn"><a name="columnCount" />int QTreeWidget.columnCount (<i>self</i>)</h3><h3 class="fn"><a name="currentColumn" />int QTreeWidget.currentColumn (<i>self</i>)</h3><p>Returns the current column in the tree widget.</p>
<p>This function was introduced in Qt 4.1.</p>
<p>See also <a href="qtreewidget.html#setCurrentItem">setCurrentItem</a>() and <a href="qtreewidget.html#columnCount-prop">columnCount</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/currentItem" />
<h3 class="fn"><a name="currentItem" /><a href="qtreewidgetitem.html">QTreeWidgetItem</a> QTreeWidget.currentItem (<i>self</i>)</h3><p>Returns the current item in the tree widget.</p>
<p>See also <a href="qtreewidget.html#setCurrentItem">setCurrentItem</a>() and <a href="qtreewidget.html#currentItemChanged">currentItemChanged</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/currentItemChanged" />
<h3 class="fn"><a name="dropEvent" />QTreeWidget.dropEvent (<i>self</i>, <a href="qdropevent.html">QDropEvent</a>)</h3><p>Reimplemented from <a href="qwidget.html#dropEvent">QWidget.dropEvent</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/dropMimeData" />
<h3 class="fn"><a name="dropMimeData" />bool QTreeWidget.dropMimeData (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, int, <a href="qmimedata.html">QMimeData</a>, <a href="qt.html#DropAction-enum">Qt.DropAction</a>)</h3><p>Handles the <i>data</i> supplied by a drag and drop operation that ended with the given <i>action</i> in the <i>index</i> in the given <i>parent</i> item.</p>
<p>The default implementation returns true if the drop was successfully handled by decoding the mime data and inserting it into the model; otherwise it returns false.</p>
<p>See also <a href="qtreewidget.html#supportedDropActions">supportedDropActions</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/editItem" />
<h3 class="fn"><a name="editItem" />QTreeWidget.editItem (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, int <i>column</i> = 0)</h3><p>Starts editing the <i>item</i> in the given <i>column</i> if it is editable.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/event" />
<h3 class="fn"><a name="event" />bool QTreeWidget.event (<i>self</i>, <a href="qevent.html">QEvent</a>)</h3><p>Reimplemented from <a href="qobject.html#event">QObject.event</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/expandItem" />
<h3 class="fn"><a name="expandItem" />QTreeWidget.expandItem (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>)</h3><p>This method is also a Qt slot with the C++ signature <tt>void expandItem(const QTreeWidgetItem *)</tt>.</p><p>Expands the <i>item</i>. This causes the tree containing the item's children to be expanded.</p>
<p>See also <a href="qtreewidget.html#collapseItem">collapseItem</a>(), <a href="qtreewidget.html#currentItem">currentItem</a>(), <a href="qtreewidget.html#itemAt">itemAt</a>(), <a href="qtreewidget.html#topLevelItem">topLevelItem</a>(), and <a href="qtreewidget.html#itemExpanded">itemExpanded</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/findItems" />
<h3 class="fn"><a name="findItems" />list-of-QTreeWidgetItem QTreeWidget.findItems (<i>self</i>, QString, <a href="qt-matchflags.html">Qt.MatchFlags</a>, int <i>column</i> = 0)</h3><p>Returns a list of items that match the given <i>text</i>, using the given <i>flags</i>, in the given <i>column</i>.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/headerItem" />
<h3 class="fn"><a name="headerItem" /><a href="qtreewidgetitem.html">QTreeWidgetItem</a> QTreeWidget.headerItem (<i>self</i>)</h3><p>Returns the item used for the tree widget's header.</p>
<p>See also <a href="qtreewidget.html#setHeaderItem">setHeaderItem</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/indexFromItem" />
<h3 class="fn"><a name="indexFromItem" /><a href="qmodelindex.html">QModelIndex</a> QTreeWidget.indexFromItem (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, int <i>column</i> = 0)</h3><p>Returns the <a href="qmodelindex.html">QModelIndex</a> assocated with the given <i>item</i> in the given <i>column</i>.</p>
<p>See also <a href="qtreewidget.html#itemFromIndex">itemFromIndex</a>() and <a href="qtreewidget.html#topLevelItem">topLevelItem</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/indexOfTopLevelItem" />
<h3 class="fn"><a name="indexOfTopLevelItem" />int QTreeWidget.indexOfTopLevelItem (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>)</h3><p>Returns the index of the given top-level <i>item</i>, or -1 if the item cannot be found.</p>
<p>See also <a href="qtreewidget.html#sortItems">sortItems</a>() and <a href="qtreewidget.html#topLevelItemCount-prop">topLevelItemCount</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/insertTopLevelItem" />
<h3 class="fn"><a name="insertTopLevelItem" />QTreeWidget.insertTopLevelItem (<i>self</i>, int, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>)</h3><p>The <i>QTreeWidgetItem</i> argument has it's ownership transferred to Qt.</p><p>Inserts the <i>item</i> at <i>index</i> in the top level in the view.</p>
<p>If the item has already been inserted somewhere else it wont be inserted.</p>
<p>See also <a href="qtreewidget.html#addTopLevelItem">addTopLevelItem</a>() and <a href="qtreewidget.html#columnCount-prop">columnCount</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/insertTopLevelItems" />
<h3 class="fn"><a name="insertTopLevelItems" />QTreeWidget.insertTopLevelItems (<i>self</i>, int, list-of-QTreeWidgetItem)</h3><p>The <i>list-of-QTreeWidgetItem</i> argument has it's ownership transferred to Qt.</p><p>Inserts the list of <i>items</i> at <i>index</i> in the top level in the view.</p>
<p>Items that have already been inserted somewhere else wont be inserted.</p>
<p>This function was introduced in Qt 4.1.</p>
<p>See also <a href="qtreewidget.html#addTopLevelItems">addTopLevelItems</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/invisibleRootItem" />
<h3 class="fn"><a name="invisibleRootItem" /><a href="qtreewidgetitem.html">QTreeWidgetItem</a> QTreeWidget.invisibleRootItem (<i>self</i>)</h3><p>Returns the tree widget's invisible root item.</p>
<p>The invisible root item provides access to the tree widget's top-level items through the <a href="qtreewidgetitem.html">QTreeWidgetItem</a> API, making it possible to write functions that can treat top-level items and their children in a uniform way; for example, recursive functions.</p>
<p>This function was introduced in Qt 4.2.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/isFirstItemColumnSpanned" />
<h3 class="fn"><a name="isFirstItemColumnSpanned" />bool QTreeWidget.isFirstItemColumnSpanned (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>)</h3><p>Returns true if the given <i>item</i> is set to show only one section over all columns; otherwise returns false.</p>
<p>This function was introduced in Qt 4.3.</p>
<p>See also <a href="qtreewidget.html#setFirstItemColumnSpanned">setFirstItemColumnSpanned</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/itemAbove" />
<h3 class="fn"><a name="isItemExpanded" />bool QTreeWidget.isItemExpanded (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>)</h3><h3 class="fn"><a name="isItemHidden" />bool QTreeWidget.isItemHidden (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>)</h3><h3 class="fn"><a name="isItemSelected" />bool QTreeWidget.isItemSelected (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>)</h3><h3 class="fn"><a name="isSortingEnabled" />bool QTreeWidget.isSortingEnabled (<i>self</i>)</h3><h3 class="fn"><a name="itemAbove" /><a href="qtreewidgetitem.html">QTreeWidgetItem</a> QTreeWidget.itemAbove (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>)</h3><p>Returns the item above the given <i>item</i>.</p>
<p>This function was introduced in Qt 4.3.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/itemActivated" />
<h3 class="fn"><a name="itemAt" /><a href="qtreewidgetitem.html">QTreeWidgetItem</a> QTreeWidget.itemAt (<i>self</i>, <a href="qpoint.html">QPoint</a>)</h3><p>Returns a pointer to the item at the coordinates <i>p</i>.</p>
<p>See also <a href="qtreewidget.html#visualItemRect">visualItemRect</a>().</p>
<h3 class="fn"><a name="itemAt-2" /><a href="qtreewidgetitem.html">QTreeWidgetItem</a> QTreeWidget.itemAt (<i>self</i>, int, int)</h3><p>This is an overloaded function.</p>
<p>Returns a pointer to the item at the coordinates (<i>x</i>, <i>y</i>).</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/itemBelow" />
<h3 class="fn"><a name="itemBelow" /><a href="qtreewidgetitem.html">QTreeWidgetItem</a> QTreeWidget.itemBelow (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>)</h3><p>Returns the item visually below the given <i>item</i>.</p>
<p>This function was introduced in Qt 4.3.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/itemChanged" />
<h3 class="fn"><a name="itemFromIndex" /><a href="qtreewidgetitem.html">QTreeWidgetItem</a> QTreeWidget.itemFromIndex (<i>self</i>, <a href="qmodelindex.html">QModelIndex</a>)</h3><p>Returns a pointer to the <a href="qtreewidgetitem.html">QTreeWidgetItem</a> assocated with the given <i>index</i>.</p>
<p>See also <a href="qtreewidget.html#indexFromItem">indexFromItem</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/itemPressed" />
<h3 class="fn"><a name="items" />list-of-QTreeWidgetItem QTreeWidget.items (<i>self</i>, <a href="qmimedata.html">QMimeData</a>)</h3><h3 class="fn"><a name="itemWidget" /><a href="qwidget.html">QWidget</a> QTreeWidget.itemWidget (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, int)</h3><p>Returns the widget displayed in the cell specified by <i>item</i> and the given <i>column</i>.</p>
<p><b>Note:</b> The tree takes ownership of the widget.</p>
<p>This function was introduced in Qt 4.1.</p>
<p>See also <a href="qtreewidget.html#setItemWidget">setItemWidget</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/mimeData" />
<h3 class="fn"><a name="mimeData" /><a href="qmimedata.html">QMimeData</a> QTreeWidget.mimeData (<i>self</i>, list-of-QTreeWidgetItem)</h3><p>The <i>QMimeData</i> result</p><p>Returns an object that contains a serialized description of the specified <i>items</i>. The format used to describe the items is obtained from the <a href="qtreewidget.html#mimeTypes">mimeTypes</a>() function.</p>
<p>If the list of items is empty, 0 is returned rather than a serialized empty list.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/mimeTypes" />
<h3 class="fn"><a name="mimeTypes" />QStringList QTreeWidget.mimeTypes (<i>self</i>)</h3><p>Returns a list of MIME types that can be used to describe a list of treewidget items.</p>
<p>See also <a href="qtreewidget.html#mimeData">mimeData</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/openPersistentEditor" />
<h3 class="fn"><a name="openPersistentEditor" />QTreeWidget.openPersistentEditor (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, int <i>column</i> = 0)</h3><p>Opens a persistent editor for the <i>item</i> in the given <i>column</i>.</p>
<p>See also <a href="qtreewidget.html#closePersistentEditor">closePersistentEditor</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/removeItemWidget" />
<h3 class="fn"><a name="removeItemWidget" />QTreeWidget.removeItemWidget (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, int)</h3><p>The <i>QTreeWidgetItem</i> argument</p><p>Removes the widget set in the given <i>item</i> in the given <i>column</i>.</p>
<p>This function was introduced in Qt 4.3.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/scrollToItem" />
<h3 class="fn"><a name="scrollToItem" />QTreeWidget.scrollToItem (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, <a href="qabstractitemview.html#ScrollHint-enum">QAbstractItemView.ScrollHint</a> <i>hint</i> = QAbstractItemView.EnsureVisible)</h3><p>This method is also a Qt slot with the C++ signature <tt>void scrollToItem(const QTreeWidgetItem *,QAbstractItemView::ScrollHint = QAbstractItemView.EnsureVisible)</tt>.</p><p>Ensures that the <i>item</i> is visible, scrolling the view if necessary using the specified <i>hint</i>.</p>
<p>See also <a href="qtreewidget.html#currentItem">currentItem</a>(), <a href="qtreewidget.html#itemAt">itemAt</a>(), and <a href="qtreewidget.html#topLevelItem">topLevelItem</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/selectedItems" />
<h3 class="fn"><a name="selectedItems" />list-of-QTreeWidgetItem QTreeWidget.selectedItems (<i>self</i>)</h3><p>Returns a list of all selected non-hidden items.</p>
<p>See also <a href="qtreewidget.html#itemSelectionChanged">itemSelectionChanged</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/setCurrentItem" />
<h3 class="fn"><a name="setColumnCount" />QTreeWidget.setColumnCount (<i>self</i>, int)</h3><h3 class="fn"><a name="setCurrentItem" />QTreeWidget.setCurrentItem (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>)</h3><p>Sets the current <i>item</i> in the tree widget.</p>
<p>Unless the selection mode is <a href="qabstractitemview.html#SelectionMode-enum">NoSelection</a>, the item is also be selected.</p>
<p>See also <a href="qtreewidget.html#currentItem">currentItem</a>() and <a href="qtreewidget.html#currentItemChanged">currentItemChanged</a>().</p>
<h3 class="fn"><a name="setCurrentItem-2" />QTreeWidget.setCurrentItem (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, int)</h3><p>Sets the current <i>item</i> in the tree widget and the current column to <i>column</i>.</p>
<p>This function was introduced in Qt 4.1.</p>
<p>See also <a href="qtreewidget.html#currentItem">currentItem</a>().</p>
<h3 class="fn"><a name="setCurrentItem-3" />QTreeWidget.setCurrentItem (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, int, <a href="qitemselectionmodel-selectionflags.html">QItemSelectionModel.SelectionFlags</a>)</h3><p>Sets the current <i>item</i> in the tree widget and the current column to <i>column</i>, using the given <i>command</i>.</p>
<p>This function was introduced in Qt 4.4.</p>
<p>See also <a href="qtreewidget.html#currentItem">currentItem</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/setFirstItemColumnSpanned" />
<h3 class="fn"><a name="setFirstItemColumnSpanned" />QTreeWidget.setFirstItemColumnSpanned (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, bool)</h3><p>Sets the given <i>item</i> to only show one section for all columns if <i>span</i> is true; otherwise the item will show one section per column.</p>
<p>This function was introduced in Qt 4.3.</p>
<p>See also <a href="qtreewidget.html#isFirstItemColumnSpanned">isFirstItemColumnSpanned</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/setHeaderItem" />
<h3 class="fn"><a name="setHeaderItem" />QTreeWidget.setHeaderItem (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>)</h3><p>Sets the header <i>item</i> for the tree widget. The label for each column in the header is supplied by the corresponding label in the item.</p>
<p>The tree widget takes ownership of the item.</p>
<p>See also <a href="qtreewidget.html#headerItem">headerItem</a>() and <a href="qtreewidget.html#setHeaderLabels">setHeaderLabels</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/setHeaderLabel" />
<h3 class="fn"><a name="setHeaderLabel" />QTreeWidget.setHeaderLabel (<i>self</i>, QString)</h3><p>Same as setHeaderLabels(<a href="qstringlist.html">QStringList</a>(<i>label</i>)).</p>
<p>This function was introduced in Qt 4.2.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/setHeaderLabels" />
<h3 class="fn"><a name="setHeaderLabels" />QTreeWidget.setHeaderLabels (<i>self</i>, QStringList)</h3><p>Adds a column in the header for each item in the <i>labels</i> list, and sets the label for each column.</p>
<p>Note that setHeaderLabels() won't remove existing columns.</p>
<p>See also <a href="qtreewidget.html#setHeaderItem">setHeaderItem</a>() and <a href="qtreewidget.html#setHeaderLabel">setHeaderLabel</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/setItemWidget" />
<h3 class="fn"><a name="setItemExpanded" />QTreeWidget.setItemExpanded (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, bool)</h3><h3 class="fn"><a name="setItemHidden" />QTreeWidget.setItemHidden (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, bool)</h3><h3 class="fn"><a name="setItemSelected" />QTreeWidget.setItemSelected (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, bool)</h3><h3 class="fn"><a name="setItemWidget" />QTreeWidget.setItemWidget (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>, int, <a href="qwidget.html">QWidget</a>)</h3><p>The <i>QWidget</i> argument has it's ownership transferred to Qt.</p><p>Sets the given <i>widget</i> to be displayed in the cell specified by the given <i>item</i> and <i>column</i>.</p>
<p>The given <i>widget</i>'s <a href="qwidget.html#autoFillBackground-prop">autoFillBackground</a> property must be set to true, otherwise the widget's background will be transparent, showing both the model data and the tree widget item.</p>
<p>This function should only be used to display static content in the place of a tree widget item. If you want to display custom dynamic content or implement a custom editor widget, use <a href="qtreeview.html">QTreeView</a> and subclass <a href="qitemdelegate.html">QItemDelegate</a> instead.</p>
<p>This function cannot be called before the item hierarchy has been set up, i.e., the <a href="qtreewidgetitem.html">QTreeWidgetItem</a> that will hold <i>widget</i> must have been added to the view before <i>widget</i> is set.</p>
<p><b>Note:</b> The tree takes ownership of the widget.</p>
<p>This function was introduced in Qt 4.1.</p>
<p>See also <a href="qtreewidget.html#itemWidget">itemWidget</a>() and <a href="model-view-delegate.html">Delegate Classes</a>.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/setSelectionModel" />
<h3 class="fn"><a name="setSelectionModel" />QTreeWidget.setSelectionModel (<i>self</i>, <a href="qitemselectionmodel.html">QItemSelectionModel</a>)</h3><p>Reimplemented from <a href="qabstractitemview.html#setSelectionModel">QAbstractItemView.setSelectionModel</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/sortColumn" />
<h3 class="fn"><a name="setSortingEnabled" />QTreeWidget.setSortingEnabled (<i>self</i>, bool)</h3><h3 class="fn"><a name="sortColumn" />int QTreeWidget.sortColumn (<i>self</i>)</h3><p>Returns the column used to sort the contents of the widget.</p>
<p>This function was introduced in Qt 4.1.</p>
<p>See also <a href="qtreewidget.html#sortItems">sortItems</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/sortItems" />
<h3 class="fn"><a name="sortItems" />QTreeWidget.sortItems (<i>self</i>, int, <a href="qt.html#SortOrder-enum">Qt.SortOrder</a>)</h3><p>Sorts the items in the widget in the specified <i>order</i> by the values in the given <i>column</i>.</p>
<p>See also <a href="qtreewidget.html#sortColumn">sortColumn</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/supportedDropActions" />
<h3 class="fn"><a name="supportedDropActions" /><a href="qt-dropactions.html">Qt.DropActions</a> QTreeWidget.supportedDropActions (<i>self</i>)</h3><p>Returns the drop actions supported by this view.</p>
<p>See also <a href="qt.html#DropAction-enum">Qt.DropActions</a>.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/takeTopLevelItem" />
<h3 class="fn"><a name="takeTopLevelItem" /><a href="qtreewidgetitem.html">QTreeWidgetItem</a> QTreeWidget.takeTopLevelItem (<i>self</i>, int)</h3><p>The <i>QTreeWidgetItem</i> result</p><p>Removes the top-level item at the given <i>index</i> in the tree and returns it, otherwise returns 0;</p>
<p>See also <a href="qtreewidget.html#insertTopLevelItem">insertTopLevelItem</a>(), <a href="qtreewidget.html#topLevelItem">topLevelItem</a>(), and <a href="qtreewidget.html#topLevelItemCount-prop">topLevelItemCount</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/topLevelItem" />
<h3 class="fn"><a name="topLevelItem" /><a href="qtreewidgetitem.html">QTreeWidgetItem</a> QTreeWidget.topLevelItem (<i>self</i>, int)</h3><p>Returns the top level item at the given <i>index</i>, or 0 if the item does not exist.</p>
<p>See also <a href="qtreewidget.html#topLevelItemCount-prop">topLevelItemCount</a>() and <a href="qtreewidget.html#insertTopLevelItem">insertTopLevelItem</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/visualItemRect" />
<h3 class="fn"><a name="topLevelItemCount" />int QTreeWidget.topLevelItemCount (<i>self</i>)</h3><h3 class="fn"><a name="visualItemRect" /><a href="qrect.html">QRect</a> QTreeWidget.visualItemRect (<i>self</i>, <a href="qtreewidgetitem.html">QTreeWidgetItem</a>)</h3><p>Returns the rectangle on the viewport occupied by the item at <i>item</i>.</p>
<p>See also <a href="qtreewidget.html#itemAt">itemAt</a>().</p>
<p /><hr /><h2>Qt Signal Documentation</h2><h3 class="fn"><a name="currentItemChanged" />void currentItemChanged (QTreeWidgetItem *,QTreeWidgetItem *)</h3><p>This is the default overload of this signal.</p><p>This signal is emitted when the current item changes. The current item is specified by <i>current</i>, and this replaces the <i>previous</i> current item.</p>
<p>See also <a href="qtreewidget.html#setCurrentItem">setCurrentItem</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/dropEvent" />
<h3 class="fn"><a name="itemActivated" />void itemActivated (QTreeWidgetItem *,int)</h3><p>This is the default overload of this signal.</p><p>This signal is emitted when the user activates an item by single- or double-clicking (depending on the platform, i.e. on the <a href="qstyle.html#StyleHint-enum">QStyle.SH_ItemView_ActivateItemOnSingleClick</a> style hint) or pressing a special key (e.g., <b>Enter</b>).</p>
<p>The specified <i>item</i> is the item that was clicked, or 0 if no item was clicked. The <i>column</i> is the item's column that was clicked, or -1 if no item was clicked.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/itemAt" />
<h3 class="fn"><a name="itemChanged" />void itemChanged (QTreeWidgetItem *,int)</h3><p>This is the default overload of this signal.</p><p>This signal is emitted when the contents of the <i>column</i> in the specified <i>item</i> changes.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/itemClicked" />
<h3 class="fn"><a name="itemClicked" />void itemClicked (QTreeWidgetItem *,int)</h3><p>This is the default overload of this signal.</p><p>This signal is emitted when the user clicks inside the widget.</p>
<p>The specified <i>item</i> is the item that was clicked. The <i>column</i> is the item's column that was clicked. If no item was clicked, no signal will be emitted.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/itemCollapsed" />
<h3 class="fn"><a name="itemCollapsed" />void itemCollapsed (QTreeWidgetItem *)</h3><p>This is the default overload of this signal.</p><p>This signal is emitted when the specified <i>item</i> is collapsed so that none of its children are displayed.</p>
<p><b>Note:</b> This signal will not be emitted if an item changes its state when <a href="qtreeview.html#collapseAll">collapseAll</a>() is invoked.</p>
<p>See also <a href="qtreewidgetitem.html#isExpanded">QTreeWidgetItem.isExpanded</a>(), <a href="qtreewidget.html#itemExpanded">itemExpanded</a>(), and <a href="qtreewidget.html#collapseItem">collapseItem</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/itemDoubleClicked" />
<h3 class="fn"><a name="itemDoubleClicked" />void itemDoubleClicked (QTreeWidgetItem *,int)</h3><p>This is the default overload of this signal.</p><p>This signal is emitted when the user double clicks inside the widget.</p>
<p>The specified <i>item</i> is the item that was clicked, or 0 if no item was clicked. The <i>column</i> is the item's column that was clicked. If no item was double clicked, no signal will be emitted.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/itemEntered" />
<h3 class="fn"><a name="itemEntered" />void itemEntered (QTreeWidgetItem *,int)</h3><p>This is the default overload of this signal.</p><p>This signal is emitted when the mouse cursor enters an <i>item</i> over the specified <i>column</i>. <a href="qtreewidget.html">QTreeWidget</a> mouse tracking needs to be enabled for this feature to work.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/itemExpanded" />
<h3 class="fn"><a name="itemExpanded" />void itemExpanded (QTreeWidgetItem *)</h3><p>This is the default overload of this signal.</p><p>This signal is emitted when the specified <i>item</i> is expanded so that all of its children are displayed.</p>
<p><b>Note:</b> This signal will not be emitted if an item changes its state when <a href="qtreeview.html#expandAll">expandAll</a>() is invoked.</p>
<p>See also <a class="obsolete" href="qtreewidget-obsolete.html#setItemExpanded">setItemExpanded</a>(), <a href="qtreewidgetitem.html#isExpanded">QTreeWidgetItem.isExpanded</a>(), <a href="qtreewidget.html#itemCollapsed">itemCollapsed</a>(), and <a href="qtreewidget.html#expandItem">expandItem</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/itemFromIndex" />
<h3 class="fn"><a name="itemPressed" />void itemPressed (QTreeWidgetItem *,int)</h3><p>This is the default overload of this signal.</p><p>This signal is emitted when the user presses a mouse button inside the widget.</p>
<p>The specified <i>item</i> is the item that was clicked, or 0 if no item was clicked. The <i>column</i> is the item's column that was clicked, or -1 if no item was clicked.</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/itemSelectionChanged" />
<h3 class="fn"><a name="itemSelectionChanged" />void itemSelectionChanged ()</h3><p>This is the default overload of this signal.</p><p>This signal is emitted when the selection changes in the tree widget. The current selection can be found with <a href="qtreewidget.html#selectedItems">selectedItems</a>().</p>
<a name="//apple_ref/cpp/instm/QTreeWidget/itemWidget" />
<address><hr /><div align="center"><table border="0" cellspacing="0" width="100%"><tr class="address"><td align="left" width="25%">PyQt 4.7.3 for X11</td><td align="center" width="50%">Copyright © <a href="http://www.riverbankcomputing.com">Riverbank Computing Ltd</a> and <a href="http://www.qtsoftware.com">Nokia</a> 2010</td><td align="right" width="25%">Qt 4.6.2</td></tr></table></div></address></body></html>
|