<?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="GtkRadioToolButton">
<refmeta>
<refentrytitle role="top_of_page" id="GtkRadioToolButton.top_of_page">GtkRadioToolButton</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>GTK Library</refmiscinfo>
</refmeta>

<refnamediv>
<refname>GtkRadioToolButton</refname>
<refpurpose>A toolbar item that contains a radio button</refpurpose>
</refnamediv>

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

<synopsis>

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

                    <link linkend="GtkRadioToolButton-struct">GtkRadioToolButton</link>;
<link linkend="GtkToolItem">GtkToolItem</link> *       <link linkend="gtk-radio-tool-button-new">gtk_radio_tool_button_new</link>           (<link linkend="GSList">GSList</link> *group);
<link linkend="GtkToolItem">GtkToolItem</link> *       <link linkend="gtk-radio-tool-button-new-from-stock">gtk_radio_tool_button_new_from_stock</link>
                                                        (<link linkend="GSList">GSList</link> *group,
                                                         const <link linkend="gchar">gchar</link> *stock_id);
<link linkend="GtkToolItem">GtkToolItem</link> *       <link linkend="gtk-radio-tool-button-new-from-widget">gtk_radio_tool_button_new_from_widget</link>
                                                        (<link linkend="GtkRadioToolButton">GtkRadioToolButton</link> *group);
<link linkend="GtkToolItem">GtkToolItem</link> *       <link linkend="gtk-radio-tool-button-new-with-stock-from-widget">gtk_radio_tool_button_new_with_stock_from_widget</link>
                                                        (<link linkend="GtkRadioToolButton">GtkRadioToolButton</link> *group,
                                                         const <link linkend="gchar">gchar</link> *stock_id);
<link linkend="GSList">GSList</link> *            <link linkend="gtk-radio-tool-button-get-group">gtk_radio_tool_button_get_group</link>     (<link linkend="GtkRadioToolButton">GtkRadioToolButton</link> *button);
<link linkend="void">void</link>                <link linkend="gtk-radio-tool-button-set-group">gtk_radio_tool_button_set_group</link>     (<link linkend="GtkRadioToolButton">GtkRadioToolButton</link> *button,
                                                         <link linkend="GSList">GSList</link> *group);
</synopsis>
</refsynopsisdiv>

<refsect1 id="GtkRadioToolButton.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="GtkToolItem">GtkToolItem</link>
                                       +----<link linkend="GtkToolButton">GtkToolButton</link>
                                             +----<link linkend="GtkToggleToolButton">GtkToggleToolButton</link>
                                                   +----GtkRadioToolButton
</synopsis>
</refsect1>



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


<refsect1 id="GtkRadioToolButton.properties" role="properties">
<title role="properties.title">Properties</title>
<synopsis>
  &quot;<link linkend="GtkRadioToolButton--group">group</link>&quot;                    <link linkend="GtkRadioToolButton">GtkRadioToolButton</link>*   : Write
</synopsis>
</refsect1>



<refsect1 id="GtkRadioToolButton.description" role="desc">
<title role="desc.title">Description</title>
<para>
A <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link> is a <link linkend="GtkToolItem"><type>GtkToolItem</type></link> that contains a radio button,
that is, a button that is part of a group of toggle buttons where only
one button can be active at a time.
</para>
<para>
Use <link linkend="gtk-radio-tool-button-new"><function>gtk_radio_tool_button_new()</function></link> to create a new
<link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link>. use <link linkend="gtk-radio-tool-button-new-from-widget"><function>gtk_radio_tool_button_new_from_widget()</function></link> to
create a new <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link> that is part of the same group as an
existing <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link>. Use
<link linkend="gtk-radio-tool-button-new-from-stock"><function>gtk_radio_tool_button_new_from_stock()</function></link> or
<link linkend="gtk-radio-tool-button-new-from-widget-with-stock"><function>gtk_radio_tool_button_new_from_widget_with_stock()</function></link> to create a new
<link linkend="GtkRAdioToolButton"><type>GtkRAdioToolButton</type></link> containing a stock item.
</para>
</refsect1>

