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

<refnamediv>
<refname>GtkListItem</refname><refpurpose>an item in a <link linkend="GtkList">GtkList</link>.</refpurpose>
</refnamediv>

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

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


struct      <link linkend="GtkListItem-struct">GtkListItem</link>;
<link linkend="GtkWidget">GtkWidget</link>*  <link linkend="gtk-list-item-new">gtk_list_item_new</link>               (void);
<link linkend="GtkWidget">GtkWidget</link>*  <link linkend="gtk-list-item-new-with-label">gtk_list_item_new_with_label</link>    (const <link linkend="gchar">gchar</link> *label);
void        <link linkend="gtk-list-item-select">gtk_list_item_select</link>            (<link linkend="GtkListItem">GtkListItem</link> *list_item);
void        <link linkend="gtk-list-item-deselect">gtk_list_item_deselect</link>          (<link linkend="GtkListItem">GtkListItem</link> *list_item);


</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>
                     +----<link linkend="GtkBin">GtkBin</link>
                           +----<link linkend="GtkItem">GtkItem</link>
                                 +----GtkListItem
</synopsis>

</refsect1>


<refsect1>
<title>Signal Prototypes</title>
<synopsis>

&quot;<link linkend="GtkListItem-end-selection">end-selection</link>&quot;
            void        user_function      (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="gpointer">gpointer</link> user_data);
&quot;<link linkend="GtkListItem-extend-selection">extend-selection</link>&quot;
            void        user_function      (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="GtkScrollType">GtkScrollType</link> scroll_type,
                                            <link linkend="gfloat">gfloat</link> position,
                                            <link linkend="gboolean">gboolean</link> auto_start_selection,
                                            <link linkend="gpointer">gpointer</link> user_data);
&quot;<link linkend="GtkListItem-scroll-horizontal">scroll-horizontal</link>&quot;
            void        user_function      (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="GtkScrollType">GtkScrollType</link> scroll_type,
                                            <link linkend="gfloat">gfloat</link> position,
                                            <link linkend="gpointer">gpointer</link> user_data);
&quot;<link linkend="GtkListItem-scroll-vertical">scroll-vertical</link>&quot;
            void        user_function      (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="GtkScrollType">GtkScrollType</link> scroll_type,
                                            <link linkend="gfloat">gfloat</link> position,
                                            <link linkend="gpointer">gpointer</link> user_data);
&quot;<link linkend="GtkListItem-select-all">select-all</link>&quot;
            void        user_function      (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="gpointer">gpointer</link> user_data);
&quot;<link linkend="GtkListItem-start-selection">start-selection</link>&quot;
            void        user_function      (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="gpointer">gpointer</link> user_data);
&quot;<link linkend="GtkListItem-toggle-add-mode">toggle-add-mode</link>&quot;
            void        user_function      (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="gpointer">gpointer</link> user_data);
&quot;<link linkend="GtkListItem-toggle-focus-row">toggle-focus-row</link>&quot;
            void        user_function      (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="gpointer">gpointer</link> user_data);
&quot;<link linkend="GtkListItem-undo-selection">undo-selection</link>&quot;
            void        user_function      (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="gpointer">gpointer</link> user_data);
&quot;<link linkend="GtkListItem-unselect-all">unselect-all</link>&quot;
            void        user_function      (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="gpointer">gpointer</link> user_data);
</synopsis>
</refsect1>


<refsect1>
<title>Description</title>
<para>
The <link linkend="GtkListItem">GtkListItem</link> widget is used for each item in a <link linkend="GtkList">GtkList</link>.

</para>
</refsect1>

<refsect1>
<title>Details</title>
<refsect2>
<title><anchor id="GtkListItem-struct">struct GtkListItem</title>
<programlisting>struct GtkListItem;</programlisting>
<warning>
<para>
<literal>GtkListItem</literal> is deprecated and should not be used in newly-written code.
</para>
</warning>
<para>
The <link linkend="GtkListItem">GtkListItem</link> struct contains private data only, and should
only be accessed using the functions below.
</para></refsect2>
<refsect2>
<title><anchor id="gtk-list-item-new">gtk_list_item_new ()</title>
<programlisting><link linkend="GtkWidget">GtkWidget</link>*  gtk_list_item_new               (void);</programlisting>
<warning>
<para>
<literal>gtk_list_item_new</literal> is deprecated and should not be used in newly-written code.
</para>
</warning>
<para>
Creates a new <link linkend="GtkListitem">GtkListitem</link>.
</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><emphasis>Returns</emphasis> :</entry><entry>a new <link linkend="GtkListItem">GtkListItem</link>.


