Files
gimp/devel-docs/libgimp/html/libgimp-gimpprogress.html
2010-08-11 01:13:56 -04:00

101 lines
13 KiB
HTML
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>gimpprogress</title><meta name="generator" content="DocBook XSL Stylesheets V1.66.1"><link rel="start" href="index.html" title="GIMP Library Reference Manual"><link rel="up" href="libgimp-general.html" title="Functions not Related to Specific Images"><link rel="prev" href="libgimp-gimpproceduraldb.html" title="gimpproceduraldb"><link rel="next" href="libgimp-image.html" title="Manupulating Images and all their Properties"><meta name="generator" content="GTK-Doc V1.3 (XML mode)"><link rel="stylesheet" href="style.css" type="text/css"><link rel="part" href="gimpdefinitions.html" title="Part I. GIMP Constants"><link rel="part" href="libgimp.html" title="Part II. GIMP Library"><link rel="chapter" href="libgimp-general.html" title="Functions not Related to Specific Images"><link rel="chapter" href="libgimp-image.html" title="Manupulating Images and all their Properties"><link rel="chapter" href="libgimp-data.html" title="Data Objects"><link rel="chapter" href="libgimp-selectors.html" title="Controlling the Core's Selection Dialogs"><link rel="part" href="libgimpui.html" title="Part III. GIMP User Interface Library"><link rel="chapter" href="libgimpui-hierarchy.html" title="Object Hierarchy"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><table class="navigation" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2"><tr valign="middle"><td><a accesskey="p" href="libgimp-gimpproceduraldb.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td><td><a accesskey="u" href="libgimp-general.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td><td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td><th width="100%" align="center">GIMP Library Reference Manual</th><td><a accesskey="n" href="libgimp-image.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td></tr></table><div class="refentry" lang="en"><a name="libgimp-gimpprogress"></a><div class="titlepage"></div><div class="refnamediv"><table width="100%"><tr><td valign="top"><h2><span class="refentrytitle">gimpprogress</span></h2><p>gimpprogress &#8212; Functions for embedding the progress bar into a plug-in's GUI.</p></td><td valign="top" align="right"></td></tr></table></div><div class="refsynopsisdiv"><h2>Synopsis</h2><pre class="synopsis">
void (<a href="libgimp-gimpprogress.html#GimpProgressStartCallback">*GimpProgressStartCallback</a>) (const gchar *message,
gboolean cancelable,
gpointer user_data);
void (<a href="libgimp-gimpprogress.html#GimpProgressEndCallback">*GimpProgressEndCallback</a>) (gpointer user_data);
void (<a href="libgimp-gimpprogress.html#GimpProgressTextCallback">*GimpProgressTextCallback</a>) (const gchar *message,
gpointer user_data);
void (<a href="libgimp-gimpprogress.html#GimpProgressValueCallback">*GimpProgressValueCallback</a>) (gdouble percentage,
gpointer user_data);
gboolean <a href="libgimp-gimpprogress.html#gimp-progress-init">gimp_progress_init</a> (const gchar *message);
gboolean <a href="libgimp-gimpprogress.html#gimp-progress-update">gimp_progress_update</a> (gdouble percentage);
const gchar* <a href="libgimp-gimpprogress.html#gimp-progress-install">gimp_progress_install</a> (<a href="libgimp-gimpprogress.html#GimpProgressStartCallback">GimpProgressStartCallback</a> start_callback,
<a href="libgimp-gimpprogress.html#GimpProgressEndCallback">GimpProgressEndCallback</a> end_callback,
<a href="libgimp-gimpprogress.html#GimpProgressTextCallback">GimpProgressTextCallback</a> text_callback,
<a href="libgimp-gimpprogress.html#GimpProgressValueCallback">GimpProgressValueCallback</a> value_callback,
gpointer user_data);
gpointer <a href="libgimp-gimpprogress.html#gimp-progress-uninstall">gimp_progress_uninstall</a> (const gchar *progress_callback);
gboolean <a href="libgimp-gimpprogress.html#gimp-progress-cancel">gimp_progress_cancel</a> (const gchar *progress_callback);
</pre></div><div class="refsect1" lang="en"><a name="id2582936"></a><h2>Description</h2><p>
Functions for embedding the progress bar into a plug-in's GUI.
</p></div><div class="refsect1" lang="en"><a name="id2582947"></a><h2>Details</h2><div class="refsect2" lang="en"><a name="id2582952"></a><h3><a name="GimpProgressStartCallback"></a>GimpProgressStartCallback ()</h3><a class="indexterm" name="id2582960"></a><pre class="programlisting">void (*GimpProgressStartCallback) (const gchar *message,
gboolean cancelable,
gpointer user_data);</pre><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i class="parameter"><tt>message</tt></i> :</span></td><td>
</td></tr><tr><td><span class="term"><i class="parameter"><tt>cancelable</tt></i> :</span></td><td>
</td></tr><tr><td><span class="term"><i class="parameter"><tt>user_data</tt></i> :</span></td><td>
</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2583029"></a><h3><a name="GimpProgressEndCallback"></a>GimpProgressEndCallback ()</h3><a class="indexterm" name="id2583037"></a><pre class="programlisting">void (*GimpProgressEndCallback) (gpointer user_data);</pre><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i class="parameter"><tt>user_data</tt></i> :</span></td><td>
</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2582691"></a><h3><a name="GimpProgressTextCallback"></a>GimpProgressTextCallback ()</h3><a class="indexterm" name="id2582699"></a><pre class="programlisting">void (*GimpProgressTextCallback) (const gchar *message,
gpointer user_data);</pre><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i class="parameter"><tt>message</tt></i> :</span></td><td>
</td></tr><tr><td><span class="term"><i class="parameter"><tt>user_data</tt></i> :</span></td><td>
</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2582751"></a><h3><a name="GimpProgressValueCallback"></a>GimpProgressValueCallback ()</h3><a class="indexterm" name="id2582759"></a><pre class="programlisting">void (*GimpProgressValueCallback) (gdouble percentage,
gpointer user_data);</pre><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i class="parameter"><tt>percentage</tt></i> :</span></td><td>
</td></tr><tr><td><span class="term"><i class="parameter"><tt>user_data</tt></i> :</span></td><td>
</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2582810"></a><h3><a name="gimp-progress-init"></a>gimp_progress_init ()</h3><a class="indexterm" name="id2589984"></a><pre class="programlisting">gboolean gimp_progress_init (const gchar *message);</pre><p>
Initializes the progress bar for the current plug-in.
</p><p>
Initializes the progress bar for the current plug-in. It is only
valid to call this procedure from a plug-in.</p><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i class="parameter"><tt>message</tt></i> :</span></td><td> Message to use in the progress dialog.
</td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td> TRUE on success.
</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2590037"></a><h3><a name="gimp-progress-update"></a>gimp_progress_update ()</h3><a class="indexterm" name="id2590045"></a><pre class="programlisting">gboolean gimp_progress_update (gdouble percentage);</pre><p>
Updates the progress bar for the current plug-in.
</p><p>
Updates the progress bar for the current plug-in. It is only valid
to call this procedure from a plug-in.</p><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i class="parameter"><tt>percentage</tt></i> :</span></td><td> Percentage of progress completed which must be between 0.0 and 1.0.
</td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td> TRUE on success.
</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2590099"></a><h3><a name="gimp-progress-install"></a>gimp_progress_install ()</h3><a class="indexterm" name="id2590107"></a><pre class="programlisting">const gchar* gimp_progress_install (<a href="libgimp-gimpprogress.html#GimpProgressStartCallback">GimpProgressStartCallback</a> start_callback,
<a href="libgimp-gimpprogress.html#GimpProgressEndCallback">GimpProgressEndCallback</a> end_callback,
<a href="libgimp-gimpprogress.html#GimpProgressTextCallback">GimpProgressTextCallback</a> text_callback,
<a href="libgimp-gimpprogress.html#GimpProgressValueCallback">GimpProgressValueCallback</a> value_callback,
gpointer user_data);</pre><p>
</p><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i class="parameter"><tt>start_callback</tt></i> :</span></td><td> the function to call when progress starts
</td></tr><tr><td><span class="term"><i class="parameter"><tt>end_callback</tt></i> :</span></td><td> the function to call when progress finishes
</td></tr><tr><td><span class="term"><i class="parameter"><tt>text_callback</tt></i> :</span></td><td> the function to call to change the text
</td></tr><tr><td><span class="term"><i class="parameter"><tt>value_callback</tt></i> :</span></td><td> the function to call to change the value
</td></tr><tr><td><span class="term"><i class="parameter"><tt>user_data</tt></i> :</span></td><td> a pointer that is returned when uninstalling the progress
</td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td> the name of the temporary procedure that's been installed
</td></tr></tbody></table></div><p>Since GIMP 2.2
</p></div><hr><div class="refsect2" lang="en"><a name="id2590232"></a><h3><a name="gimp-progress-uninstall"></a>gimp_progress_uninstall ()</h3><a class="indexterm" name="id2584237"></a><pre class="programlisting">gpointer gimp_progress_uninstall (const gchar *progress_callback);</pre><p>
Uninstalls a temporary progress procedure that was installed using
<a href="libgimp-gimpprogress.html#gimp-progress-install"><tt class="function">gimp_progress_install()</tt></a>.</p><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i class="parameter"><tt>progress_callback</tt></i> :</span></td><td> the name of the temporary procedure to uninstall
</td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td> the <i class="parameter"><tt>user_data</tt></i> that was passed to <a href="libgimp-gimpprogress.html#gimp-progress-install"><tt class="function">gimp_progress_install()</tt></a>.
</td></tr></tbody></table></div><p>Since GIMP 2.2
</p></div><hr><div class="refsect2" lang="en"><a name="id2584306"></a><h3><a name="gimp-progress-cancel"></a>gimp_progress_cancel ()</h3><a class="indexterm" name="id2584314"></a><pre class="programlisting">gboolean gimp_progress_cancel (const gchar *progress_callback);</pre><p>
Cancels a running progress.
</p><p>
This function cancels the currently running progress.</p><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i class="parameter"><tt>progress_callback</tt></i> :</span></td><td> The name of the callback registered for this progress.
</td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td> TRUE on success.
</td></tr></tbody></table></div><p>Since GIMP 2.2
</p></div></div></div><table class="navigation" width="100%" summary="Navigation footer" cellpadding="2" cellspacing="0"><tr valign="middle"><td align="left"><a accesskey="p" href="libgimp-gimpproceduraldb.html"><b>&lt;&lt; gimpproceduraldb</b></a></td><td align="right"><a accesskey="n" href="libgimp-image.html"><b>Manupulating Images and all their Properties &gt;&gt;</b></a></td></tr></table></body></html>