<refsect1 id="GtkRadioToolButton.details" role="details">
<title role="details.title">Details</title>
<refsect2 id="GtkRadioToolButton-struct" role="struct">
<title>GtkRadioToolButton</title>
<indexterm zone="GtkRadioToolButton-struct"><primary sortas="RadioToolButton">GtkRadioToolButton</primary></indexterm><programlisting>typedef struct _GtkRadioToolButton GtkRadioToolButton;</programlisting>
<para>
  The <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link> contains only private data and should only
  be accessed through the functions described below.
</para></refsect2>
<refsect2 id="gtk-radio-tool-button-new" role="function" condition="since:2.4">
<title>gtk_radio_tool_button_new ()</title>
<indexterm zone="gtk-radio-tool-button-new" role="2.4"><primary sortas="radio_tool_button_new">gtk_radio_tool_button_new</primary></indexterm><programlisting><link linkend="GtkToolItem">GtkToolItem</link> *       gtk_radio_tool_button_new           (<link linkend="GSList">GSList</link> *group);</programlisting>
<para>
Creates a new <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link>, adding it to <parameter>group</parameter>.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>group</parameter>&#160;:</term>
<listitem><simpara> An existing radio button group, or <link linkend="NULL--CAPS"><literal>NULL</literal></link> if you are creating a new group
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> The new <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link>

</simpara></listitem></varlistentry>
</variablelist><para role="since">Since 2.4</para></refsect2>
<refsect2 id="gtk-radio-tool-button-new-from-stock" role="function" condition="since:2.4">
<title>gtk_radio_tool_button_new_from_stock ()</title>
<indexterm zone="gtk-radio-tool-button-new-from-stock" role="2.4"><primary sortas="radio_tool_button_new_from_stock">gtk_radio_tool_button_new_from_stock</primary></indexterm><programlisting><link linkend="GtkToolItem">GtkToolItem</link> *       gtk_radio_tool_button_new_from_stock
                                                        (<link linkend="GSList">GSList</link> *group,
                                                         const <link linkend="gchar">gchar</link> *stock_id);</programlisting>
<para>
Creates a new <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link>, adding it to <parameter>group</parameter>. 
The new <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link> will contain an icon and label from the
stock item indicated by <parameter>stock_id</parameter>.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>group</parameter>&#160;:</term>
<listitem><simpara> an existing radio button group, or <link linkend="NULL--CAPS"><literal>NULL</literal></link> if you are creating a new group
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>stock_id</parameter>&#160;:</term>
<listitem><simpara> the name of a stock item
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> The new <link linkend="GtkRadioToolItem"><type>GtkRadioToolItem</type></link>

</simpara></listitem></varlistentry>
</variablelist><para role="since">Since 2.4</para></refsect2>
<refsect2 id="gtk-radio-tool-button-new-from-widget" role="function" condition="since:2.4">
<title>gtk_radio_tool_button_new_from_widget ()</title>
<indexterm zone="gtk-radio-tool-button-new-from-widget" role="2.4"><primary sortas="radio_tool_button_new_from_widget">gtk_radio_tool_button_new_from_widget</primary></indexterm><programlisting><link linkend="GtkToolItem">GtkToolItem</link> *       gtk_radio_tool_button_new_from_widget
                                                        (<link linkend="GtkRadioToolButton">GtkRadioToolButton</link> *group);</programlisting>
<para>
Creates a new <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link> adding it to the same group as <parameter>gruup</parameter></para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>group</parameter>&#160;:</term>
<listitem><simpara> An existing <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link>
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> The new <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link>

</simpara></listitem></varlistentry>
</variablelist><para role="since">Since 2.4</para></refsect2>
<refsect2 id="gtk-radio-tool-button-new-with-stock-from-widget" role="function" condition="since:2.4">
<title>gtk_radio_tool_button_new_with_stock_from_widget ()</title>
<indexterm zone="gtk-radio-tool-button-new-with-stock-from-widget" role="2.4"><primary sortas="radio_tool_button_new_with_stock_from_widget">gtk_radio_tool_button_new_with_stock_from_widget</primary></indexterm><programlisting><link linkend="GtkToolItem">GtkToolItem</link> *       gtk_radio_tool_button_new_with_stock_from_widget
                                                        (<link linkend="GtkRadioToolButton">GtkRadioToolButton</link> *group,
                                                         const <link linkend="gchar">gchar</link> *stock_id);</programlisting>
