Sophie

Sophie

distrib > Fedora > 15 > x86_64 > by-pkgid > 0d2c760c00774fa1d350bb3c66520f68 > files > 396

GtkAda-doc-2.14.1-4.fc15.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><head>
 <title>GtkAda: Gtk.Tree_Selection</title>
 <link rel='stylesheet' href='gtkada_rm.css' type='text/css'>
 <script src='gtkada_rm.js' type='text/javascript'></script>
</head><body>
<div id='objectName'>
 <span><a href='index.html'><img src='home.png' alt='Toc' title='Table of Contents'/></a> <a href='gallery.html'><img src='gallery.png' alt='Gallery' title='Widgets gallery'/></a>
 <a href='entities.html'><img src='entities.png' alt='Index' title='Global Index'/></a>
 <a href='tree.html'><img src='tree.png' alt='Tree' title='Widgets Inheritance Tree'/></a>
  </span>
Gtk.Tree_Selection
</div> <!--  objectName -->

<div id='leftSide'>
  <div id='classHierarchy'>
   <h2>Hierarchy</h2>
<ul class='top'>
  <li><img src='childtree.png' alt='_' /><a class='tree' onclick='treetoggle(this)'><img src='treeopen.png' alt='[-]' /></a><a href='glib-object.html'>GObject_Record</a></li><ul>
  <li><img src='childtree2.png' alt='  '/><img src='childtree.png' alt='_' />Gtk_Tree_Selection_Record</li></ul>
</ul>
  </div> <!--  classHierarchy -->

  <div id='navigation'>
   <h2>Navigation</h2>
   <ul>
     <li><a href='#Description' onclick='return switchPage("page1")'>Description</a></li>
     <li><a href='#Types' onclick='return switchPage("page1")'>Types</a></li>
     <li><a href='#Subprograms' onclick='return switchPage("page1")'>Subprograms</a>
       <ul>
        <li><a href='#Subprograms__General' onclick='return switchPage("page1")'>General</a></li>
       </ul>
   </li>
     <li><a href='#Signals' onclick='return switchPage("page2")'>Signals</a></li>
   </ul>
  </div> <!--  navigation -->

</div>  <!--  leftSide -->

<div id='documentation'>
  <ul id='notebook'>
   <li id='tab_page1' class='current'><a href='' onclick='return !switchPage("page1")'>Entities</a></li>
   <li id='tab_page2'><a href='#Signals' onclick='return !switchPage("page2")'>Signals</a></li>
  </ul>  <!-- notebook --> 

  <div id='notebook_page1' class='notebookPage'>
  <a name='Description'></a>
  <div class='description'>
   <h2>Description</h2>
