<?xml version="1.0"?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
               "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
<!ENTITY % local.common.attrib "xmlns:xi  CDATA  #FIXED 'http://www.w3.org/2003/XInclude'">
<!ENTITY version SYSTEM "version.xml">
]>
<!--ENTITY index-Objects-Grouped SYSTEM "objects_grouped.sgml"-->
<refentry id="GtkCheckButton">
<refmeta>
<refentrytitle role="top_of_page" id="GtkCheckButton.top_of_page">GtkCheckButton</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>GTK Library</refmiscinfo>
</refmeta>

<refnamediv>
<refname>GtkCheckButton</refname>
<refpurpose>Create widgets with a discrete toggle button</refpurpose>
</refnamediv>

<refsynopsisdiv id="GtkCheckButton.synopsis" role="synopsis">
<title role="synopsis.title">Synopsis</title>

<synopsis>

#include &lt;gtk/gtk.h&gt;

                    <link linkend="GtkCheckButton-struct">GtkCheckButton</link>;
<link linkend="GtkWidget">GtkWidget</link>*          <link linkend="gtk-check-button-new">gtk_check_button_new</link>                (void);
<link linkend="GtkWidget">GtkWidget</link>*          <link linkend="gtk-check-button-new-with-label">gtk_check_button_new_with_label</link>     (const <link linkend="gchar">gchar</link> *label);
<link linkend="GtkWidget">GtkWidget</link>*          <link linkend="gtk-check-button-new-with-mnemonic">gtk_check_button_new_with_mnemonic</link>  (const <link linkend="gchar">gchar</link> *label);
</synopsis>
</refsynopsisdiv>

<refsect1 id="GtkCheckButton.object-hierarchy" role="object_hierarchy">
<title role="object_hierarchy.title">Object Hierarchy</title>
<synopsis>
  <link linkend="GObject">GObject</link>
   +----<link linkend="GInitiallyUnowned">GInitiallyUnowned</link>
         +----<link linkend="GtkObject">GtkObject</link>
               +----<link linkend="GtkWidget">GtkWidget</link>
                     +----<link linkend="GtkContainer">GtkContainer</link>
                           +----<link linkend="GtkBin">GtkBin</link>
                                 +----<link linkend="GtkButton">GtkButton</link>
                                       +----<link linkend="GtkToggleButton">GtkToggleButton</link>
                                             +----GtkCheckButton
                                                   +----<link linkend="GtkRadioButton">GtkRadioButton</link>
</synopsis>
</refsect1>



<refsect1 id="GtkCheckButton.implemented-interfaces" role="impl_interfaces">
<title role="impl_interfaces.title">Implemented Interfaces</title>
<para>
GtkCheckButton implements
 <link linkend="GtkActivatable">GtkActivatable</link>,  <link linkend="AtkImplementorIface">AtkImplementorIface</link> and  <link linkend="GtkBuildable">GtkBuildable</link>.</para>
</refsect1>


<refsect1 id="GtkCheckButton.style-properties" role="style_properties">
<title role="style_properties.title">Style Properties</title>
<synopsis>
  &quot;<link linkend="GtkCheckButton--s-indicator-size">indicator-size</link>&quot;           <link linkend="gint">gint</link>                  : Read
  &quot;<link linkend="GtkCheckButton--s-indicator-spacing">indicator-spacing</link>&quot;        <link linkend="gint">gint</link>                  : Read
</synopsis>
</refsect1>



<refsect1 id="GtkCheckButton.description" role="desc">
<title role="desc.title">Description</title>
<para>
A <link linkend="GtkCheckButton"><type>GtkCheckButton</type></link> places a discrete <link linkend="GtkToggleButton"><type>GtkToggleButton</type></link> next to a widget, (usually a <link linkend="GtkLabel"><type>GtkLabel</type></link>). See the section on <link linkend="GtkToggleButton"><type>GtkToggleButton</type></link> widgets for more information about toggle/check buttons.
</para>
<para>
The important signal ('toggled') is also inherited from <link linkend="GtkToggleButton"><type>GtkToggleButton</type></link>.
</para>
</refsect1>