<para>
Creates a new <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link> adding it to the same group as <parameter>group</parameter>.
The new <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link> will contain an icon and label from the
stock item indicated by <parameter>stock_id</parameter>.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>group</parameter>&#160;:</term>
<listitem><simpara> An existing <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link>.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>stock_id</parameter>&#160;:</term>
<listitem><simpara> the name of a stock item 
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> A new <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link>

</simpara></listitem></varlistentry>
</variablelist><para role="since">Since 2.4</para></refsect2>
<refsect2 id="gtk-radio-tool-button-get-group" role="function" condition="since:2.4">
<title>gtk_radio_tool_button_get_group ()</title>
<indexterm zone="gtk-radio-tool-button-get-group" role="2.4"><primary sortas="radio_tool_button_get_group">gtk_radio_tool_button_get_group</primary></indexterm><programlisting><link linkend="GSList">GSList</link> *            gtk_radio_tool_button_get_group     (<link linkend="GtkRadioToolButton">GtkRadioToolButton</link> *button);</programlisting>
<para>
Returns the radio button group <parameter>button</parameter> belongs to.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>button</parameter>&#160;:</term>
<listitem><simpara> a <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link>
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> The group <parameter>button</parameter> belongs to.

</simpara></listitem></varlistentry>
</variablelist><para role="since">Since 2.4</para></refsect2>
<refsect2 id="gtk-radio-tool-button-set-group" role="function" condition="since:2.4">
<title>gtk_radio_tool_button_set_group ()</title>
<indexterm zone="gtk-radio-tool-button-set-group" role="2.4"><primary sortas="radio_tool_button_set_group">gtk_radio_tool_button_set_group</primary></indexterm><programlisting><link linkend="void">void</link>                gtk_radio_tool_button_set_group     (<link linkend="GtkRadioToolButton">GtkRadioToolButton</link> *button,
                                                         <link linkend="GSList">GSList</link> *group);</programlisting>
<para>
Adds <parameter>button</parameter> to <parameter>group</parameter>, removing it from the group it belonged to before.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>button</parameter>&#160;:</term>
<listitem><simpara> a <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>group</parameter>&#160;:</term>
<listitem><simpara> an existing radio button group
</simpara></listitem></varlistentry>
</variablelist><para role="since">Since 2.4</para></refsect2>

</refsect1>
<refsect1 id="GtkRadioToolButton.property-details" role="property_details">
<title role="property_details.title">Property Details</title>
<refsect2 id="GtkRadioToolButton--group" role="property"><title>The <literal>&quot;group&quot;</literal> property</title>
<indexterm zone="GtkRadioToolButton--group" role="2.4"><primary sortas="RadioToolButton:group">GtkRadioToolButton:group</primary></indexterm><programlisting>  &quot;group&quot;                    <link linkend="GtkRadioToolButton">GtkRadioToolButton</link>*   : Write</programlisting>
<para>
Sets a new group for a radio tool button.</para>
<para>
</para><para>Since 2.4</para>
</refsect2>
</refsect1>



<refsect1 id="GtkRadioToolButton.see-also">
<title>See Also</title>
<para>
<variablelist>
<varlistentry>
<term><link linkend="GtkToolbar"><type>GtkToolbar</type></link></term>
<listitem><para>The toolbar widget</para></listitem>
</varlistentry>
<varlistentry>
  <term><link linkend="GtkToolButton"><type>GtkToolButton</type></link></term>
  <listitem><para>
      An ancestor class of GtkRadioToolButton. The properties
      "label_widget", "label", "icon_widget", and "stock_id" on
      <link linkend="GtkToolButton"><type>GtkToolButton</type></link> determine the label and icon used on a
      <link linkend="GtkRadioToolButton"><type>GtkRadioToolButton</type></link>.
  </para></listitem>
</varlistentry>
<varlistentry>
  <term><link linkend="GtkSeparatorToolItem"><type>GtkSeparatorToolItem</type></link></term>
  <listitem>
    <para>A subclass of <link linkend="GtkToolItem"><type>GtkToolItem</type></link> that separates groups of
      items on a toolbar. It is usually a good idea to put a separator
      before and after a group of <link linkend="GtkRadioToolButtons"><type>GtkRadioToolButtons</type></link> on a <link linkend="GtkToolbar"><type>GtkToolbar</type></link>.
    </para>
  </listitem>
</varlistentry>
</variablelist>
</para>
</refsect1>

</refentry>