The <a href='gtk-tree_selection.html'>Gtk_Tree_Selection</a> object is a helper object to manage the selection
for a Gtk_Tree_View widget. The <a href='gtk-tree_selection.html'>Gtk_Tree_Selection</a> object is automatically
created when a new Gtk_Tree_View widget is created, and cannot exist
independentally of this widget. The primary reason the <a href='gtk-tree_selection.html'>Gtk_Tree_Selection</a>
objects exists is for cleanliness of code and API. That is, there is no
conceptual reason all these functions could not be methods on the
Gtk_Tree_View widget instead of separate function.
<p>
The <a href='gtk-tree_selection.html'>Gtk_Tree_Selection</a> object is gotten from a Gtk_Tree_View by calling
<a href='gtk-tree_view.html#Get_Selection_8_'>Gtk.Tree_View.Get_Selection</a>. It can be manipulated to check the selection
status of the tree, as well as select and deselect individual rows.
Selection is done completely view side. As a result, multiple views of the
same model can have completely different selections. Additionally, you
cannot change the selection of a row on the model that is not currently
displayed by the view without expanding its parents first.
<p>
One of the important things to remember when monitoring the selection of a
view is that the "changed" signal is mostly a hint. That is, it may only
emit one signal when a range of rows is selected. Additionally, it may on
occasion emit a "changed" signal when nothing has happened (mostly as a
result of programmers calling select_row on an already selected row).
  </div> <!-- description -->

  <a name='Types'></a>
  <div id='types'>
   <h2>Types</h2>
   <ul>
     <li><a name='Data_Type_'></a>
         <div class='profile'><b>type</b> Data_Type <b>is</b> <b>private</b>;</div>
         <div class='comment'></div></li>
     <li><a name='Data_Type_Access_'></a>
         <div class='profile'><b>type</b> Data_Type_Access <b>is</b> <b>access</b> <b>all</b> Data_Type;</div>
         <div class='comment'></div></li>
     <li><a name='Foreach_Func_'></a>
         <div class='profile'><b>type</b> Foreach_Func <b>is</b> <b>access</b> <b>procedure</b>
        (Model : <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Model</a>;
         Path  : <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Path</a>;
         Iter  : <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Iter</a>;
         Data  : Data_Type_Access);</div>
         <div class='comment'></div></li>
     <li><a name='Gtk_Tree_Selection_'></a>
         <div class='profile'><b>type</b> Gtk_Tree_Selection <b>is</b> <b>access</b> <b>all</b> Gtk_Tree_Selection_Record'Class;</div>
         <div class='comment'></div></li>
     <li><a name='Gtk_Tree_Selection_Record_'></a>
         <div class='profile'><b>type</b> Gtk_Tree_Selection_Record <b>is</b>
     <b>new</b> <a href='glib-object.html'>Glib.Object.GObject_Record</a> <b>with</b> <b>private</b>;</div>
         <div class='comment'></div></li>
   </ul>
  </div> <!-- types -->

  <a name='Subprograms'> </a>
  <a name='Subprograms__General'> </a>
  <div id='subprograms'>
   <h2>Subprograms</h2>
   <ul>
     <li><a name='Get_Type_1_'></a>
<div class='profile'><b>function</b> <span class='name'>Get_Type</span> <b>return</b> <a href='glib.html'>Glib.GType</a>;</div>
<div class='comment'>Return the internal type associated with <a href='gtk-tree_selection.html'>Gtk_Tree_Selection</a>.
</div></li>
     <li><a name='Set_Mode_2_'></a>
<div class='profile'><b>procedure</b> <span class='name'>Set_Mode</span>
  (Selection : <b>access</b> Gtk_Tree_Selection_Record'Class;
   The_Type  : Gtk_Selection_Mode);</div>
