2003-02-12 02:00:12 +00:00
<Type Name= "TreeSelection" FullName= "Gtk.TreeSelection" >
2005-05-23 20:41:51 +00:00
<TypeSignature Language= "C#" Maintainer= "Lee Mallabone" Value= "public class TreeSelection : GLib.Object" />
2011-11-09 16:01:51 +00:00
<TypeSignature Language= "ILAsm" Value= ".class public auto ansi beforefieldinit TreeSelection extends GLib.Object" />
2003-02-12 02:00:12 +00:00
<AssemblyInfo >
<AssemblyName > gtk-sharp</AssemblyName>
2003-12-24 01:35:30 +00:00
<AssemblyPublicKey >
</AssemblyPublicKey>
2003-02-12 02:00:12 +00:00
</AssemblyInfo>
2003-02-23 07:26:30 +00:00
<ThreadSafetyStatement > Gtk# is thread aware, but not thread safe; See the <link location= "node:gtk-sharp/programming/threads" > Gtk# Thread Programming</link> for details.</ThreadSafetyStatement>
2011-11-09 16:01:51 +00:00
<Base >
<BaseTypeName > GLib.Object</BaseTypeName>
</Base>
<Interfaces >
</Interfaces>
2003-02-12 02:00:12 +00:00
<Docs >
2003-05-08 20:26:02 +00:00
<summary > The selection object for <see cref= "T:Gtk.TreeView" /> .</summary>
<remarks >
<para > TreeSelection provides a single class for managing selection information on the List/Tree widget.</para>
<para > A TreeSelection object is automatically created when a new <see cref= "T:Gtk.TreeView" /> widget is created and is inherently tied to it. A TreeSelection cannot exist independently of a <see cref= "T:Gtk.TreeView" /> . Selection information is retrieved from the <see cref= "T:Gtk.TreeView" /> with the <see cref= "P:Gtk.TreeView.Selection" /> property.</para>
<para > TreeSelection can check the selection status of the tree, as well as select and deselect individual rows. Selection is done completely on the view. As a result, multiple views of the same model can have completely different selections. Additionally, you cannot change the selection of a row that is not currently displayed by the view without expanding its parents first.</para>
2003-07-03 01:25:09 +00:00
<para > One of the important things to remember when monitoring the selection of a view is that the <see cref= "E:Gtk.TreeSelection.Changed" /> event is mostly a hint. For example, it may only fire once when a range of rows is selected. It may also fire when nothing has happened, such as when <see cref= "M:Gtk.TreeSelection.SelectPath(Gtk.TreePath)" /> is called on a row that is already selected.</para>
2003-05-08 20:26:02 +00:00
</remarks>
2004-05-27 19:02:19 +00:00
<example >
<code lang= "C#" >
2004-04-28 01:25:29 +00:00
using System;
using Gtk;
class Selection
{
static void Main ()
{
Application.Init ();
Window win = new Window ("TreeSelection sample");
win.DeleteEvent += OnWinDelete;
TreeView tv = new TreeView ();
tv.AppendColumn ("Items", new CellRendererText (), "text", 0);
ListStore store = new ListStore (typeof (string));
store.AppendValues ("item 1");
store.AppendValues ("item 2");
tv.Model = store;
tv.Selection.Changed += OnSelectionChanged;
win.Add (tv);
win.ShowAll ();
Application.Run ();
}
static void OnSelectionChanged (object o, EventArgs args)
{
TreeIter iter;
TreeModel model;
if (((TreeSelection)o).GetSelected (out model, out iter))
{
string val = (string) model.GetValue (iter, 0);
Console.WriteLine ("{0} was selected", val);
}
}
static void OnWinDelete (object o, DeleteEventArgs args)
{
Application.Quit ();
}
}
</code>
2004-05-27 19:02:19 +00:00
</example>
2003-02-12 02:00:12 +00:00
</Docs>
<Members >
2011-11-09 16:01:51 +00:00
<Member MemberName= ".ctor" >
<MemberSignature Language= "C#" Value= "protected TreeSelection ();" />
<MemberSignature Language= "ILAsm" Value= ".method familyhidebysig specialname rtspecialname instance void .ctor() cil managed" />
<MemberType > Constructor</MemberType>
<ReturnValue />
<Parameters />
2003-02-12 02:00:12 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<summary > Protected constructor.</summary>
2003-04-13 12:55:01 +00:00
<remarks />
2003-02-12 02:00:12 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= ".ctor" >
<MemberSignature Language= "C#" Value= "public TreeSelection (IntPtr raw);" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig specialname rtspecialname instance void .ctor(native int raw) cil managed" />
<MemberType > Constructor</MemberType>
<ReturnValue />
2003-02-12 02:00:12 +00:00
<Parameters >
2011-11-09 16:01:51 +00:00
<Parameter Name= "raw" Type= "System.IntPtr" />
2003-07-31 21:44:39 +00:00
</Parameters>
2003-02-12 02:00:12 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<param name= "raw" > Pointer to the C object.</param>
<summary > Internal constructor</summary>
<remarks >
<para > This is an internal constructor, and should not be used by user code.</para>
</remarks>
2003-02-12 02:00:12 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "Changed" >
<MemberSignature Language= "C#" Value= "public event EventHandler Changed;" />
<MemberSignature Language= "ILAsm" Value= ".event class System.EventHandler Changed" />
<MemberType > Event</MemberType>
<Attributes >
<Attribute >
<AttributeName > GLib.Signal("changed")</AttributeName>
</Attribute>
</Attributes>
2003-02-12 02:00:12 +00:00
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > System.EventHandler</ReturnType>
2003-02-12 02:00:12 +00:00
</ReturnValue>
2011-11-09 16:01:51 +00:00
<Parameters />
2003-02-12 02:00:12 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<summary > Raised when the selection (may have) changed.</summary>
2003-05-08 20:26:02 +00:00
<remarks >
2011-11-09 16:01:51 +00:00
<para > This event is mostly a hint. It may only be raised once when a range of rows are selected, and it may occasionally be raised when nothing has happened.</para>
2003-05-08 20:26:02 +00:00
</remarks>
2003-02-12 02:00:12 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "CountSelectedRows" >
<MemberSignature Language= "C#" Value= "public int CountSelectedRows ();" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance int32 CountSelectedRows() cil managed" />
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > System.Int32</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
<summary > Get the number of selected rows.</summary>
<returns > The number of selected rows</returns>
<remarks />
</Docs>
</Member>
<Member MemberName= "GetSelected" >
<MemberSignature Language= "C#" Value= "public bool GetSelected (out Gtk.TreeIter iter);" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance bool GetSelected(valuetype Gtk.TreeIter iter) cil managed" />
2003-02-12 02:00:12 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > System.Boolean</ReturnType>
</ReturnValue>
<Parameters >
2011-11-09 16:01:51 +00:00
<Parameter Name= "iter" Type= "Gtk.TreeIter&" RefType= "out" />
2003-07-31 21:44:39 +00:00
</Parameters>
2003-02-12 02:00:12 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<param name= "iter" > The position that was selected.</param>
<summary > Gets information about the currently selected node.</summary>
2003-05-08 20:26:02 +00:00
<returns >
2011-11-09 16:01:51 +00:00
<see langword= "true" /> if a row is selected.</returns>
<remarks > This convenience method doesnt require an out <see cref= "Gtk.TreeModel" /> . It is useful in the case that you already have a copy of the TreeModel.</remarks>
2003-02-12 02:00:12 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "GetSelected" >
2013-11-30 15:01:53 +00:00
<MemberSignature Language= "C#" Value= "public bool GetSelected (out Gtk.ITreeModel model, out Gtk.TreeIter iter);" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance bool GetSelected(class Gtk.ITreeModel model, valuetype Gtk.TreeIter iter) cil managed" />
2003-02-12 02:00:12 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > System.Boolean</ReturnType>
2003-02-12 02:00:12 +00:00
</ReturnValue>
2011-11-09 16:01:51 +00:00
<Parameters >
2013-11-30 15:01:53 +00:00
<Parameter Name= "model" Type= "Gtk.ITreeModel&" RefType= "out" />
2011-11-09 16:01:51 +00:00
<Parameter Name= "iter" Type= "Gtk.TreeIter&" RefType= "out" />
</Parameters>
2003-02-12 02:00:12 +00:00
<Docs >
2013-11-30 15:01:53 +00:00
<param name= "model" > To be added.</param>
<param name= "iter" > To be added.</param>
<summary > To be added.</summary>
<returns > To be added.</returns>
<remarks > To be added.</remarks>
<since version= "Gtk# 3.0" />
2003-02-12 02:00:12 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "GetSelectedRows" >
<MemberSignature Language= "C#" Value= "public Gtk.TreePath[] GetSelectedRows ();" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance class Gtk.TreePath[] GetSelectedRows() cil managed" />
2003-02-12 02:00:12 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > Gtk.TreePath[]</ReturnType>
2003-02-12 02:00:12 +00:00
</ReturnValue>
2011-11-09 16:01:51 +00:00
<Parameters />
2003-02-12 02:00:12 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<summary > Returns an array of <see cref= "T:Gtk.TreePath" /> s representing the selected rows.</summary>
<returns > Selected rows in an array of <see cref= "T:Gtk.TreePath" /> s</returns>
<remarks />
<since version= "Gtk# 2.4" />
2003-02-12 02:00:12 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "GetSelectedRows" >
2013-11-30 15:01:53 +00:00
<MemberSignature Language= "C#" Value= "public Gtk.TreePath[] GetSelectedRows (out Gtk.ITreeModel model);" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance class Gtk.TreePath[] GetSelectedRows(class Gtk.ITreeModel model) cil managed" />
2003-02-12 02:00:12 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > Gtk.TreePath[]</ReturnType>
2003-02-12 02:00:12 +00:00
</ReturnValue>
<Parameters >
2013-11-30 15:01:53 +00:00
<Parameter Name= "model" Type= "Gtk.ITreeModel&" RefType= "out" />
2003-07-31 21:44:39 +00:00
</Parameters>
2003-02-12 02:00:12 +00:00
<Docs >
2013-11-30 15:01:53 +00:00
<param name= "model" > To be added.</param>
<summary > To be added.</summary>
<returns > To be added.</returns>
<remarks > To be added.</remarks>
<since version= "Gtk# 3.0" />
2003-02-12 02:00:12 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "GType" >
<MemberSignature Language= "C#" Value= "public static GLib.GType GType { get; }" />
<MemberSignature Language= "ILAsm" Value= ".property valuetype GLib.GType GType" />
<MemberType > Property</MemberType>
2003-02-12 02:00:12 +00:00
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > GLib.GType</ReturnType>
2003-02-12 02:00:12 +00:00
</ReturnValue>
<Parameters />
<Docs >
2011-11-09 16:01:51 +00:00
<summary > GType Property.</summary>
<value > a <see cref= "T:GLib.GType" /> </value>
<remarks > Returns the native <see cref= "T:GLib.GType" /> value for <see cref= "T:Gtk.TreeSelection" /> .</remarks>
2003-02-12 02:00:12 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "IterIsSelected" >
<MemberSignature Language= "C#" Value= "public bool IterIsSelected (Gtk.TreeIter iter);" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance bool IterIsSelected(valuetype Gtk.TreeIter iter) cil managed" />
2003-02-12 02:00:12 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > System.Boolean</ReturnType>
2003-02-12 02:00:12 +00:00
</ReturnValue>
<Parameters >
2011-11-09 16:01:51 +00:00
<Parameter Name= "iter" Type= "Gtk.TreeIter" />
2003-07-31 21:44:39 +00:00
</Parameters>
2003-02-12 02:00:12 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<param name= "iter" > The tree location to check</param>
<summary > Determine if the iter is selected.</summary>
<returns >
<see langword= "true" /> if the tree node specified by <paramref name= "iter" /> is selected, <see langword= "false" /> otherwise.</returns>
2003-05-08 20:26:02 +00:00
<remarks >
2011-11-09 16:01:51 +00:00
<para > See also <see cref= "M:Gtk.TreeSelection.PathIsSelected(Gtk.TreePath)" /> .</para>
2003-05-08 20:26:02 +00:00
</remarks>
2003-02-12 02:00:12 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "Mode" >
<MemberSignature Language= "C#" Value= "public Gtk.SelectionMode Mode { get; set; }" />
<MemberSignature Language= "ILAsm" Value= ".property instance valuetype Gtk.SelectionMode Mode" />
<MemberType > Property</MemberType>
2003-02-12 02:00:12 +00:00
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > Gtk.SelectionMode</ReturnType>
2003-02-12 02:00:12 +00:00
</ReturnValue>
<Parameters >
2003-07-31 21:44:39 +00:00
</Parameters>
2003-02-12 02:00:12 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<summary > Manages the way rows can be selected.</summary>
<value > The current mode dictating selection behaviour.</value>
<remarks >
<para > Rows may be deselected by changing this property. For example, if <see cref= "P:Gtk.SelectionMode.Multiple" /> rows are selected and the mode is changed to <see cref= "P:Gtk.SelectionMode.Single" /> or <see cref= "P:Gtk.SelectionMode.Browse" /> .</para>
</remarks>
2005-05-04 11:47:25 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "OnChanged" >
<MemberSignature Language= "C#" Value= "protected virtual void OnChanged ();" />
<MemberSignature Language= "ILAsm" Value= ".method familyhidebysig newslot virtual instance void OnChanged() cil managed" />
<MemberType > Method</MemberType>
<Attributes >
<Attribute >
<AttributeName > GLib.DefaultSignalHandler(ConnectionMethod="OverrideChanged", Type=typeof(Gtk.TreeSelection))</AttributeName>
</Attribute>
</Attributes>
<ReturnValue >
<ReturnType > System.Void</ReturnType>
2005-05-04 11:47:25 +00:00
</ReturnValue>
2011-11-09 16:01:51 +00:00
<Parameters />
2005-05-04 11:47:25 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<summary > Default handler for the <see cref= "M:Gtk.TreeSelection.Changed" /> event.</summary>
<remarks > Override this method in a subclass to provide a default handler for the <see cref= "M:Gtk.TreeSelection.Changed" /> event.</remarks>
2003-02-12 02:00:12 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "PathIsSelected" >
<MemberSignature Language= "C#" Value= "public bool PathIsSelected (Gtk.TreePath path);" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance bool PathIsSelected(class Gtk.TreePath path) cil managed" />
2003-02-12 02:00:12 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > System.Boolean</ReturnType>
2003-02-12 02:00:12 +00:00
</ReturnValue>
<Parameters >
2011-11-09 16:01:51 +00:00
<Parameter Name= "path" Type= "Gtk.TreePath" />
2003-07-31 21:44:39 +00:00
</Parameters>
2003-02-12 02:00:12 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<param name= "path" > The path to a node whose selected status should be checked.</param>
<summary > Determines whether a <see cref= "T:Gtk.TreePath" /> has been selected in this <see cref= "T:TreeView" /> .</summary>
<returns >
<see langword= "true" /> if <paramref name= "path" /> is selected, <see langword= "false" /> otherwise.</returns>
<remarks />
2003-02-12 02:00:12 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "SelectAll" >
<MemberSignature Language= "C#" Value= "public void SelectAll ();" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance void SelectAll() cil managed" />
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > System.Void</ReturnType>
</ReturnValue>
<Parameters />
2003-02-12 02:00:12 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<summary > Selects every node in this <see cref= "T:Gtk.TreeView" /> .</summary>
2003-02-23 07:26:30 +00:00
<remarks >
2011-11-09 16:01:51 +00:00
<para > The <see cref= "P:Gtk.TreeSelection.Mode" /> must be set to <see cref= "P:Gtk.SelectionMode.Multiple" /> for this method to work.</para>
2003-02-23 07:26:30 +00:00
</remarks>
2003-02-12 02:00:12 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "SelectedForeach" >
<MemberSignature Language= "C#" Value= "public void SelectedForeach (Gtk.TreeSelectionForeachFunc func);" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance void SelectedForeach(class Gtk.TreeSelectionForeachFunc func) cil managed" />
<MemberType > Method</MemberType>
2003-02-12 02:00:12 +00:00
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > System.Void</ReturnType>
2003-02-12 02:00:12 +00:00
</ReturnValue>
2003-12-24 01:35:30 +00:00
<Parameters >
2011-11-09 16:01:51 +00:00
<Parameter Name= "func" Type= "Gtk.TreeSelectionForeachFunc" />
2003-12-24 01:35:30 +00:00
</Parameters>
2003-02-12 02:00:12 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<param name= "func" > The delegate that should be called for each selected row.</param>
<summary > Invokes the delegate passed in by <paramref name= "func" /> for each selected row in the <see cref= "T:Gtk.TreeView" /> .</summary>
2003-05-08 20:26:02 +00:00
<remarks >
2011-11-09 16:01:51 +00:00
<para > This method is useful when the <see cref= "P:Gtk.TreeSelection.Mode" /> of this TreeSelection is set to <see cref= "P:Gtk.Selection.Multiple" /> . It is currently the only way to access selection information for multiple rows. See the class overview for an example on how to effectively use this method for selection tracking.</para>
2003-05-08 20:26:02 +00:00
</remarks>
2003-02-12 02:00:12 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "SelectFunction" >
<MemberSignature Language= "C#" Value= "public Gtk.TreeSelectionFunc SelectFunction { get; set; }" />
<MemberSignature Language= "ILAsm" Value= ".property instance class Gtk.TreeSelectionFunc SelectFunction" />
2003-02-12 02:00:12 +00:00
<MemberType > Property</MemberType>
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > Gtk.TreeSelectionFunc</ReturnType>
2003-02-12 02:00:12 +00:00
</ReturnValue>
<Docs >
2011-11-09 16:01:51 +00:00
<summary > A hook into selection and unselection</summary>
<value > a <see cref= "T:Gtk.TreeSelectionFunc" /> </value>
2003-05-08 20:26:02 +00:00
<remarks >
2011-11-09 16:01:51 +00:00
<para > If set, <paramref name= "func" /> is called before any node is selected or unselected, giving some control over which nodes are selected. The select function should return <see langword= "true" /> if the state of the node may be toggled, and <see langword= "false" /> if the state of the node should be left unchanged.</para>
2003-05-08 20:26:02 +00:00
</remarks>
2011-11-09 16:01:51 +00:00
<since version= "Gtk# 2.4" />
2003-02-12 02:00:12 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "SelectIter" >
<MemberSignature Language= "C#" Value= "public void SelectIter (Gtk.TreeIter iter);" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance void SelectIter(valuetype Gtk.TreeIter iter) cil managed" />
<MemberType > Method</MemberType>
2003-07-31 21:44:39 +00:00
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > System.Void</ReturnType>
2003-07-31 21:44:39 +00:00
</ReturnValue>
2011-11-09 16:01:51 +00:00
<Parameters >
<Parameter Name= "iter" Type= "Gtk.TreeIter" />
</Parameters>
2003-02-12 02:00:12 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<param name= "iter" > Indicates which row to select.</param>
<summary > Selects the specified <see cref= "T:Gtk.TreeIter" /> .</summary>
2003-05-08 20:26:02 +00:00
<remarks >
2011-11-09 16:01:51 +00:00
<para > See also <see cref= "M:Gtk.TreeSelection.SelectAll()" /> and <see cref= "M:Gtk.TreeSelection.SelectPath(Gtk.TreePath)" /> .</para>
2003-05-08 20:26:02 +00:00
</remarks>
2003-02-12 02:00:12 +00:00
</Docs>
2005-06-16 18:56:42 +00:00
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "SelectPath" >
<MemberSignature Language= "C#" Value= "public void SelectPath (Gtk.TreePath path);" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance void SelectPath(class Gtk.TreePath path) cil managed" />
2003-07-17 06:38:40 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > System.Void</ReturnType>
</ReturnValue>
<Parameters >
2011-11-09 16:01:51 +00:00
<Parameter Name= "path" Type= "Gtk.TreePath" />
2003-07-31 21:44:39 +00:00
</Parameters>
2003-07-17 06:38:40 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<param name= "path" > A row to be selected.</param>
<summary > Selects the specified row that <paramref name= "path" /> represents.</summary>
2004-08-04 17:10:22 +00:00
<remarks />
2003-07-17 06:38:40 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "SelectRange" >
<MemberSignature Language= "C#" Value= "public void SelectRange (Gtk.TreePath start_path, Gtk.TreePath end_path);" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance void SelectRange(class Gtk.TreePath start_path, class Gtk.TreePath end_path) cil managed" />
2003-07-17 06:38:40 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > System.Void</ReturnType>
2003-07-17 06:38:40 +00:00
</ReturnValue>
2011-11-09 16:01:51 +00:00
<Parameters >
<Parameter Name= "start_path" Type= "Gtk.TreePath" />
<Parameter Name= "end_path" Type= "Gtk.TreePath" />
</Parameters>
2003-07-17 06:38:40 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<param name= "start_path" > The first node to select on the tree.</param>
<param name= "end_path" > The last node to select on the tree.</param>
<summary > Selects all the nodes that appear between <paramref name= "start_path" /> and <paramref name= "end_path" /> .</summary>
2004-08-04 17:10:22 +00:00
<remarks />
2003-07-17 06:38:40 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "TreeView" >
<MemberSignature Language= "C#" Value= "public Gtk.TreeView TreeView { get; }" />
<MemberSignature Language= "ILAsm" Value= ".property instance class Gtk.TreeView TreeView" />
<MemberType > Property</MemberType>
2003-10-28 00:48:23 +00:00
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > Gtk.TreeView</ReturnType>
2003-10-28 00:48:23 +00:00
</ReturnValue>
<Docs >
2011-11-09 16:01:51 +00:00
<summary > Get the <see cref= "T:Gtk.TreeView" /> that this <see cref= "T:Gtk.TreeSelection" /> is associated with.</summary>
<value > The <see cref= "T:Gtk.TreeView" /> that this <see cref= "T:Gtk.TreeSelection" /> is tied to.</value>
2003-10-28 00:48:23 +00:00
<remarks >
2011-11-09 16:01:51 +00:00
<para > A <see cref= "T:Gtk.TreeSelection" /> object can only be retrieved from a <see cref= "T:Gtk.TreeView" /> . That is done with its <see cref= "P:Gtk.TreeView.Selection" /> property.</para>
2003-10-28 00:48:23 +00:00
</remarks>
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "UnselectAll" >
<MemberSignature Language= "C#" Value= "public void UnselectAll ();" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance void UnselectAll() cil managed" />
<MemberType > Method</MemberType>
2003-12-24 01:35:30 +00:00
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > System.Void</ReturnType>
2003-12-24 01:35:30 +00:00
</ReturnValue>
<Parameters />
<Docs >
2011-11-09 16:01:51 +00:00
<summary > Sets all nodes in the <see cref= "T:Gtk.TreeView" /> as unselected.</summary>
<remarks />
2003-12-24 01:35:30 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "UnselectIter" >
<MemberSignature Language= "C#" Value= "public void UnselectIter (Gtk.TreeIter iter);" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance void UnselectIter(valuetype Gtk.TreeIter iter) cil managed" />
2003-12-24 01:35:30 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > System.Void</ReturnType>
</ReturnValue>
<Parameters >
2011-11-09 16:01:51 +00:00
<Parameter Name= "iter" Type= "Gtk.TreeIter" />
2003-12-24 01:35:30 +00:00
</Parameters>
<Docs >
2011-11-09 16:01:51 +00:00
<param name= "iter" > The tree position that should be deselected.</param>
<summary > Deselects the specified position in the tree.</summary>
<remarks >
<para > See also, <see cref= "M:Gtk.TreeSelection.UnselectPath(Gtk.TreePath)" /> and <see cref= "M:Gtk.TreeSelection.UnselectAll()" /> .</para>
</remarks>
<example >
<code language= "C#" >
using System;
using Gtk;
class TreeSelectionSample
{
Label selected;
static void Main ()
{
Application.Init ();
new TreeSelectionSample ();
Application.Run ();
}
TreeSelectionSample ()
{
Window win = new Window ("TreeView selection sample");
win.SetDefaultSize (400, 300);
win.DeleteEvent += new DeleteEventHandler (OnWinDelete);
HBox hbox = new HBox (false, 0);
TreeView tv = new TreeView ();
tv.Selection.Changed += new EventHandler (OnSelectionChanged);
tv.AppendColumn ("items", new CellRendererText (), "text", 0);
TreeStore store = new TreeStore (typeof (string));
for (int i = 0; i < 10; i++)
{
store.AppendValues ("item " + i.ToString ());
}
tv.Model = store;
hbox.PackStart (tv);
selected = new Label ();
hbox.PackStart (selected);
win.Add (hbox);
win.ShowAll ();
}
void OnSelectionChanged (object o, EventArgs args)
{
TreeSelection ts = (TreeSelection) o;
TreeIter iter;
TreeModel model;
ts.GetSelected (out model, out iter);
selected.Text = (string) model.GetValue (iter, 0);
}
void OnWinDelete (object o, DeleteEventArgs args)
{
Application.Quit ();
}
}
</code>
</example>
2003-12-24 01:35:30 +00:00
</Docs>
2005-06-16 18:56:42 +00:00
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "UnselectPath" >
<MemberSignature Language= "C#" Value= "public void UnselectPath (Gtk.TreePath path);" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance void UnselectPath(class Gtk.TreePath path) cil managed" />
2004-02-26 18:46:28 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > System.Void</ReturnType>
2004-02-26 18:46:28 +00:00
</ReturnValue>
<Parameters >
2011-11-09 16:01:51 +00:00
<Parameter Name= "path" Type= "Gtk.TreePath" />
2004-02-26 18:46:28 +00:00
</Parameters>
<Docs >
2011-11-09 16:01:51 +00:00
<param name= "path" > A node in the tree.</param>
<summary > Deselects the tree node that <paramref name= "path" /> refers to.</summary>
<remarks >
<para > See also <see cref= "M:Gtk.TreeSelection.UnselectIter(Gtk.TreeIter)" /> .</para>
</remarks>
2004-06-01 18:05:26 +00:00
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "UnselectRange" >
<MemberSignature Language= "C#" Value= "public void UnselectRange (Gtk.TreePath start_path, Gtk.TreePath end_path);" />
<MemberSignature Language= "ILAsm" Value= ".method public hidebysig instance void UnselectRange(class Gtk.TreePath start_path, class Gtk.TreePath end_path) cil managed" />
2005-01-27 16:56:54 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > System.Void</ReturnType>
2005-01-27 16:56:54 +00:00
</ReturnValue>
2011-11-09 16:01:51 +00:00
<Parameters >
<Parameter Name= "start_path" Type= "Gtk.TreePath" />
<Parameter Name= "end_path" Type= "Gtk.TreePath" />
</Parameters>
2005-01-27 16:56:54 +00:00
<Docs >
2011-11-09 16:01:51 +00:00
<param name= "start_path" >
<see cref= "T:Gtk.TreePath" /> to begin range.</param>
<param name= "end_path" >
<see cref= "T:Gtk.TreePath" /> to end range.</param>
<summary > Unselects everything between one path and another.</summary>
2005-01-27 16:56:54 +00:00
<remarks />
</Docs>
</Member>
2011-11-09 16:01:51 +00:00
<Member MemberName= "UserData" >
<MemberSignature Language= "C#" Value= "public IntPtr UserData { get; }" />
<MemberSignature Language= "ILAsm" Value= ".property instance native int UserData" />
<MemberType > Property</MemberType>
2005-07-20 17:08:28 +00:00
<ReturnValue >
2011-11-09 16:01:51 +00:00
<ReturnType > System.IntPtr</ReturnType>
2005-07-20 17:08:28 +00:00
</ReturnValue>
<Docs >
2011-11-09 16:01:51 +00:00
<summary > Get the data associated with the <see cref= "T:Gtk.TreeSelectionFunc" /> that has been setup for this <see cref= "T:Gtk.TreeSelection" /> .</summary>
<value > The raw data that was set when <see cref= "M:Gtk.TreeSelection.SetSelectFunction(Gtk.TreeSelectionFunc,System.IntPtr,Gtk.DestroyNotify)" /> was called.</value>
<remarks />
2005-07-20 17:08:28 +00:00
</Docs>
</Member>
2003-02-12 02:00:12 +00:00
</Members>
2005-06-17 18:43:30 +00:00
</Type>