</entry></row>
</tbody></tgroup></informaltable></refsect2>
<refsect2>
<title><anchor id="gtk-list-item-new-with-label">gtk_list_item_new_with_label ()</title>
<programlisting><link linkend="GtkWidget">GtkWidget</link>*  gtk_list_item_new_with_label    (const <link linkend="gchar">gchar</link> *label);</programlisting>
<warning>
<para>
<literal>gtk_list_item_new_with_label</literal> is deprecated and should not be used in newly-written code.
</para>
</warning>
<para>
Creates a new <link linkend="GtkListItem">GtkListItem</link> with a child label containing the given string.
</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><parameter>label</parameter>&nbsp;:</entry>
<entry>the string to use for the child label.
</entry></row>
<row><entry align="right"><emphasis>Returns</emphasis> :</entry><entry>a new <link linkend="GtkListItem">GtkListItem</link> with a child <link linkend="GtkLabel">GtkLabel</link> with the text set to
<parameter>label</parameter>.


</entry></row>
</tbody></tgroup></informaltable></refsect2>
<refsect2>
<title><anchor id="gtk-list-item-select">gtk_list_item_select ()</title>
<programlisting>void        gtk_list_item_select            (<link linkend="GtkListItem">GtkListItem</link> *list_item);</programlisting>
<warning>
<para>
<literal>gtk_list_item_select</literal> is deprecated and should not be used in newly-written code.
</para>
</warning>
<para>
Selects the item, by emitting the item's "select" signal.
Depending on the selection mode of the list, this may cause other items to
be deselected.
</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><parameter>list_item</parameter>&nbsp;:</entry>
<entry>a <link linkend="GtkListItem">GtkListItem</link>.


</entry></row>
</tbody></tgroup></informaltable></refsect2>
<refsect2>
<title><anchor id="gtk-list-item-deselect">gtk_list_item_deselect ()</title>
<programlisting>void        gtk_list_item_deselect          (<link linkend="GtkListItem">GtkListItem</link> *list_item);</programlisting>
<warning>
<para>
<literal>gtk_list_item_deselect</literal> is deprecated and should not be used in newly-written code.
</para>
</warning>
<para>
Deselects the item, by emitting the item's "deselect" signal.
</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><parameter>list_item</parameter>&nbsp;:</entry>
<entry>a <link linkend="GtkListItem">GtkListItem</link>.


</entry></row>
</tbody></tgroup></informaltable></refsect2>

</refsect1>

