<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <title>gtkmm: Gtk::TreeRow Class Reference</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <link href="doxygen.css" rel="stylesheet" type="text/css"/> </head> <body> <!-- Generated by Doxygen 1.7.3 --> <div id="top"> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td style="padding-left: 0.5em;"> <div id="projectname">gtkmm <span id="projectnumber">2.24.4</span></div> </td> </tr> </tbody> </table> </div> <div id="navrow1" class="tabs"> <ul class="tablist"> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="modules.html"><span>Modules</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li class="current"><a href="annotated.html"><span>Classes</span></a></li> </ul> </div> <div id="navrow2" class="tabs2"> <ul class="tablist"> <li><a href="annotated.html"><span>Class List</span></a></li> <li><a href="classes.html"><span>Class Index</span></a></li> <li><a href="inherits.html"><span>Class Hierarchy</span></a></li> <li><a href="functions.html"><span>Class Members</span></a></li> </ul> </div> <div id="nav-path" class="navpath"> <ul> <li class="navelem"><a class="el" href="namespaceGtk.html">Gtk</a> </li> <li class="navelem"><a class="el" href="classGtk_1_1TreeRow.html">TreeRow</a> </li> </ul> </div> </div> <div class="header"> <div class="summary"> <a href="#pub-methods">Public Member Functions</a> </div> <div class="headertitle"> <h1>Gtk::TreeRow Class Reference<div class="ingroups"><a class="el" href="group__TreeView.html">TreeView Classes</a></div></h1> </div> </div> <div class="contents"> <!-- doxytag: class="Gtk::TreeRow" --><!-- doxytag: inherits="Gtk::TreeIter" --> <p>Typedefed as <a class="el" href="classGtk_1_1TreeModel.html#a297c9db68905e82fe7c3fac57f6c4de8">TreeModel::Row</a>. <a href="#_details">More...</a></p> <div class="dynheader"> Inheritance diagram for Gtk::TreeRow:</div> <div class="dyncontent"> <div class="center"><img src="classGtk_1_1TreeRow__inherit__graph.png" border="0" usemap="#Gtk_1_1TreeRow_inherit__map" alt="Inheritance graph"/></div> <map name="Gtk_1_1TreeRow_inherit__map" id="Gtk_1_1TreeRow_inherit__map"> <area shape="rect" id="node2" href="classGtk_1_1TreeIter.html" title="A Gtk::TreeModel::iterator is a reference to a specific node on a specific model." alt="" coords="21,83,120,112"/><area shape="rect" id="node4" href="classGtk_1_1TreeIterBase.html" title="Gtk::TreeIterBase" alt="" coords="5,5,136,35"/></map> <center><span class="legend">[<a href="graph_legend.html">legend</a>]</span></center></div> <div class="dynheader"> Collaboration diagram for Gtk::TreeRow:</div> <div class="dyncontent"> <div class="center"><img src="classGtk_1_1TreeRow__coll__graph.png" border="0" usemap="#Gtk_1_1TreeRow_coll__map" alt="Collaboration graph"/></div> <map name="Gtk_1_1TreeRow_coll__map" id="Gtk_1_1TreeRow_coll__map"> <area shape="rect" id="node2" href="classGtk_1_1TreeIter.html" title="A Gtk::TreeModel::iterator is a reference to a specific node on a specific model." alt="" coords="21,83,120,112"/><area shape="rect" id="node4" href="classGtk_1_1TreeIterBase.html" title="Gtk::TreeIterBase" alt="" coords="5,5,136,35"/></map> <center><span class="legend">[<a href="graph_legend.html">legend</a>]</span></center></div> <p><a href="classGtk_1_1TreeRow-members.html">List of all members.</a></p> <table class="memberdecls"> <tr><td colspan="2"><h2><a name="pub-methods"></a> Public Member Functions</h2></td></tr> <tr><td class="memTemplParams" colspan="2">template<class ColumnType > </td></tr> <tr><td class="memTemplItemLeft" align="right" valign="top"><a class="el" href="classGtk_1_1TreeValueProxy.html">TreeValueProxy</a>< ColumnType > </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classGtk_1_1TreeRow.html#ad1880375e2c3b45a6ba69b225dd7f6a4">operator[]</a> (const <a class="el" href="classGtk_1_1TreeModelColumn.html">TreeModelColumn</a>< ColumnType >& column) const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Use this to set and get the value of this <em>column</em> of this row. <a href="#ad1880375e2c3b45a6ba69b225dd7f6a4"></a><br/></td></tr> <tr><td class="memTemplParams" colspan="2">template<class ColumnType > </td></tr> <tr><td class="memTemplItemLeft" align="right" valign="top">void </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classGtk_1_1TreeRow.html#ae25785fc6de538f6dd632bb434a5f2ff">set_value</a> (const <a class="el" href="classGtk_1_1TreeModelColumn.html">TreeModelColumn</a>< ColumnType >& column, const ColumnType& data) const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the value of this <em>column</em> of this row. <a href="#ae25785fc6de538f6dd632bb434a5f2ff"></a><br/></td></tr> <tr><td class="memTemplParams" colspan="2">template<class ColumnType > </td></tr> <tr><td class="memTemplItemLeft" align="right" valign="top">void </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classGtk_1_1TreeRow.html#abc6ffaec37d8bde03d94c39218390065">set_value</a> (int column, const ColumnType& data) const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Use set_value(const TreeModelColumn<>& column, const ColumnType& data) unless you do not know the column type at compile-time. <a href="#abc6ffaec37d8bde03d94c39218390065"></a><br/></td></tr> <tr><td class="memTemplParams" colspan="2">template<class ColumnType > </td></tr> <tr><td class="memTemplItemLeft" align="right" valign="top">ColumnType </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classGtk_1_1TreeRow.html#a193b7d490eed8f7e25aa70d73d746f6a">get_value</a> (const <a class="el" href="classGtk_1_1TreeModelColumn.html">TreeModelColumn</a>< ColumnType >& column) const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Gets the value of this <em>column</em> of this row. <a href="#a193b7d490eed8f7e25aa70d73d746f6a"></a><br/></td></tr> <tr><td class="memTemplParams" colspan="2">template<class ColumnType > </td></tr> <tr><td class="memTemplItemLeft" align="right" valign="top">void </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classGtk_1_1TreeRow.html#a9b1db0af89cc50bb0b16a1daf8d5c5e1">get_value</a> (int column, ColumnType& data) const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Use get_value(const TreeModelColumn<>& column) unless you do not know the column type at compile-time. <a href="#a9b1db0af89cc50bb0b16a1daf8d5c5e1"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">const <a class="el" href="classGtk_1_1TreeNodeChildren.html">TreeNodeChildren</a>& </td><td class="memItemRight" valign="bottom"><a class="el" href="classGtk_1_1TreeRow.html#a334dc0b2d96c219e24de467d3fcbd091">children</a> () const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">This returns an STL-like container API, for iterating over the rows. <a href="#a334dc0b2d96c219e24de467d3fcbd091"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classGtk_1_1TreeIter.html">TreeIter</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classGtk_1_1TreeRow.html#a9d55079617fc05a849af189b657e7679">parent</a> () const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Gets an iterator to the parent row of this row. <a href="#a9d55079617fc05a849af189b657e7679"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classGtk_1_1TreeRow.html#a256d9c1def321f1968c2f01299781e14">operator bool</a> () const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Discover whether this is a valid row. <a href="#a256d9c1def321f1968c2f01299781e14"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">GtkTreeIter* </td><td class="memItemRight" valign="bottom"><a class="el" href="classGtk_1_1TreeRow.html#a70f407de60552e0270ed73471ad07cd1">gobj</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Provides access to the underlying C GObject. <a href="#a70f407de60552e0270ed73471ad07cd1"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">const GtkTreeIter* </td><td class="memItemRight" valign="bottom"><a class="el" href="classGtk_1_1TreeRow.html#aabd78b5aa80816c10b49d51f797ce7b7">gobj</a> () const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Provides access to the underlying C GObject. <a href="#aabd78b5aa80816c10b49d51f797ce7b7"></a><br/></td></tr> </table> <hr/><a name="_details"></a><h2>Detailed Description</h2> <div class="textblock"><p>Typedefed as <a class="el" href="classGtk_1_1TreeModel.html#a297c9db68905e82fe7c3fac57f6c4de8">TreeModel::Row</a>. </p> <p>Dereference a <a class="el" href="classGtk_1_1TreeModel.html#a754e74cd833ff30e729f9b8d7daf4d8c">TreeModel::iterator</a> to get the Row. Use operator[] or <a class="el" href="classGtk_1_1TreeRow.html#ae25785fc6de538f6dd632bb434a5f2ff" title="Sets the value of this column of this row.">set_value()</a> and <a class="el" href="classGtk_1_1TreeRow.html#a193b7d490eed8f7e25aa70d73d746f6a" title="Gets the value of this column of this row.">get_value()</a> to access the values in the columns of this row.</p> <p>If the model contains a hierarchy of rows (such as <a class="el" href="classGtk_1_1TreeStore.html">Gtk::TreeStore</a>), then you can access the child rows with <a class="el" href="classGtk_1_1TreeRow.html#a334dc0b2d96c219e24de467d3fcbd091" title="This returns an STL-like container API, for iterating over the rows.">children()</a>.</p> <p>You can use a const <a class="el" href="classGtk_1_1TreeModel.html#a297c9db68905e82fe7c3fac57f6c4de8">TreeModel::Row</a>& for any parameter that takes a const <a class="el" href="classGtk_1_1TreeModel.html#a754e74cd833ff30e729f9b8d7daf4d8c">TreeModel::iterator</a>&. </p> </div><hr/><h2>Member Function Documentation</h2> <a class="anchor" id="a334dc0b2d96c219e24de467d3fcbd091"></a><!-- doxytag: member="Gtk::TreeRow::children" ref="a334dc0b2d96c219e24de467d3fcbd091" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">const <a class="el" href="classGtk_1_1TreeNodeChildren.html">TreeNodeChildren</a>& Gtk::TreeRow::children </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </div> <div class="memdoc"> <p>This returns an STL-like container API, for iterating over the rows. </p> <p>See also <a class="el" href="classGtk_1_1TreeModel.html#a62142e8a5beffb04a2b643d7f62c890f" title="This returns an STL-like container API, for iterating over the rows.">Gtk::TreeModel::children()</a> for the top-level children. </p> </div> </div> <a class="anchor" id="a9b1db0af89cc50bb0b16a1daf8d5c5e1"></a><!-- doxytag: member="Gtk::TreeRow::get_value" ref="a9b1db0af89cc50bb0b16a1daf8d5c5e1" args="(int column, ColumnType &data) const " --> <div class="memitem"> <div class="memproto"> <div class="memtemplate"> template <class ColumnType > </div> <table class="memname"> <tr> <td class="memname">void Gtk::TreeRow::get_value </td> <td>(</td> <td class="paramtype">int </td> <td class="paramname"><em>column</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">ColumnType & </td> <td class="paramname"><em>data</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Use get_value(const TreeModelColumn<>& column) unless you do not know the column type at compile-time. </p> <p>If the <em>data</em> output argument is of an inappropriate C++ type then this might fail at runtime. </p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">column</td><td>The number of the column whose value you want to change. </td></tr> </table> </dd> </dl> <dl class="return"><dt><b>Returns:</b></dt><dd>data An output argument which will contain the value of this column of this row. </dd></dl> </div> </div> <a class="anchor" id="a193b7d490eed8f7e25aa70d73d746f6a"></a><!-- doxytag: member="Gtk::TreeRow::get_value" ref="a193b7d490eed8f7e25aa70d73d746f6a" args="(const TreeModelColumn< ColumnType > &column) const " --> <div class="memitem"> <div class="memproto"> <div class="memtemplate"> template <class ColumnType > </div> <table class="memname"> <tr> <td class="memname">ColumnType Gtk::TreeRow::get_value </td> <td>(</td> <td class="paramtype">const <a class="el" href="classGtk_1_1TreeModelColumn.html">TreeModelColumn</a>< ColumnType >& </td> <td class="paramname"><em>column</em></td><td>)</td> <td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Gets the value of this <em>column</em> of this row. </p> <p>This is a templated method, so the compiler will not allow you to provide an inappropriate type of data for the model column.</p> <p>See also operator[].</p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">column</td><td>The model column. </td></tr> </table> </dd> </dl> <dl class="return"><dt><b>Returns:</b></dt><dd>The new value to use for this column of this row. </dd></dl> </div> </div> <a class="anchor" id="a70f407de60552e0270ed73471ad07cd1"></a><!-- doxytag: member="Gtk::TreeRow::gobj" ref="a70f407de60552e0270ed73471ad07cd1" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">GtkTreeIter* Gtk::TreeRow::gobj </td> <td>(</td> <td class="paramname"></td><td>)</td> <td><code> [inline]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Provides access to the underlying C GObject. </p> <p>Reimplemented from <a class="el" href="classGtk_1_1TreeIterBase.html#a1479600863c422429b606e26885fc5ef">Gtk::TreeIterBase</a>.</p> </div> </div> <a class="anchor" id="aabd78b5aa80816c10b49d51f797ce7b7"></a><!-- doxytag: member="Gtk::TreeRow::gobj" ref="aabd78b5aa80816c10b49d51f797ce7b7" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">const GtkTreeIter* Gtk::TreeRow::gobj </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const<code> [inline]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Provides access to the underlying C GObject. </p> <p>Reimplemented from <a class="el" href="classGtk_1_1TreeIterBase.html#a0a9ac6f632e297568fa81c67966fb737">Gtk::TreeIterBase</a>.</p> </div> </div> <a class="anchor" id="a256d9c1def321f1968c2f01299781e14"></a><!-- doxytag: member="Gtk::TreeRow::operator bool" ref="a256d9c1def321f1968c2f01299781e14" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">Gtk::TreeRow::operator bool </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Discover whether this is a valid row. </p> <p>Reimplemented from <a class="el" href="classGtk_1_1TreeIter.html#a937201ba3ea794fc6442d5069967a214">Gtk::TreeIter</a>.</p> </div> </div> <a class="anchor" id="ad1880375e2c3b45a6ba69b225dd7f6a4"></a><!-- doxytag: member="Gtk::TreeRow::operator[]" ref="ad1880375e2c3b45a6ba69b225dd7f6a4" args="(const TreeModelColumn< ColumnType > &column) const " --> <div class="memitem"> <div class="memproto"> <div class="memtemplate"> template <class ColumnType > </div> <table class="memname"> <tr> <td class="memname"><a class="el" href="classGtk_1_1TreeValueProxy.html">TreeValueProxy</a><ColumnType> Gtk::TreeRow::operator[] </td> <td>(</td> <td class="paramtype">const <a class="el" href="classGtk_1_1TreeModelColumn.html">TreeModelColumn</a>< ColumnType >& </td> <td class="paramname"><em>column</em></td><td>)</td> <td> const<code> [inline]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Use this to set and get the value of this <em>column</em> of this row. </p> <p>This is a templated method, so the compiler will not allow you to provide an inappropriate type of data for the model column.</p> <p>This is just a more convient syntax that does the same thing as <a class="el" href="classGtk_1_1TreeRow.html#ae25785fc6de538f6dd632bb434a5f2ff" title="Sets the value of this column of this row.">set_value()</a> and <a class="el" href="classGtk_1_1TreeRow.html#a193b7d490eed8f7e25aa70d73d746f6a" title="Gets the value of this column of this row.">get_value()</a>.</p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">column</td><td>The model column.. </td></tr> </table> </dd> </dl> </div> </div> <a class="anchor" id="a9d55079617fc05a849af189b657e7679"></a><!-- doxytag: member="Gtk::TreeRow::parent" ref="a9d55079617fc05a849af189b657e7679" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="classGtk_1_1TreeIter.html">TreeIter</a> Gtk::TreeRow::parent </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Gets an iterator to the parent row of this row. </p> <dl class="return"><dt><b>Returns:</b></dt><dd>An iterator to the parent row. </dd></dl> </div> </div> <a class="anchor" id="ae25785fc6de538f6dd632bb434a5f2ff"></a><!-- doxytag: member="Gtk::TreeRow::set_value" ref="ae25785fc6de538f6dd632bb434a5f2ff" args="(const TreeModelColumn< ColumnType > &column, const ColumnType &data) const " --> <div class="memitem"> <div class="memproto"> <div class="memtemplate"> template <class ColumnType > </div> <table class="memname"> <tr> <td class="memname">void Gtk::TreeRow::set_value </td> <td>(</td> <td class="paramtype">const <a class="el" href="classGtk_1_1TreeModelColumn.html">TreeModelColumn</a>< ColumnType >& </td> <td class="paramname"><em>column</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const ColumnType & </td> <td class="paramname"><em>data</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Sets the value of this <em>column</em> of this row. </p> <p>This is a templated method, so the compiler will not allow you to provide an inappropriate type of <em>data</em> for the model column.</p> <p>See also operator[].</p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">column</td><td>The model column. </td></tr> <tr><td class="paramname">data</td><td>The new value to use for this column of this row. </td></tr> </table> </dd> </dl> </div> </div> <a class="anchor" id="abc6ffaec37d8bde03d94c39218390065"></a><!-- doxytag: member="Gtk::TreeRow::set_value" ref="abc6ffaec37d8bde03d94c39218390065" args="(int column, const ColumnType &data) const " --> <div class="memitem"> <div class="memproto"> <div class="memtemplate"> template <class ColumnType > </div> <table class="memname"> <tr> <td class="memname">void Gtk::TreeRow::set_value </td> <td>(</td> <td class="paramtype">int </td> <td class="paramname"><em>column</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const ColumnType & </td> <td class="paramname"><em>data</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Use set_value(const TreeModelColumn<>& column, const ColumnType& data) unless you do not know the column type at compile-time. </p> <p>If the <em>data</em> is of an inappropriate C++ type then this might fail at runtime. </p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">column</td><td>The number of the column whose value you want to change. </td></tr> <tr><td class="paramname">data</td><td>The new value to use for this column of this row. </td></tr> </table> </dd> </dl> </div> </div> <hr/>The documentation for this class was generated from the following file:<ul> <li>gtkmm/treeiter.h</li> </ul> </div> <hr class="footer"/><address class="footer"><small>Generated on Tue Jun 25 2013 for gtkmm by  <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.3 </small></address> </body> </html>