2004-11-05 21:25:40 +00:00
<Type Name= "Expander" FullName= "Gtk.Expander" >
2005-05-23 20:41:51 +00:00
<TypeSignature Language= "C#" Maintainer= "auto" Value= "public class Expander : Gtk.Bin" />
2004-11-05 21:25:40 +00:00
<AssemblyInfo >
<AssemblyName > gtk-sharp</AssemblyName>
<AssemblyPublicKey > [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4]</AssemblyPublicKey>
2005-06-17 18:43:30 +00:00
<AssemblyVersion > 2.6.0.0</AssemblyVersion>
2004-11-05 21:25:40 +00:00
</AssemblyInfo>
<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>
<Docs >
2004-12-05 21:05:29 +00:00
<summary > A container which can hide its child</summary>
<remarks >
<para >
A <see cref= "T:Gtk.Expander" /> allows the user to hide or show its child by clicking on an expander triangle similar to the triangles used in a <see cref= "T:Gtk.TreeView" /> .
</para>
<para >
Normally you use an expander as you would use any other descendant of <see cref= "T:Gtk.Bin" /> ; you create the child widget and use <see cref= "M:Gtk.Container.Add()" /> to add it to the expander. When the expander is toggled, it will take care of showing and hiding the child automatically.
</para>
<example >
<code lang= "C#" >
using System;
using Gtk;
class DemoExpander : Gtk.Window
{
static void Main ()
{
Application.Init ();
new DemoExpander ();
Application.Run ();
}
DemoExpander () : base ("Demo Expander")
{
this.BorderWidth = 10;
this.DeleteEvent += new DeleteEventHandler (OnWindowDelete);
VBox vbox = new VBox ();
vbox.PackStart (new Label ("Expander demo. Click on the triangle for details."), false, true, 3);
Expander expander = new Expander ("Details");
expander.Add (new Label ("Details can be shown or hidden."));
vbox.PackStart (expander, false, true, 3);
this.Add (vbox);
this.ShowAll ();
}
void OnWindowDelete (object sender, DeleteEventArgs a)
{
Application.Quit ();
}
}
</code>
</example>
<para >
Special Usage
</para>
<para >
There there are situations in which you may prefer to show and hide the expanded widget yourself, such as when you want to actually create the widget at expansion time. In this case, create a <see cref= "T:Gtk.Expander" /> but do not add a child to it. The expander widget has <see cref= "E:Gtk.Expander.Activated" /> which can be used to monitor its expansion state.
</para>
<example >
<code lang= "C#" >
using System;
using Gtk;
class DemoExpander : Gtk.Window
{
static void Main ()
{
Application.Init ();
new DemoExpander ();
Application.Run ();
}
DemoExpander () : base ("Demo Expander")
{
this.BorderWidth = 10;
this.DeleteEvent += new DeleteEventHandler (OnWindowDelete);
VBox vbox = new VBox ();
vbox.PackStart (new Label ("Expander demo. Click on the triangle for details."), false, true, 3);
Expander expander = new Expander ("Details");
expander.Activated += new EventHandler (OnExpanded);
vbox.PackStart (expander, false, true, 3);
this.Add (vbox);
this.ShowAll ();
}
void OnExpanded (object sender, EventArgs a)
{
Expander expander = sender as Expander;
if (expander.Child == null)
{
expander.Add (new Label ("Details can be shown or hidden."));
expander.ShowAll ();
}
}
void OnWindowDelete (object sender, DeleteEventArgs a)
{
Application.Quit ();
}
}
</code>
</example>
</remarks>
2005-06-16 18:56:42 +00:00
<since version= "Gtk# 2.4" />
2004-11-05 21:25:40 +00:00
</Docs>
<Base >
<BaseTypeName > Gtk.Bin</BaseTypeName>
</Base>
<Interfaces >
</Interfaces>
<Members >
<Member MemberName= "OnActivated" >
<MemberSignature Language= "C#" Value= "protected virtual void OnActivated ();" />
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > System.Void</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2004-12-05 21:05:29 +00:00
<summary > Default handler for the <see cref= "E:Gtk.Expander.Activated" /> event.</summary>
<remarks > Override this method in a subclass to provide a default handler for the <see cref= "E:Gtk.Entry.Activated" /> event.</remarks>
2004-11-05 21:25:40 +00:00
</Docs>
</Member>
<Member MemberName= ".ctor" >
<MemberSignature Language= "C#" Value= "protected Expander (GLib.GType gtype);" />
<MemberType > Constructor</MemberType>
<ReturnValue />
<Parameters >
<Parameter Name= "gtype" Type= "GLib.GType" />
</Parameters>
<Docs >
2004-12-05 21:05:29 +00:00
<summary > Internal constructor</summary>
2004-11-05 21:25:40 +00:00
<param name= "gtype" > a <see cref= "T:GLib.GType" /> </param>
2004-12-05 21:05:29 +00:00
<remarks />
2004-11-05 21:25:40 +00:00
</Docs>
2005-06-16 18:56:42 +00:00
<Attributes >
2005-05-23 20:41:51 +00:00
<Attribute >
<AttributeName > System.Obsolete(Message=null, IsError=False)</AttributeName>
</Attribute>
2005-06-16 18:56:42 +00:00
</Attributes>
</Member>
2004-11-05 21:25:40 +00:00
<Member MemberName= ".ctor" >
<MemberSignature Language= "C#" Value= "public Expander (IntPtr raw);" />
<MemberType > Constructor</MemberType>
<ReturnValue />
<Parameters >
<Parameter Name= "raw" Type= "System.IntPtr" />
</Parameters>
<Docs >
2004-12-05 21:05:29 +00:00
<summary > Internal constructor</summary>
2004-11-05 21:25:40 +00:00
<param name= "raw" > a <see cref= "T:System.IntPtr" /> </param>
2004-12-05 21:05:29 +00:00
<remarks />
2004-11-05 21:25:40 +00:00
</Docs>
</Member>
<Member MemberName= ".ctor" >
<MemberSignature Language= "C#" Value= "public Expander (string label);" />
<MemberType > Constructor</MemberType>
<ReturnValue />
<Parameters >
<Parameter Name= "label" Type= "System.String" />
</Parameters>
<Docs >
2004-12-05 21:05:29 +00:00
<summary > Creates a new expander with <paramref name= "label" /> as its label.</summary>
2004-11-05 21:25:40 +00:00
<param name= "label" > a <see cref= "T:System.String" /> </param>
2004-12-05 21:05:29 +00:00
<remarks />
2004-11-05 21:25:40 +00:00
</Docs>
</Member>
<Member MemberName= "GType" >
<MemberSignature Language= "C#" Value= "public static GLib.GType GType { get; };" />
<MemberType > Property</MemberType>
<ReturnValue >
<ReturnType > GLib.GType</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2004-12-05 21:05:29 +00:00
<summary > GType Property.</summary>
2005-05-23 20:41:51 +00:00
<value > a <see cref= "T:GLib.GType" /> </value>
2004-12-05 21:05:29 +00:00
<remarks > Returns the native <see cref= "T:GLib.GType" /> value for <see cref= "T:Gtk.Expander" /> .</remarks>
2004-11-05 21:25:40 +00:00
</Docs>
</Member>
<Member MemberName= "Label" >
<MemberSignature Language= "C#" Value= "public string Label { set; get; };" />
<MemberType > Property</MemberType>
<ReturnValue >
<ReturnType > System.String</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2004-12-05 21:05:29 +00:00
<summary > The text of the label of the expander.</summary>
2005-05-23 20:41:51 +00:00
<value > a <see cref= "T:System.String" /> </value>
2004-12-05 21:05:29 +00:00
<remarks >
<para >
If the label text has not been set the return value will be <see langword= "null " /> .
</para>
<para >
Setting the label will also clear any previously set labels.
</para>
</remarks>
2004-11-05 21:25:40 +00:00
</Docs>
2005-06-16 18:56:42 +00:00
<Attributes >
2005-05-23 20:41:51 +00:00
<Attribute >
<AttributeName > GLib.Property(Name="label")</AttributeName>
</Attribute>
2005-06-16 18:56:42 +00:00
</Attributes>
</Member>
2004-11-05 21:25:40 +00:00
<Member MemberName= "UseMarkup" >
<MemberSignature Language= "C#" Value= "public bool UseMarkup { set; get; };" />
<MemberType > Property</MemberType>
<ReturnValue >
<ReturnType > System.Boolean</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2004-12-05 21:05:29 +00:00
<summary > Whether the text of the label contains markup in Pango's text markup language.</summary>
2005-05-23 20:41:51 +00:00
<value > a <see cref= "T:System.Boolean" /> , <see langword= "true" /> if the label's text should be parsed for markup
2004-12-05 21:05:29 +00:00
2005-05-23 20:41:51 +00:00
</value>
2004-12-05 21:05:29 +00:00
<remarks />
2004-11-05 21:25:40 +00:00
</Docs>
2005-06-16 18:56:42 +00:00
<Attributes >
2005-05-23 20:41:51 +00:00
<Attribute >
<AttributeName > GLib.Property(Name="use_markup")</AttributeName>
</Attribute>
2005-06-16 18:56:42 +00:00
</Attributes>
</Member>
2004-11-05 21:25:40 +00:00
<Member MemberName= "Spacing" >
<MemberSignature Language= "C#" Value= "public int Spacing { set; get; };" />
<MemberType > Property</MemberType>
<ReturnValue >
<ReturnType > System.Int32</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2004-12-05 21:05:29 +00:00
<summary > Space to put between the label and the child.</summary>
2005-05-23 20:41:51 +00:00
<value > a <see cref= "T:System.Int32" /> </value>
2004-12-05 21:05:29 +00:00
<remarks >
<para >
Allowed values: > = 0
</para>
<para >
Default value: 0
</para>
</remarks>
2004-11-05 21:25:40 +00:00
</Docs>
2005-06-16 18:56:42 +00:00
<Attributes >
2005-05-23 20:41:51 +00:00
<Attribute >
<AttributeName > GLib.Property(Name="spacing")</AttributeName>
</Attribute>
2005-06-16 18:56:42 +00:00
</Attributes>
</Member>
2004-11-05 21:25:40 +00:00
<Member MemberName= "Expanded" >
<MemberSignature Language= "C#" Value= "public bool Expanded { set; get; };" />
<MemberType > Property</MemberType>
<ReturnValue >
<ReturnType > System.Boolean</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2004-12-05 21:05:29 +00:00
<summary > The state of the expander.</summary>
2005-05-23 20:41:51 +00:00
<value > a <see cref= "T:System.Boolean" /> </value>
2004-12-05 21:05:29 +00:00
<remarks > Returns <see langword= "true" /> if the child widget is revealed.</remarks>
2004-11-05 21:25:40 +00:00
</Docs>
2005-06-16 18:56:42 +00:00
<Attributes >
2005-05-23 20:41:51 +00:00
<Attribute >
<AttributeName > GLib.Property(Name="expanded")</AttributeName>
</Attribute>
2005-06-16 18:56:42 +00:00
</Attributes>
</Member>
2004-11-05 21:25:40 +00:00
<Member MemberName= "UseUnderline" >
<MemberSignature Language= "C#" Value= "public bool UseUnderline { set; get; };" />
<MemberType > Property</MemberType>
<ReturnValue >
<ReturnType > System.Boolean</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2004-12-05 21:05:29 +00:00
<summary > Whether an embedded underline in the expander label indicates a mnemonic.</summary>
2005-05-23 20:41:51 +00:00
<value > a <see cref= "T:System.Boolean" /> , <see langword= "true" /> if underlines in the text indicate mnemonics</value>
2004-12-05 21:05:29 +00:00
<remarks />
2004-11-05 21:25:40 +00:00
</Docs>
2005-06-16 18:56:42 +00:00
<Attributes >
2005-05-23 20:41:51 +00:00
<Attribute >
<AttributeName > GLib.Property(Name="use_underline")</AttributeName>
</Attribute>
2005-06-16 18:56:42 +00:00
</Attributes>
</Member>
2004-11-05 21:25:40 +00:00
<Member MemberName= "LabelWidget" >
<MemberSignature Language= "C#" Value= "public Gtk.Widget LabelWidget { set; get; };" />
<MemberType > Property</MemberType>
<ReturnValue >
<ReturnType > Gtk.Widget</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2004-12-05 21:05:29 +00:00
<summary > The label widget for the expander.</summary>
2005-05-23 20:41:51 +00:00
<value > the label <see cref= "T:Gtk.Widget" /> , or <see langword= "null" /> if there is none.</value>
2004-12-05 21:05:29 +00:00
<remarks > This is the widget that will appear embedded alongside the expander arrow.</remarks>
2004-11-05 21:25:40 +00:00
</Docs>
2005-06-16 18:56:42 +00:00
<Attributes >
2005-05-23 20:41:51 +00:00
<Attribute >
<AttributeName > GLib.Property(Name="label_widget")</AttributeName>
</Attribute>
2005-06-16 18:56:42 +00:00
</Attributes>
</Member>
2004-11-05 21:25:40 +00:00
<Member MemberName= "Activated" >
<MemberSignature Language= "C#" Value= "public event EventHandler Activated;" />
<MemberType > Event</MemberType>
<ReturnValue >
<ReturnType > System.EventHandler</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2004-12-05 21:05:29 +00:00
<summary > Emitted when the expander is toggled.</summary>
<remarks />
2004-11-05 21:25:40 +00:00
</Docs>
2005-06-16 18:56:42 +00:00
<Attributes >
2005-05-23 20:41:51 +00:00
<Attribute >
<AttributeName > GLib.Signal(CName="activate")</AttributeName>
</Attribute>
2005-06-16 18:56:42 +00:00
</Attributes>
</Member>
2004-12-08 18:57:08 +00:00
<Member MemberName= "New" >
<MemberSignature Language= "C#" Value= "public static Gtk.Expander New (string label);" />
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > Gtk.Expander</ReturnType>
</ReturnValue>
<Parameters >
<Parameter Name= "label" Type= "System.String" />
</Parameters>
<Docs >
2005-01-03 17:38:13 +00:00
<summary > Public constructor.</summary>
2004-12-08 18:57:08 +00:00
<param name= "label" > a <see cref= "T:System.String" /> </param>
<returns > a <see cref= "T:Gtk.Expander" /> </returns>
2005-05-23 20:41:51 +00:00
<remarks >
</remarks>
2004-12-08 18:57:08 +00:00
</Docs>
</Member>
2004-11-05 21:25:40 +00:00
</Members>
2005-06-17 18:43:30 +00:00
</Type>