<refsect1>
<title>Signals</title>
<refsect2><title><anchor id="GtkListItem-end-selection">The &quot;end-selection&quot; signal</title>
<programlisting>void        user_function                  (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>

</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><parameter>listitem</parameter>&nbsp;:</entry>
<entry>the object which received the signal.

</entry></row>
<row><entry align="right"><parameter>user_data</parameter>&nbsp;:</entry>
<entry>user data set when the signal handler was connected.</entry></row>
</tbody></tgroup></informaltable></refsect2><refsect2><title><anchor id="GtkListItem-extend-selection">The &quot;extend-selection&quot; signal</title>
<programlisting>void        user_function                  (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="GtkScrollType">GtkScrollType</link> scroll_type,
                                            <link linkend="gfloat">gfloat</link> position,
                                            <link linkend="gboolean">gboolean</link> auto_start_selection,
                                            <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>

</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><parameter>listitem</parameter>&nbsp;:</entry>
<entry>the object which received the signal.
</entry></row>
<row><entry align="right"><parameter>scroll_type</parameter>&nbsp;:</entry>
<entry>
</entry></row>
<row><entry align="right"><parameter>position</parameter>&nbsp;:</entry>
<entry>
</entry></row>
<row><entry align="right"><parameter>auto_start_selection</parameter>&nbsp;:</entry>
<entry>

</entry></row>
<row><entry align="right"><parameter>user_data</parameter>&nbsp;:</entry>
<entry>user data set when the signal handler was connected.</entry></row>
</tbody></tgroup></informaltable></refsect2><refsect2><title><anchor id="GtkListItem-scroll-horizontal">The &quot;scroll-horizontal&quot; signal</title>
<programlisting>void        user_function                  (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="GtkScrollType">GtkScrollType</link> scroll_type,
                                            <link linkend="gfloat">gfloat</link> position,
                                            <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>

</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><parameter>listitem</parameter>&nbsp;:</entry>
<entry>the object which received the signal.
</entry></row>
<row><entry align="right"><parameter>scroll_type</parameter>&nbsp;:</entry>
<entry>
</entry></row>
<row><entry align="right"><parameter>position</parameter>&nbsp;:</entry>
<entry>

</entry></row>
<row><entry align="right"><parameter>user_data</parameter>&nbsp;:</entry>
<entry>user data set when the signal handler was connected.</entry></row>
</tbody></tgroup></informaltable></refsect2><refsect2><title><anchor id="GtkListItem-scroll-vertical">The &quot;scroll-vertical&quot; signal</title>
<programlisting>void        user_function                  (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="GtkScrollType">GtkScrollType</link> scroll_type,
                                            <link linkend="gfloat">gfloat</link> position,
                                            <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>

</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><parameter>listitem</parameter>&nbsp;:</entry>
<entry>the object which received the signal.
</entry></row>
<row><entry align="right"><parameter>scroll_type</parameter>&nbsp;:</entry>
<entry>
</entry></row>
<row><entry align="right"><parameter>position</parameter>&nbsp;:</entry>
<entry>

</entry></row>
<row><entry align="right"><parameter>user_data</parameter>&nbsp;:</entry>
<entry>user data set when the signal handler was connected.</entry></row>
</tbody></tgroup></informaltable></refsect2><refsect2><title><anchor id="GtkListItem-select-all">The &quot;select-all&quot; signal</title>
<programlisting>void        user_function                  (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>

</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><parameter>listitem</parameter>&nbsp;:</entry>
<entry>the object which received the signal.

</entry></row>
<row><entry align="right"><parameter>user_data</parameter>&nbsp;:</entry>
<entry>user data set when the signal handler was connected.</entry></row>
</tbody></tgroup></informaltable></refsect2><refsect2><title><anchor id="GtkListItem-start-selection">The &quot;start-selection&quot; signal</title>
<programlisting>void        user_function                  (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>

</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><parameter>listitem</parameter>&nbsp;:</entry>
<entry>the object which received the signal.

</entry></row>
<row><entry align="right"><parameter>user_data</parameter>&nbsp;:</entry>
<entry>user data set when the signal handler was connected.</entry></row>
</tbody></tgroup></informaltable></refsect2><refsect2><title><anchor id="GtkListItem-toggle-add-mode">The &quot;toggle-add-mode&quot; signal</title>
<programlisting>void        user_function                  (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>

</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><parameter>listitem</parameter>&nbsp;:</entry>
<entry>the object which received the signal.

</entry></row>
<row><entry align="right"><parameter>user_data</parameter>&nbsp;:</entry>
<entry>user data set when the signal handler was connected.</entry></row>
</tbody></tgroup></informaltable></refsect2><refsect2><title><anchor id="GtkListItem-toggle-focus-row">The &quot;toggle-focus-row&quot; signal</title>
<programlisting>void        user_function                  (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>

</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><parameter>listitem</parameter>&nbsp;:</entry>
<entry>the object which received the signal.

</entry></row>
<row><entry align="right"><parameter>user_data</parameter>&nbsp;:</entry>
<entry>user data set when the signal handler was connected.</entry></row>
</tbody></tgroup></informaltable></refsect2><refsect2><title><anchor id="GtkListItem-undo-selection">The &quot;undo-selection&quot; signal</title>
<programlisting>void        user_function                  (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>

</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><parameter>listitem</parameter>&nbsp;:</entry>
<entry>the object which received the signal.

</entry></row>
<row><entry align="right"><parameter>user_data</parameter>&nbsp;:</entry>
<entry>user data set when the signal handler was connected.</entry></row>
</tbody></tgroup></informaltable></refsect2><refsect2><title><anchor id="GtkListItem-unselect-all">The &quot;unselect-all&quot; signal</title>
<programlisting>void        user_function                  (<link linkend="GtkListItem">GtkListItem</link> *listitem,
                                            <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>

</para><informaltable pgwide="1" frame="none" role="params">
<tgroup cols="2">
<colspec colwidth="2*">
<colspec colwidth="8*">
<tbody>
<row><entry align="right"><parameter>listitem</parameter>&nbsp;:</entry>
<entry>the object which received the signal.

</entry></row>
<row><entry align="right"><parameter>user_data</parameter>&nbsp;:</entry>
<entry>user data set when the signal handler was connected.</entry></row>
</tbody></tgroup></informaltable></refsect2>
</refsect1>


<refsect1>
<title>See Also</title>
<para>
<variablelist>

<varlistentry>
<term><link linkend="GtkList">GtkList</link></term>
<listitem><para>the parent list widget.</para></listitem>
</varlistentry>

</variablelist>

</para>
</refsect1>

</refentry>
