<?xml version="1.0" standalone="no"?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
    "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">

<refentry id="class-gtkcellrendererprogress">
  <refnamediv>
    <refname>gtk.CellRendererProgress</refname>
    <refpurpose>an object that renders numbers as progress bars in a <link
    linkend="class-gtktreeview"><classname>gtk.TreeView</classname></link>
    (new in PyGTK 2.6)</refpurpose>
  </refnamediv>

  <refsect1>
    <title>Synopsis</title>

    <classsynopsis language="python">
      <ooclass><classname>gtk.CellRendererProgress</classname></ooclass>
      <ooclass><classname><link
linkend="class-gtkcellrenderer">gtk.CellRenderer</link></classname></ooclass>
      <constructorsynopsis language="python">
	<methodname><link
linkend="constructor-gtkcellrendererprogress">gtk.CellRendererProgress</link></methodname>
	<methodparam></methodparam>
      </constructorsynopsis>
    </classsynopsis>

  </refsect1>

  <refsect1>
    <title>Ancestry</title>

<synopsis>+-- <link linkend="class-gobject">gobject.GObject</link>
  +-- <link linkend="class-gtkobject">gtk.Object</link>
    +-- <link linkend="class-gtkcellrenderer">gtk.CellRenderer</link>
      +-- <link linkend="class-gtkcellrendererprogress">gtk.CellRendererProgress</link>
</synopsis>

  </refsect1>

  <refsect1 id="properties-gtkcellrendererprogress">
    <title>gtk.CellRendererProgress Properties</title>

    <para><link linkend="properties-gtkobject">gtk.Object Properties</link></para>
    <para><link linkend="properties-gtkcellrenderer">gtk.CellRenderer Properties</link></para>

    <blockquote role="properties">
        <informaltable pgwide="1" frame="none">
            <tgroup cols="3">
                <colspec column="1" colwidth="1in"/>
                <colspec column="2" colwidth="1in"/>
                <colspec column="3" colwidth="3.5in"/>
                <tbody>
                    <row valign="top">
                        <entry>"orientation"</entry>
                        <entry>Read/Write</entry>
                        <entry>The "orientation" property controls the direction and growth direction
                        of the progress bar (left-to-right, right-to-left, top-to-bottom or bottom-to-top).
                        Default value: gtk.PROGRESS_LEFT_TO_RIGHT. Available in GTK+ 2.12 and above.</entry>
                    </row>
                    <row valign="top">
                        <entry>"pulse"</entry>
                        <entry>Read/Write</entry>
                        <entry>Setting this to a non-negative value causes the cell renderer to enter
                        "activity mode", where a block bounces back and forth to indicate that some progress
                        is made, without specifying exactly how much. Each increment of the property causes
                        the block to move by a little bit. To indicate that the activity has not started yet,
                        set the property to zero. To indicate completion, set the property to G_MAXINT.
                        Allowed values: >= -1. Default value: -1. Available in GTK+ 2.12 and above.</entry>
                    </row>
                    <row valign="top">
                        <entry>"text"</entry>
                        <entry>Read/Write</entry>
                        <entry>The text in the label that will be drawn over the progress bar.
                        Setting this property to <literal>None</literal> causes the default label to
                        be displayed. Setting this property to an empty string causes no label to be
                        displayed. Default value: <literal>None</literal>. Available in GTK+ 2.6 and
                        above.</entry>
                    </row>
                    <row valign="top">
                        <entry>"text-xalign"</entry>
                        <entry>Read/Write</entry>
                        <entry>The "text-xalign" property controls the horizontal alignment of the text
                        in the progress bar. Valid values range from 0 (left) to 1 (right). Reserved for
                        RTL layouts. Allowed values: [0,1]. Default value: 0.5. Available in GTK+ 2.12 and above.</entry>
                    </row>
                    <row valign="top">
                        <entry>"text-yalign"</entry>
                        <entry>Read/Write</entry>
                        <entry>The "text-yalign" property controls the vertical alignment of the text in
                        the progress bar. Valid values range from 0 (top) to 1 (bottom).
                        Allowed values: [0,1]. Default value: 0.5. Available in GTK+ 2.12 and above.</entry>
                    </row>
                    <row valign="top">
                        <entry>"value"</entry>
                        <entry>Read/Write</entry>
                        <entry>The percentage that the progress bar is "filled in".
                        Available in GTK+ 2.6 and above.</entry>
                    </row>
                </tbody>
            </tgroup>
        </informaltable>
    </blockquote>

  </refsect1>

  <refsect1 id="signal-prototypes-gtkcellrendererprogress">
    <title>gtk.CellRendererProgress Signal Prototypes</title>

    <para><link linkend="signal-prototypes-gobject">gobject.GObject Signal Prototypes</link></para>
    <para><link linkend="signal-prototypes-gtkobject">gtk.Object Signal Prototypes</link></para>
    <para><link linkend="signal-prototypes-gtkcellrenderer">gtk.CellRenderer Signal Prototypes</link></para>
</refsect1>

  <refsect1>
    <title>Description</title>

    <note>
      <para>This object is available in PyGTK 2.6 and above.</para>
    </note>

    <para>The <link
linkend="class-gtkcellrendererprogress"><classname>gtk.CellRendererProgress</classname></link>
manages the rendering of a number as a progress bar in a <link
linkend="class-gtktreeview"><classname>gtk.TreeView</classname></link>
cell.</para>

  </refsect1>

  <refsect1 id="constructor-gtkcellrendererprogress">
    <title>Constructor</title>

    <programlisting><constructorsynopsis language="python">
	<methodname>gtk.CellRendererProgress</methodname>
	<methodparam></methodparam>  </constructorsynopsis></programlisting>
    <variablelist>
      <varlistentry>
	<term><emphasis>Returns</emphasis>&nbsp;:</term>
	<listitem><simpara>the new cell renderer</simpara></listitem>
      </varlistentry>
    </variablelist>

    <note>
      <para>This constructor is available in PyGTK 2.6 and above.</para>
    </note>

    <para>Creates a new <link
linkend="class-gtkcellrendererprogress"><classname>gtk.CellRendererProgress</classname></link>. 
Rendering parameters are adjusted using the object properties. The object
properties can be set globally (with <link
linkend="method-gobject--set-property"><methodname>set_property</methodname>()</link>). 
Also, with <link
linkend="class-gtktreeviewcolumn"><classname>gtk.TreeViewColumn</classname></link>, 
you can bind a property to a value in a <link
linkend="class-gtktreemodel"><classname>gtk.TreeModel</classname></link>.
For example, you can bind the "text" property on the cell renderer to a
string value in the model, thus rendering a different string in each row of
the <link
linkend="class-gtktreeview"><classname>gtk.TreeView</classname></link>.</para>

  </refsect1>

</refentry>
