<refentry id="GtkBin">
<refmeta>
<refentrytitle>GtkBin</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>GTK Library</refmiscinfo>
</refmeta>

<refnamediv>
<refname>GtkBin</refname><refpurpose>a container with just one child.</refpurpose>
</refnamediv>

<refsynopsisdiv><title>Synopsis</title>
<synopsis>

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


struct      <link linkend="GtkBin-struct">GtkBin</link>;
<link linkend="GtkWidget">GtkWidget</link>*  <link linkend="gtk-bin-get-child">gtk_bin_get_child</link>               (<link linkend="GtkBin">GtkBin</link> *bin);


</synopsis>
</refsynopsisdiv>

<refsect1>
<title>Object Hierarchy</title>
<synopsis>

  <link linkend="GObject">GObject</link>
   +----<link linkend="GtkObject">GtkObject</link>
         +----<link linkend="GtkWidget">GtkWidget</link>
               +----<link linkend="GtkContainer">GtkContainer</link>
                     +----GtkBin
</synopsis>

</refsect1>




<refsect1>
<title>Description</title>
<para>
The <link linkend="GtkBin">GtkBin</link> widget is a container with just one child.
It is not very useful itself, but it is useful for deriving subclasses,
since it provides common code needed for handling a single child widget.
</para>
<para>
Many GTK+ widgets are subclasses of <link linkend="GtkBin">GtkBin</link>, including <link linkend="GtkWindow">GtkWindow</link>, <link linkend="GtkButton">GtkButton</link>,
<link linkend="GtkFrame">GtkFrame</link>, <link linkend="GtkHandleBox">GtkHandleBox</link>, and <link linkend="GtkScrolledWindow">GtkScrolledWindow</link>.
</para>
</refsect1>

<refsect1>
<title>Details</title>
<refsect2>
<title><anchor id="GtkBin-struct">struct GtkBin</title>
<programlisting>struct GtkBin;</programlisting>
<para>
The <link linkend="GtkBin-struct">GtkBin</link> struct contains the following fields.
(These fields should be considered read-only. They should never be set by
an application.)

<informaltable pgwide=1 frame="none" role="struct">
<tgroup cols="2"><colspec colwidth="2*"><colspec colwidth="8*">
<tbody>

<row>
<entry><link linkend="GtkWidget">GtkWidget</link> *child;</entry>
<entry>the child widget.</entry>
</row>

</tbody></tgroup></informaltable>

</para></refsect2>
<refsect2>
<title><anchor id="gtk-bin-get-child">gtk_bin_get_child ()</title>
<programlisting><link linkend="GtkWidget">GtkWidget</link>*  gtk_bin_get_child               (<link linkend="GtkBin">GtkBin</link> *bin);</programlisting>
<para>
Gets the child of the <link linkend="GtkBin">GtkBin</link>, or <literal>NULL</literal> if the bin contains
no child widget. The returned widget does not have a reference
added, so you do not need to unref it.</para>
<para>

</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><parameter>bin</parameter>&nbsp;:</entry>
<entry> a <link linkend="GtkBin">GtkBin</link>
</entry></row>
<row><entry align="right"><emphasis>Returns</emphasis> :</entry><entry> pointer to child of the <link linkend="GtkBin">GtkBin</link>
</entry></row>
</tbody></tgroup></informaltable></refsect2>

</refsect1>




</refentry>
