1999-08-16 18:51:52 +00:00
|
|
|
<!-- ##### SECTION Title ##### -->
|
|
|
|
GtkButton
|
|
|
|
|
|
|
|
<!-- ##### SECTION Short_Description ##### -->
|
|
|
|
A widget that creates a signal when clicked on.
|
|
|
|
|
|
|
|
<!-- ##### SECTION Long_Description ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
The #GtkButton widget is generally used to attach a function to that
|
|
|
|
is called when the button is pressed. The various signals and how to use
|
|
|
|
them are outlined below.
|
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
The #GtkButton widget can hold any valid child widget. That is it can
|
|
|
|
hold most any other standard #GtkWidget. The most commonly used child is
|
|
|
|
the #GtkLabel.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
<!-- ##### SECTION See_Also ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
<!-- ##### STRUCT GtkButton ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
This should not be accessed directly. Use the accessor functions below.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### FUNCTION gtk_button_new ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
Creates a new #GtkButton widget.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@Returns: The newly created #GtkButton widget.
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### FUNCTION gtk_button_new_with_label ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
Creates a #GtkButton widget with a #GtkLabel child containing the given
|
|
|
|
text.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@label: The text you want the #GtkLabel to hold.
|
|
|
|
@Returns: The newly created #GtkButton widget.
|
|
|
|
|
|
|
|
|
2001-03-23 22:21:06 +00:00
|
|
|
<!-- ##### FUNCTION gtk_button_new_with_mnemonic ##### -->
|
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
|
|
|
@label:
|
|
|
|
@Returns:
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### FUNCTION gtk_button_new_from_stock ##### -->
|
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
|
|
|
@stock_id:
|
|
|
|
@Returns:
|
|
|
|
|
|
|
|
|
1999-08-16 18:51:52 +00:00
|
|
|
<!-- ##### FUNCTION gtk_button_pressed ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
Emits a #GtkButton::pressed signal to the given #GtkButton.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@button: The #GtkButton you want to send the signal to.
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### FUNCTION gtk_button_released ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
Emits a #GtkButton::released signal to the given #GtkButton.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@button: The #GtkButton you want to send the signal to.
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### FUNCTION gtk_button_clicked ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
Emits a #GtkButton::clicked signal to the given #GtkButton.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@button: The #GtkButton you want to send the signal to.
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### FUNCTION gtk_button_enter ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
Emits a #GtkButton::enter signal to the given #GtkButton.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@button: The #GtkButton you want to send the signal to.
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### FUNCTION gtk_button_leave ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
Emits a #GtkButton::leave signal to the given #GtkButton.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@button: The #GtkButton you want to send the signal to.
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### FUNCTION gtk_button_set_relief ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
Sets the relief style of the edges of the given #GtkButton widget.
|
|
|
|
Three styles exist, GTK_RELIEF_NORMAL, GTK_RELIEF_HALF, GTK_RELIEF_NONE.
|
|
|
|
The default style is, as one can guess, GTK_RELIEF_NORMAL.
|
|
|
|
|
|
|
|
<!-- FIXME: put pictures of each style -->
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@button: The #GtkButton you want to set relief styles of.
|
|
|
|
@newstyle: The GtkReliefStyle as described above.
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### FUNCTION gtk_button_get_relief ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
Returns the current relief style of the given #GtkButton.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@button: The #GtkButton you want the #GtkReliefStyle from.
|
|
|
|
@Returns: The current #GtkReliefStyle
|
|
|
|
|
|
|
|
|
2001-10-13 05:52:14 +00:00
|
|
|
<!-- ##### FUNCTION gtk_button_get_label ##### -->
|
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
|
|
|
@button:
|
|
|
|
@Returns:
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### FUNCTION gtk_button_set_label ##### -->
|
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
|
|
|
@button:
|
|
|
|
@label:
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### FUNCTION gtk_button_get_use_stock ##### -->
|
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
|
|
|
@button:
|
|
|
|
@Returns:
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### FUNCTION gtk_button_set_use_stock ##### -->
|
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
|
|
|
@button:
|
2001-10-26 15:44:20 +00:00
|
|
|
@use_stock:
|
|
|
|
<!-- # Unused Parameters # -->
|
2001-10-13 05:52:14 +00:00
|
|
|
@value:
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### FUNCTION gtk_button_get_use_underline ##### -->
|
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
|
|
|
@button:
|
|
|
|
@Returns:
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### FUNCTION gtk_button_set_use_underline ##### -->
|
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
|
|
|
@button:
|
2001-10-26 15:44:20 +00:00
|
|
|
@use_underline:
|
|
|
|
<!-- # Unused Parameters # -->
|
2001-10-13 05:52:14 +00:00
|
|
|
@value:
|
|
|
|
|
|
|
|
|
2001-03-07 14:49:21 +00:00
|
|
|
<!-- ##### SIGNAL GtkButton::activate ##### -->
|
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
|
|
|
@button: the object which received the signal.
|
|
|
|
|
2000-10-29 08:03:34 +00:00
|
|
|
<!-- ##### SIGNAL GtkButton::clicked ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
Emitted when a button clicked on by the mouse and the cursor stays on the
|
|
|
|
button. If the cursor is not on the button when the mouse button is released,
|
|
|
|
the signal is not emitted.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@button: the object which received the signal.
|
|
|
|
|
2000-10-29 08:03:34 +00:00
|
|
|
<!-- ##### SIGNAL GtkButton::enter ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
Emitted when the mouse cursor enters the region of the button.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@button: the object which received the signal.
|
|
|
|
|
2000-10-29 08:03:34 +00:00
|
|
|
<!-- ##### SIGNAL GtkButton::leave ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
Emitted when the mouse cursor leaves the region of the button.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@button: the object which received the signal.
|
|
|
|
|
2000-10-29 08:03:34 +00:00
|
|
|
<!-- ##### SIGNAL GtkButton::pressed ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
Emitted when the button is initially pressed.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@button: the object which received the signal.
|
|
|
|
|
2000-10-29 08:03:34 +00:00
|
|
|
<!-- ##### SIGNAL GtkButton::released ##### -->
|
2002-06-08 06:48:27 +00:00
|
|
|
<para>
|
|
|
|
Emitted when a button which is pressed is released, no matter where the
|
|
|
|
mouse cursor is.
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@button: the object which received the signal.
|
|
|
|
|
|
|
|
<!-- ##### ARG GtkButton:label ##### -->
|
2002-05-28 22:23:55 +00:00
|
|
|
<para>
|
|
|
|
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
<!-- ##### ARG GtkButton:relief ##### -->
|
2002-05-28 22:23:55 +00:00
|
|
|
<para>
|
|
|
|
|
1999-08-16 18:51:52 +00:00
|
|
|
</para>
|
|
|
|
|
2001-08-29 02:20:02 +00:00
|
|
|
<!-- ##### ARG GtkButton:use-underline ##### -->
|
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
|
|
|
<!-- ##### ARG GtkButton:use-stock ##### -->
|
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
2002-09-01 12:34:21 +00:00
|
|
|
<!-- ##### ARG GtkButton:default-border ##### -->
|
2002-05-14 20:55:22 +00:00
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
2002-09-01 12:34:21 +00:00
|
|
|
<!-- ##### ARG GtkButton:child-displacement-y ##### -->
|
2002-05-14 20:55:22 +00:00
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
2002-09-01 12:34:21 +00:00
|
|
|
<!-- ##### ARG GtkButton:child-displacement-x ##### -->
|
2002-05-14 20:55:22 +00:00
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
Minor documentation fixes
2002-08-10 Soren Sandmann <sandmann@daimi.au.dk>
* docs/reference/gtk/tree_widget.sgml,
docs/reference/gtk/tmpl/gtkdialog.sgml,
docs/reference/gtk/tmpl/gtkentry.sgml,
docs/reference/gtk/tmpl/gtkfilesel.sgml,
docs/reference/gtk/tmpl/gtkfontsel.sgml,
docs/reference/gtk/tmpl/gtkfontseldlg.sgml,
docs/reference/gtk/tmpl/gtktreemodel.sgml,
docs/reference/gtk/tmpl/gtkwidget.sgml, gdk/x11/gdkdisplay-x11.c,
gtk/gtkbbox.c, gtk/gtkbox.c, gtk/gtkbutton.c, gtk/gtkcellrenderer.c,
gtk/gtkcellrendererpixbuf.c, gtk/gtkcellrenderertext.c,
gtk/gtkcheckmenuitem.c, gtk/gtkcontainer.c, gtk/gtkcurve.c,
gtk/gtkdialog.h, gtk/gtkentry.c, gtk/gtkfilesel.c, gtk/gtkfontsel.c,
gtk/gtkframe.c, gtk/gtkhandlebox.c, gtk/gtkiconfactory.c,
gtk/gtkimage.c, gtk/gtkinvisible.c, gtk/gtkitemfactory.c,
gtk/gtklabel.c, gtk/gtklayout.c, gtk/gtkmenu.c, gtk/gtkprogress.c,
gtk/gtkprogressbar.c, gtk/gtkscrolledwindow.c, gtk/gtksizegroup.c,
gtk/gtktable.c, gtk/gtktextiter.c, gtk/gtktexttag.c,
gtk/gtktexttag.h, gtk/gtktextview.c, gtk/gtktogglebutton.c,
gtk/gtktoolbar.c, gtk/gtktreemodel.c, gtk/gtktreeselection.c,
gtk/gtktreestore.c, gtk/gtktreeview.c, gtk/gtktreeviewcolumn.c,
gtk/gtkviewport.c, gtk/gtkwidget.c, gtk/gtkwidget.h,
gtk/gtkwindow.c:
Minor documentation fixes
(#89254, patch from Brett Nash;
#85809, patch from daten@dnetc.org;
#76391, patch from Ross Burton;
#74559, Manuel Clos;
#73569, #72005, Alexey A. Malyshev;
#70061, patch from Dennis Bj"orklund;
#64566, #63388, #58328, #57499, #81007, #77349, Vitaly Tishkov;
#78932, Vitaly Tishkov, patch from Ross Burton;
#73306)
2002-08-10 09:55:41 +00:00
|
|
|
<!-- ##### ARG GtkButton:default-outside-border ##### -->
|
2002-05-14 20:55:22 +00:00
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|