<a name='Get_Mode_3_'></a>
<div class='profile'><b>function</b> <span class='name'>Get_Mode</span>
  (Selection : <b>access</b> Gtk_Tree_Selection_Record'Class)
   <b>return</b> Gtk_Selection_Mode;</div>
<div class='comment'>Set the selection mode of the <tt>Selection</tt>.
If the previous type was Gtk_Selection_Multiple,
then the anchor is kept selected, if it was  previously selected.
</div></li>
     <li><a name='Get_Tree_View_4_'></a>
<div class='profile'><b>function</b> <span class='name'>Get_Tree_View</span>
  (Selection : <b>access</b> Gtk_Tree_Selection_Record'Class)
   <b>return</b> <a href='gtk-widget.html'>Gtk.Widget.Gtk_Widget</a>;</div>
<div class='comment'>Return the tree view associated with <tt>Selection</tt>.
</div></li>
     <li><a name='Count_Selected_Rows_5_'></a>
<div class='profile'><b>function</b> <span class='name'>Count_Selected_Rows</span>
  (Selection : <b>access</b> Gtk_Tree_Selection_Record) <b>return</b> Gint;</div>
<div class='comment'>Returns the number of rows that have been selected.
</div></li>
     <li><a name='Get_Selected_6_'></a>
<div class='profile'><b>procedure</b> <span class='name'>Get_Selected</span>
  (Selection : <b>access</b> Gtk_Tree_Selection_Record'Class;
   Model     : <b>out</b> <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Model</a>;
   Iter      : <b>out</b> <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Iter</a>);</div>
<div class='comment'>Set <tt>Iter</tt> to the currently selected node if <tt>Selection</tt>
is set to Gtk_Selection_Single or Gtk_Selection_Browse.
<tt>Iter</tt> is set to Null_Iter if no node is currently selected.
<tt>Model</tt> is filled with the current model as a convenience. This function
will not work if <tt>Selection</tt> is set to Gtk_Selection_Multiple.
</div></li>
     <li><a name='Get_Selected_Rows_7_'></a>
<div class='profile'><b>procedure</b> <span class='name'>Get_Selected_Rows</span>
  (Selection : <b>access</b> Gtk_Tree_Selection_Record;
   Model     : <b>out</b> <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Model</a>;
   Path_List : <b>out</b> Gtk.Tree_Model.Gtk_Tree_Path_List.Glist);</div>
<div class='comment'>Creates a list of path of all selected rows. Additionally, if you are
planning on modifying the model after calling this function, you may
want to convert the returned list into a list of Gtk_Tree_Row_Reference.
<p>
You must free the resulting list by calling Path_Free on each item, and
then freeing the list itself.
</div></li>
     <li><a name='Selected_Foreach_8_'></a>
<div class='profile'><b>procedure</b> <span class='name'>Selected_Foreach</span>
  (Selection : <b>access</b> Gtk_Tree_Selection_Record'Class;
   Func      : Foreach_Func;
   Data      : Data_Type_Access);</div>
<div class='comment'>Call <tt>Func</tt> for each selected node.
</div></li>
     <li><a name='Select_Path_9_'></a>
<div class='profile'><b>procedure</b> <span class='name'>Select_Path</span>
  (Selection : <b>access</b> Gtk_Tree_Selection_Record'Class;
   Path      : <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Path</a>);</div>
<a name='Unselect_Path_10_'></a>
<div class='profile'><b>procedure</b> <span class='name'>Unselect_Path</span>
  (Selection : <b>access</b> Gtk_Tree_Selection_Record'Class;
   Path      : <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Path</a>);</div>
<div class='comment'>Selects or unselects the row at path.
</div></li>
     <li><a name='Path_Is_Selected_11_'></a>
<div class='profile'><b>function</b> <span class='name'>Path_Is_Selected</span>
  (Selection : <b>access</b> Gtk_Tree_Selection_Record'Class;
   Path      : <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Path</a>)
   <b>return</b> Boolean;</div>
<div class='comment'>Return True if the row pointed to by path is currently selected.
If path does not point to a valid location, False is returned
</div></li>
     <li><a name='Select_Iter_12_'></a>
<div class='profile'><b>procedure</b> <span class='name'>Select_Iter</span>
  (Selection : <b>access</b> Gtk_Tree_Selection_Record'Class;
   Iter      : <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Iter</a>);</div>
<a name='Unselect_Iter_13_'></a>
<div class='profile'><b>procedure</b> <span class='name'>Unselect_Iter</span>
  (Selection : <b>access</b> Gtk_Tree_Selection_Record'Class;
   Iter      : <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Iter</a>);</div>
<div class='comment'>Selects or unselects the row pointed to by the specified iterator.
</div></li>
     <li><a name='Iter_Is_Selected_14_'></a>
<div class='profile'><b>function</b> <span class='name'>Iter_Is_Selected</span>
  (Selection : <b>access</b> Gtk_Tree_Selection_Record'Class;
   Iter      : <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Iter</a>)
   <b>return</b> Boolean;</div>
<div class='comment'>Return True if the row pointed to by path is currently selected.
</div></li>
     <li><a name='Select_All_15_'></a>
<div class='profile'><b>procedure</b> <span class='name'>Select_All</span> (Selection : <b>access</b> Gtk_Tree_Selection_Record'Class);</div>
<a name='Unselect_All_16_'></a>
<div class='profile'><b>procedure</b> <span class='name'>Unselect_All</span> (Selection : <b>access</b> Gtk_Tree_Selection_Record'Class);</div>
<div class='comment'>Selects or unselects all the nodes.
<tt>Selection</tt> must be set to Gtk_Selection_Multiple mode.
</div></li>
     <li><a name='Select_Range_17_'></a>
<div class='profile'><b>procedure</b> <span class='name'>Select_Range</span>
  (Selection  : <b>access</b> Gtk_Tree_Selection_Record'Class;
   Start_Path : <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Path</a>;
   End_Path   : <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Path</a>);</div>
<a name='Unselect_Range_18_'></a>
<div class='profile'><b>procedure</b> <span class='name'>Unselect_Range</span>
  (Selection  : <b>access</b> Gtk_Tree_Selection_Record;
   Start_Path : <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Path</a>;
   End_Path   : <a href='gtk-tree_model.html'>Gtk.Tree_Model.Gtk_Tree_Path</a>);</div>
<div class='comment'>Selects or unselects a range of nodes, determined by <tt>Start_Path</tt> and
<tt>End_Path</tt> inclusive
</div></li>
    </ul>
   </div> <!--  subprograms -->

  </div> <!--  notebook_page1 --> 
  <div id='notebook_page2' class='notebookPage'>
    <a name='Signals'></a>
    <div id='signals'>
      <h2>Signals</h2>
   <ul>
    <li><div class='name'>changed</div>
        <div class='profile'><b>procedure</b> <span class='name'>Handler</span>
      (Widget : <b>access</b> Gtk_Tree_Selection_Record'Class'Class);</div>
        <div class='comment'>  Emitted whenever the selection has (possibly) changed. Please note
  that this signal is mostly a hint. It may only be emitted once when a
  range of rows are selected, and it may occasionally be emitted when
  nothing has happened.
<div></li>
   </ul>
    </div> <!-- signals -->
  </div> <!--  notebook_page2 -->

  <div id='notebook_page3' class='notebookPage'>
  </div> <!-- notebook_page3 -->

</div> <!-- documentation -->

<div id='rightSide'>
 <div id='Index'>
  <h2>Alphabetical Index</h2>
  <ul>
   <li><a href='#Count_Selected_Rows_5_' onclick='return switchPage("page1")'>Count_Selected_Rows</a></li>
   <li><a href='#Get_Mode_3_' onclick='return switchPage("page1")'>Get_Mode</a></li>
   <li><a href='#Get_Selected_6_' onclick='return switchPage("page1")'>Get_Selected</a></li>
   <li><a href='#Get_Selected_Rows_7_' onclick='return switchPage("page1")'>Get_Selected_Rows</a></li>
   <li><a href='#Get_Tree_View_4_' onclick='return switchPage("page1")'>Get_Tree_View</a></li>
   <li><a href='#Get_Type_1_' onclick='return switchPage("page1")'>Get_Type</a></li>
   <li><a href='#Iter_Is_Selected_14_' onclick='return switchPage("page1")'>Iter_Is_Selected</a></li>
   <li><a href='#Path_Is_Selected_11_' onclick='return switchPage("page1")'>Path_Is_Selected</a></li>
   <li><a href='#Select_All_15_' onclick='return switchPage("page1")'>Select_All</a></li>
   <li><a href='#Select_Iter_12_' onclick='return switchPage("page1")'>Select_Iter</a></li>
   <li><a href='#Select_Path_9_' onclick='return switchPage("page1")'>Select_Path</a></li>
   <li><a href='#Select_Range_17_' onclick='return switchPage("page1")'>Select_Range</a></li>
   <li><a href='#Selected_Foreach_8_' onclick='return switchPage("page1")'>Selected_Foreach</a></li>
   <li><a href='#Set_Mode_2_' onclick='return switchPage("page1")'>Set_Mode</a></li>
   <li><a href='#Unselect_All_16_' onclick='return switchPage("page1")'>Unselect_All</a></li>
   <li><a href='#Unselect_Iter_13_' onclick='return switchPage("page1")'>Unselect_Iter</a></li>
   <li><a href='#Unselect_Path_10_' onclick='return switchPage("page1")'>Unselect_Path</a></li>
   <li><a href='#Unselect_Range_18_' onclick='return switchPage("page1")'>Unselect_Range</a></li>
  </ul>
 </div> <!-- Index -->
</div> <!-- rightSide -->

   <script language='javascript'>switchPage('page1');
adjust_height()</script>
 </body>
</html>