2003-02-20 04:03:15 +00:00
<Type Name= "Button" FullName= "Gtk.Button" >
<TypeSignature Language= "C#" Value= "public class Button : Gtk.Bin, Implementor, IWrapper, IWrapper, IDisposable" Maintainer= "Duncan Mak" />
2003-02-12 02:00:12 +00:00
<AssemblyInfo >
<AssemblyName > gtk-sharp</AssemblyName>
<AssemblyVersion > 0.0.0.0</AssemblyVersion>
<Attributes />
</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>
2003-02-12 02:00:12 +00:00
<Docs >
2003-02-20 04:03:15 +00:00
<summary > A widget that creates a signal when clicked on.</summary>
<remarks >
<para >
2003-07-17 06:38:40 +00:00
The <see cref= "T:Gtk.Button" /> widget is generally used to attach to a function that is called when the button is pressed.
The <see cref= "T:Gtk.Button" /> widget can hold any valid child widget.
2003-05-30 04:30:12 +00:00
That is, it can hold most any other standard <see cref= "T:Gtk.Widget" /> . The most commonly used child is the <see cref= "T:Gtk.Label" /> .
2003-02-20 04:03:15 +00:00
</para>
2003-07-17 06:38:40 +00:00
<example >
<code lang= "C#" >
2003-05-30 04:30:12 +00:00
using Gtk;
using GtkSharp;
using System;
public class ButtonApp {
public static int Main (string[] args)
{
Application.Init ();
Window win = new Window ("Button Tester");
win.DefaultSize = new Size (200, 150);
win.DeleteEvent += new DeleteEventHandler (Window_Delete);
Button btn = new Button ("Click Me");
btn.Clicked += new EventHandler (btn_click);
win.Add (btn);
win.ShowAll ();
Application.Run ();
return 0;
}
static void btn_click (object obj, EventArgs args)
{
Console.WriteLine ("Button Clicked");
}
static void Window_Delete (object obj, DeleteEventArgs args)
{
Application.Quit ();
args.RetVal = true;
}
}
</code>
2003-07-17 06:38:40 +00:00
</example>
2003-02-20 04:03:15 +00:00
</remarks>
2003-02-12 02:00:12 +00:00
</Docs>
<Base >
2003-02-20 04:03:15 +00:00
<BaseTypeName > Gtk.Bin</BaseTypeName>
2003-02-12 02:00:12 +00:00
</Base>
<Interfaces >
<Interface >
<InterfaceName > Atk.Implementor</InterfaceName>
</Interface>
<Interface >
<InterfaceName > GLib.IWrapper</InterfaceName>
</Interface>
<Interface >
<InterfaceName > GLib.IWrapper</InterfaceName>
</Interface>
<Interface >
<InterfaceName > System.IDisposable</InterfaceName>
</Interface>
</Interfaces>
<Attributes />
<Members >
2003-03-15 22:50:24 +00:00
<Member MemberName= "GType" >
<MemberSignature Language= "C#" Value= "public static uint GType { get; };" />
2003-03-07 01:30:00 +00:00
<MemberType > Property</MemberType>
<ReturnValue >
2003-03-15 22:50:24 +00:00
<ReturnType > System.UInt32</ReturnType>
2003-03-07 01:30:00 +00:00
</ReturnValue>
<Docs >
2003-07-17 06:38:40 +00:00
<summary > The <see cref= "T:GLib.Type" /> for <see cref= "T:Gtk.Button" /> .</summary>
<returns > The <see cref= "T:GLib.Type" /> for the <see cref= "T:Gtk.Button" /> class.</returns>
2003-05-14 12:14:31 +00:00
<remarks />
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "UseStock" >
<MemberSignature Language= "C#" Value= "public bool UseStock { set; get; };" />
<MemberType > Property</MemberType>
<ReturnValue >
<ReturnType > System.Boolean</ReturnType>
</ReturnValue>
2003-09-17 21:56:59 +00:00
<Parameters > </Parameters>
2003-03-15 22:50:24 +00:00
<Docs >
2003-07-17 06:38:40 +00:00
<summary > Whether the <see cref= "T:Gtk.Button" /> should use a <see cref= "T:Gtk.Stock" /> .</summary>
2003-05-14 12:14:31 +00:00
<param name= "value" > Boolean value to select if the
2003-07-17 06:38:40 +00:00
<see cref= "T:Gtk.Button" /> uses a <see cref= "T:Gtk.Stock" /> or not.</param>
<returns > Gets a value indicating if the <see cref= "T:Gtk.Button" /> uses a <see cref= "T:Gtk.Stock" /> .</returns>
<remarks > It's possible to create a <see cref= "T:Gtk.Button" /> from <see cref= "T:Gtk.Stock" /> , which is recommended for consistency in <see cref= "N:Gnome" />
2003-05-14 12:14:31 +00:00
apps. They also provide a <see cref= "T:Gtk.Label" /> and a key shortcut.
</remarks>
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "UseUnderline" >
<MemberSignature Language= "C#" Value= "public bool UseUnderline { set; get; };" />
<MemberType > Property</MemberType>
<ReturnValue >
<ReturnType > System.Boolean</ReturnType>
</ReturnValue>
2003-09-17 21:56:59 +00:00
<Parameters > </Parameters>
2003-03-15 22:50:24 +00:00
<Docs >
2003-07-17 06:38:40 +00:00
<summary > Indicates if a mnemonic is associated with the <see cref= "T:Gtk.Button" /> .</summary>
<param name= "value" > Boolean value to select if the <see cref= "T:Gtk.Button" /> uses
2003-05-14 12:14:31 +00:00
underline or not.</param>
2003-07-17 06:38:40 +00:00
<returns > Gets a value indicating if the <see cref= "T:Gtk.Button" /> uses underline
2003-05-14 12:14:31 +00:00
or not.</returns>
<remarks />
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "Relief" >
<MemberSignature Language= "C#" Value= "public Gtk.ReliefStyle Relief { set; get; };" />
<MemberType > Property</MemberType>
<ReturnValue >
<ReturnType > Gtk.ReliefStyle</ReturnType>
</ReturnValue>
2003-09-17 21:56:59 +00:00
<Parameters > </Parameters>
2003-03-15 22:50:24 +00:00
<Docs >
2003-07-17 06:38:40 +00:00
<summary > The <see cref= "T:Gtk.ReliefStyle" /> for the <see cref= "T:Gtk.Button" /> .</summary>
2003-05-14 12:14:31 +00:00
<param name= "value" > The <see cref= "T:Gtk.ReliefStyle" /> for
2003-07-17 06:38:40 +00:00
the <see cref= "T:Gtk.Button" /> .</param>
2003-05-14 12:14:31 +00:00
<returns > An instance of <see cref= "T:Gtk.ReliefStyle" /> that
2003-07-17 06:38:40 +00:00
represents the relief style of the <see cref= "T:Gtk.Button" /> .</returns>
2003-05-14 12:14:31 +00:00
<remarks />
2003-03-15 22:50:24 +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>
2003-09-17 21:56:59 +00:00
<Parameters > </Parameters>
2003-03-15 22:50:24 +00:00
<Docs >
2003-07-17 06:38:40 +00:00
<summary > The text of the <see cref= "T:Gtk.Label" /> in the <see cref= "T:Gtk.Button" /> .</summary>
2003-05-30 04:30:12 +00:00
<param name= "value" > A <see cref= "T:System.String" /> to be used for
2003-07-17 06:38:40 +00:00
the <see cref= "T:Gtk.Button" /> 's <see cref= "T:Gtk.Label" /> </param>
<returns > The <see cref= "T:System.String" /> contained by the <see cref= "T:Gtk.Button" /> .</returns>
2003-05-14 12:14:31 +00:00
<remarks />
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "Activated" >
<MemberSignature Language= "C#" Value= "public event EventHandler Activated;" />
<MemberType > Event</MemberType>
2003-09-17 21:56:59 +00:00
<ReturnValue >
<ReturnType > System.EventHandler</ReturnType>
</ReturnValue>
2003-03-15 22:50:24 +00:00
<Parameters />
<Docs >
2003-05-21 21:31:19 +00:00
<summary >
2003-07-17 06:38:40 +00:00
Event launched when the <see cref= "T:Gtk.Button" /> is activated.</summary>
2003-05-14 12:14:31 +00:00
<remarks />
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "Clicked" >
<MemberSignature Language= "C#" Value= "public event EventHandler Clicked;" />
<MemberType > Event</MemberType>
2003-09-17 21:56:59 +00:00
<ReturnValue >
<ReturnType > System.EventHandler</ReturnType>
</ReturnValue>
2003-03-15 22:50:24 +00:00
<Parameters />
<Docs >
2003-05-21 21:31:19 +00:00
<summary >
2003-07-17 06:38:40 +00:00
Event launched when the <see cref= "T:Gtk.Button" /> is clicked.</summary>
2003-05-14 12:14:31 +00:00
<remarks />
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "Left" >
<MemberSignature Language= "C#" Value= "public event EventHandler Left;" />
<MemberType > Event</MemberType>
2003-09-17 21:56:59 +00:00
<ReturnValue >
<ReturnType > System.EventHandler</ReturnType>
</ReturnValue>
2003-03-15 22:50:24 +00:00
<Parameters />
<Docs >
2003-05-21 21:31:19 +00:00
<summary >
2003-07-17 06:38:40 +00:00
Event launched when the cursor leaves the <see cref= "T:Gtk.Button" /> area.</summary>
2003-05-14 12:14:31 +00:00
<remarks />
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "Pressed" >
<MemberSignature Language= "C#" Value= "public event EventHandler Pressed;" />
<MemberType > Event</MemberType>
2003-09-17 21:56:59 +00:00
<ReturnValue >
<ReturnType > System.EventHandler</ReturnType>
</ReturnValue>
2003-03-15 22:50:24 +00:00
<Parameters />
<Docs >
2003-05-21 21:31:19 +00:00
<summary >
2003-07-17 06:38:40 +00:00
Event launched when the <see cref= "T:Gtk.Button" /> is pressed.</summary>
2003-05-14 12:14:31 +00:00
<remarks />
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "Released" >
<MemberSignature Language= "C#" Value= "public event EventHandler Released;" />
<MemberType > Event</MemberType>
2003-09-17 21:56:59 +00:00
<ReturnValue >
<ReturnType > System.EventHandler</ReturnType>
</ReturnValue>
2003-03-15 22:50:24 +00:00
<Parameters />
<Docs >
2003-05-21 21:31:19 +00:00
<summary >
2003-07-17 06:38:40 +00:00
Event launched when the <see cref= "T:Gtk.Button" /> is released.</summary>
2003-05-14 12:14:31 +00:00
<remarks />
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "Entered" >
<MemberSignature Language= "C#" Value= "public event EventHandler Entered;" />
<MemberType > Event</MemberType>
2003-09-17 21:56:59 +00:00
<ReturnValue >
<ReturnType > System.EventHandler</ReturnType>
</ReturnValue>
2003-03-15 22:50:24 +00:00
<Parameters />
<Docs >
2003-05-21 21:31:19 +00:00
<summary >
2003-07-17 06:38:40 +00:00
Event launched when the cursor enters the <see cref= "T:Gtk.Button" /> area.</summary>
2003-05-14 12:14:31 +00:00
<remarks />
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "ActionGetType" >
<MemberSignature Language= "C#" Value= "public static uint ActionGetType ();" />
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > System.UInt32</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
<summary > To be added</summary>
2003-07-17 06:38:40 +00:00
<returns > an object of type <see cref= "T:System.UInt32" /> </returns>
2003-03-15 22:50:24 +00:00
<remarks > To be added</remarks>
</Docs>
</Member>
<Member MemberName= "NewWithLabel" >
<MemberSignature Language= "C#" Value= "public static Gtk.Button NewWithLabel (string label);" />
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > Gtk.Button</ReturnType>
</ReturnValue>
<Parameters >
2003-09-17 21:56:59 +00:00
<Parameter Name= "label" Type= "System.String" />
</Parameters>
2003-03-15 22:50:24 +00:00
<Docs >
2003-07-17 06:38:40 +00:00
<summary > Creates a <see cref= "T:Gtk.Button" /> widget with a <see cref= "T:Gtk.Label" /> child containing the given text.</summary>
2003-07-04 07:49:31 +00:00
<param name= "label" >
The text you want the <see cref= "T:Gtk.Label" /> to hold.
</param>
<returns > The newly created <see cref= "T:Gtk.Button" /> widget.</returns>
<remarks />
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "NewFromStock" >
<MemberSignature Language= "C#" Value= "public static Gtk.Button NewFromStock (string stock_id);" />
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > Gtk.Button</ReturnType>
</ReturnValue>
<Parameters >
2003-09-17 21:56:59 +00:00
<Parameter Name= "stock_id" Type= "System.String" />
</Parameters>
2003-03-15 22:50:24 +00:00
<Docs >
2003-07-04 07:49:31 +00:00
<summary > Creates a new <see cref= "T:Gtk.Button" /> containing the image and text from a stock item.</summary>
<param name= "stock_id" > The name of the stock item</param>
<returns > a new <see cref= "T:Gtk.Button" /> </returns>
<remarks >
2003-07-17 06:38:40 +00:00
The valid names of Stock items can be found in the <see cref= "T:Gtk.Stock" /> class.
2003-07-04 07:49:31 +00:00
</remarks>
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "Leave" >
<MemberSignature Language= "C#" Value= "public void Leave ();" />
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > System.Void</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2003-07-17 06:38:40 +00:00
<summary > Emits a <see cref= "E:Gtk.Button.Left" /> signal to the given <see cref= "T:Gtk.Button" /> .</summary>
<remarks > Emits a <see cref= "E:Gtk.Button.Left" /> signal to the given <see cref= "T:Gtk.Button" /> .</remarks>
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "Press" >
<MemberSignature Language= "C#" Value= "public void Press ();" />
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > System.Void</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2003-07-17 06:38:40 +00:00
<summary > Emits a <see cref= "E:Gtk.Button.Pressed" /> signal to the given <see cref= "T:Gtk.Button" /> .</summary>
<remarks > Emits a <see cref= "E:Gtk.Button.Pressed" /> signal to the given <see cref= "T:Gtk.Button" /> .</remarks>
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "Release" >
<MemberSignature Language= "C#" Value= "public void Release ();" />
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > System.Void</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2003-07-17 06:38:40 +00:00
<summary > Emits a <see cref= "E:Gtk.Button.Released" /> signal to the given <see cref= "T:Gtk.Button" /> .</summary>
<remarks > Emits a <see cref= "E:Gtk.Button.Released" /> signal to the given <see cref= "T:Gtk.Button" /> .</remarks>
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "Click" >
<MemberSignature Language= "C#" Value= "public void Click ();" />
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > System.Void</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2003-07-17 06:38:40 +00:00
<summary > Emits a <see cref= "E:Gtk.Button.Clicked" /> signal to the given <see cref= "T:Gtk.Button" /> .</summary>
<remarks > Emits a <see cref= "E:Gtk.Button.Clicked" /> signal to the given <see cref= "T:Gtk.Button" /> .</remarks>
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "Enter" >
<MemberSignature Language= "C#" Value= "public void Enter ();" />
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > System.Void</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2003-07-17 06:38:40 +00:00
<summary > Emits a <see cref= "E:Gtk.Button.Entered" /> signal to the given <see cref= "T:Gtk.Button" /> .</summary>
<remarks > Emits a <see cref= "E:Gtk.Button.Entered" /> signal to the given <see cref= "T:Gtk.Button" /> .</remarks>
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= "Finalize" >
2003-10-13 22:55:58 +00:00
<MemberSignature Language= "C#" Value= "protected override void Finalize ();" />
2003-03-15 22:50:24 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > System.Void</ReturnType>
</ReturnValue>
<Parameters />
<Docs >
2003-05-14 12:14:31 +00:00
<summary > Disposes the resources associated with this object.</summary>
<remarks />
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= ".ctor" >
<MemberSignature Language= "C#" Value= "protected Button (GLib.Type gtype);" />
<MemberType > Constructor</MemberType>
<ReturnValue />
<Parameters >
2003-09-17 21:56:59 +00:00
<Parameter Name= "gtype" Type= "GLib.Type" />
</Parameters>
2003-03-15 22:50:24 +00:00
<Docs >
2003-05-14 12:14:31 +00:00
<summary > Internal constructor</summary>
<param name= "gtype" > GLib type for the type.</param>
2003-07-17 06:38:40 +00:00
<returns > Creates a new instance of <see cref= "T:Gtk.Button" /> , using the GLib provided type.</returns>
2003-05-14 12:14:31 +00:00
<remarks > This is a constructor used by derivative types of
<see cref= "T:Gtk.Button" /> that would have their own GLib type
assigned to it. This is not typically used by C# code.</remarks>
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= ".ctor" >
<MemberSignature Language= "C#" Value= "public Button ();" />
<MemberType > Constructor</MemberType>
<ReturnValue />
<Parameters />
<Docs >
2003-05-14 12:14:31 +00:00
<summary > Default parameterless constructor.</summary>
2003-07-17 06:38:40 +00:00
<returns > An instance of <see cref= "T:Gtk.Button" /> .</returns>
<remarks > This is the default constructor for the <see cref= "T:Gtk.Button" /> class.</remarks>
2003-03-15 22:50:24 +00:00
</Docs>
</Member>
<Member MemberName= ".ctor" >
<MemberSignature Language= "C#" Value= "public Button (string label);" />
<MemberType > Constructor</MemberType>
<ReturnValue />
<Parameters >
2003-09-17 21:56:59 +00:00
<Parameter Name= "label" Type= "System.String" />
</Parameters>
2003-03-15 22:50:24 +00:00
<Docs >
2003-07-17 06:38:40 +00:00
<summary > Constructor that creates a labeled <see cref= "T:Gtk.Button" /> .</summary>
2003-05-30 04:30:12 +00:00
<param name= "label" > A <see cref= "T:System.String" /> that will be
2003-07-17 06:38:40 +00:00
used to create a <see cref= "T:Gtk.Label" /> for the <see cref= "T:Gtk.Button" /> </param>
<returns > A <see cref= "T:Gtk.Button" /> containing a <see cref= "T:Gtk.Label" />
with the specified <see cref= "T:System.String" /> .</returns>
<remarks > Constructor that creates a labeled <see cref= "T:Gtk.Button" /> . The label
2003-05-14 12:14:31 +00:00
shows the string passed as parameter.</remarks>
2003-03-07 01:30:00 +00:00
</Docs>
</Member>
2003-05-21 21:31:19 +00:00
<Member MemberName= ".ctor" >
<MemberSignature Language= "C#" Value= "public Button (IntPtr raw);" />
<MemberType > Constructor</MemberType>
<ReturnValue />
<Parameters >
2003-09-17 21:56:59 +00:00
<Parameter Name= "raw" Type= "System.IntPtr" />
</Parameters>
2003-05-21 21:31:19 +00:00
<Docs >
<summary > To be added</summary>
2003-07-17 06:38:40 +00:00
<param name= "raw" > an object of type <see cref= "T:System.IntPtr" /> </param>
<returns > an object of type <see cref= "T:Gtk.Button" /> </returns>
2003-05-21 21:31:19 +00:00
<remarks > To be added</remarks>
</Docs>
</Member>
2003-02-12 02:00:12 +00:00
</Members>
2003-09-17 21:56:59 +00:00
</Type>