<refsect1 id="GtkCheckButton.details" role="details">
<title role="details.title">Details</title>
<refsect2 id="GtkCheckButton-struct" role="struct">
<title>GtkCheckButton</title>
<indexterm zone="GtkCheckButton-struct"><primary sortas="CheckButton">GtkCheckButton</primary></indexterm><programlisting>typedef struct _GtkCheckButton GtkCheckButton;</programlisting>
<para>
<structfield>toggle_button</structfield> is a <link linkend="GtkToggleButton"><type>GtkToggleButton</type></link> representing the actual toggle button that composes the check button.
</para></refsect2>
<refsect2 id="gtk-check-button-new" role="function">
<title>gtk_check_button_new ()</title>
<indexterm zone="gtk-check-button-new"><primary sortas="check_button_new">gtk_check_button_new</primary></indexterm><programlisting><link linkend="GtkWidget">GtkWidget</link>*          gtk_check_button_new                (void);</programlisting>
<para>
Creates a new <link linkend="GtkCheckButton"><type>GtkCheckButton</type></link>.
</para><variablelist role="params">
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara>a <link linkend="GtkWidget"><type>GtkWidget</type></link>.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="gtk-check-button-new-with-label" role="function">
<title>gtk_check_button_new_with_label ()</title>
<indexterm zone="gtk-check-button-new-with-label"><primary sortas="check_button_new_with_label">gtk_check_button_new_with_label</primary></indexterm><programlisting><link linkend="GtkWidget">GtkWidget</link>*          gtk_check_button_new_with_label     (const <link linkend="gchar">gchar</link> *label);</programlisting>
<para>
Creates a new <link linkend="GtkCheckButton"><type>GtkCheckButton</type></link> with a <link linkend="GtkLabel"><type>GtkLabel</type></link> to the right of it.
</para><variablelist role="params">
<varlistentry><term><parameter>label</parameter>&#160;:</term>
<listitem><simpara>the text for the check button.
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara>a <link linkend="GtkWidget"><type>GtkWidget</type></link>.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="gtk-check-button-new-with-mnemonic" role="function">
<title>gtk_check_button_new_with_mnemonic ()</title>
<indexterm zone="gtk-check-button-new-with-mnemonic"><primary sortas="check_button_new_with_mnemonic">gtk_check_button_new_with_mnemonic</primary></indexterm><programlisting><link linkend="GtkWidget">GtkWidget</link>*          gtk_check_button_new_with_mnemonic  (const <link linkend="gchar">gchar</link> *label);</programlisting>
<para>
Creates a new <link linkend="GtkCheckButton"><type>GtkCheckButton</type></link> containing a label. The label
will be created using <link linkend="gtk-label-new-with-mnemonic"><function>gtk_label_new_with_mnemonic()</function></link>, so underscores
in <parameter>label</parameter> indicate the mnemonic for the check button.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>label</parameter>&#160;:</term>
<listitem><simpara> The text of the button, with an underscore in front of the
        mnemonic character
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> a new <link linkend="GtkCheckButton"><type>GtkCheckButton</type></link>
</simpara></listitem></varlistentry>
</variablelist></refsect2>

</refsect1>
<refsect1 id="GtkCheckButton.style-property-details" role="style_properties_details">
<title role="style_properties_details.title">Style Property Details</title>
<refsect2 id="GtkCheckButton--s-indicator-size" role="property"><title>The <literal>&quot;indicator-size&quot;</literal> style property</title>
<indexterm zone="GtkCheckButton--s-indicator-size"><primary sortas="CheckButton:indicator-size">GtkCheckButton:indicator-size</primary></indexterm><programlisting>  &quot;indicator-size&quot;           <link linkend="gint">gint</link>                  : Read</programlisting>
<para>Size of check or radio indicator.</para><para>Allowed values: &gt;= 0</para>
<para>Default value: 13</para>
</refsect2>
<refsect2 id="GtkCheckButton--s-indicator-spacing" role="property"><title>The <literal>&quot;indicator-spacing&quot;</literal> style property</title>
<indexterm zone="GtkCheckButton--s-indicator-spacing"><primary sortas="CheckButton:indicator-spacing">GtkCheckButton:indicator-spacing</primary></indexterm><programlisting>  &quot;indicator-spacing&quot;        <link linkend="gint">gint</link>                  : Read</programlisting>
<para>Spacing around check or radio indicator.</para><para>Allowed values: &gt;= 0</para>
<para>Default value: 2</para>
</refsect2>
</refsect1>



<refsect1 id="GtkCheckButton.see-also">
<title>See Also</title>
<para>
<variablelist>
<varlistentry>
<term><link linkend="GtkCheckMenuItem"><type>GtkCheckMenuItem</type></link></term>
<listitem><para>add check buttons to your menus.</para></listitem>
</varlistentry>
<varlistentry>
<term><link linkend="GtkButton"><type>GtkButton</type></link></term>
<listitem><para>a more general button.</para></listitem>
</varlistentry>
<varlistentry>
<term><link linkend="GtkToggleButton"><type>GtkToggleButton</type></link></term>
<listitem><para><link linkend="GtkCheckButton"><type>GtkCheckButton</type></link>'s parent.</para></listitem>
</varlistentry>
<varlistentry>
<term><link linkend="GtkRadioButton"><type>GtkRadioButton</type></link></term>
<listitem><para>group check buttons together.</para></listitem>
</varlistentry>
</variablelist>
</para>
</refsect1>

</refentry>
