Files
gimp/devel-docs/libgimpwidgets/html/GimpPathEditor.html
2010-08-11 01:21:39 -04:00

405 lines
16 KiB
HTML

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
<title>GimpPathEditor</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.72.0">
<link rel="start" href="index.html" title="GIMP Widgets Library Reference Manual">
<link rel="up" href="libgimpwidgets-widgets.html" title="Part&#160;I.&#160;GIMP Widgets">
<link rel="prev" href="GimpPageSelector.html" title="GimpPageSelector">
<link rel="next" href="GimpPickButton.html" title="GimpPickButton">
<meta name="generator" content="GTK-Doc V1.8 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
<link rel="part" href="libgimpwidgets-widgets.html" title="Part&#160;I.&#160;GIMP Widgets">
<link rel="chapter" href="libgimpwidgets-hierarchy.html" title="Object Hierarchy">
<link rel="chapter" href="libgimpwidgets-gallery.html" title="Widget Gallery">
<link rel="chapter" href="libgimpwidgets-cell-renderers.html" title="Cell Renderers for GtkTreeView">
<link rel="part" href="libgimpwidgets-colordisplay.html" title="Part&#160;II.&#160;GIMP Display Filters">
<link rel="part" href="libgimpwidgets-colorselector.html" title="Part&#160;III.&#160;GIMP Color Selectors">
<link rel="part" href="libgimpwidgets-controller.html" title="Part&#160;IV.&#160;GIMP Controllers">
<link rel="part" href="libgimpwidgets-utils.html" title="Part&#160;V.&#160;GIMP Widgets Utilities">
<link rel="part" href="libgimpwidgets-deprecated.html" title="Part&#160;VI.&#160;Deprecated API">
<link rel="index" href="libgimpwidgets-index.html" title="Index">
<link rel="index" href="libgimpwidgets-index-new-in-2-2.html" title="Index of new symbols in GIMP 2.2">
<link rel="index" href="libgimpwidgets-index-new-in-2-4.html" title="Index of new symbols in GIMP 2.4">
<link rel="index" href="libgimpwidgets-index-deprecated.html" title="Index of deprecated symbols">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
<tr valign="middle">
<td><a accesskey="p" href="GimpPageSelector.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
<td><a accesskey="u" href="libgimpwidgets-widgets.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 Widgets Library Reference Manual</th>
<td><a accesskey="n" href="GimpPickButton.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
</tr>
<tr><td colspan="5" class="shortcuts"><nobr><a href="#id2595658" class="shortcut">Top</a>
&#160;|&#160;
<a href="#id2615718" class="shortcut">Description</a>
&#160;|&#160;
<a href="#id2619552" class="shortcut">Object Hierarchy</a>
&#160;|&#160;
<a href="#id2615665" class="shortcut">Implemented Interfaces</a>
&#160;|&#160;
<a href="#id2615687" class="shortcut">Signals</a></nobr></td></tr>
</table>
<div class="refentry" lang="en">
<a name="GimpPathEditor"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2>
<a name="id2595658"></a><span class="refentrytitle">GimpPathEditor</span>
</h2>
<p>GimpPathEditor &#8212; Widget for editing a file search path.</p>
</td>
<td valign="top" align="right"><img src="gimp-path-editor.png"></td>
</tr></table></div>
<div class="refsynopsisdiv">
<h2>Synopsis</h2>
<pre class="synopsis">
<a href="GimpPathEditor.html#GimpPathEditor-struct">GimpPathEditor</a>;
GtkWidget* <a href="GimpPathEditor.html#gimp-path-editor-new">gimp_path_editor_new</a> (const gchar *title,
const gchar *path);
gchar* <a href="GimpPathEditor.html#gimp-path-editor-get-path">gimp_path_editor_get_path</a> (<a href="GimpPathEditor.html" title="GimpPathEditor">GimpPathEditor</a> *editor);
void <a href="GimpPathEditor.html#gimp-path-editor-set-path">gimp_path_editor_set_path</a> (<a href="GimpPathEditor.html" title="GimpPathEditor">GimpPathEditor</a> *editor,
const gchar *path);
gchar* <a href="GimpPathEditor.html#gimp-path-editor-get-writable-path">gimp_path_editor_get_writable_path</a> (<a href="GimpPathEditor.html" title="GimpPathEditor">GimpPathEditor</a> *editor);
void <a href="GimpPathEditor.html#gimp-path-editor-set-writable-path">gimp_path_editor_set_writable_path</a> (<a href="GimpPathEditor.html" title="GimpPathEditor">GimpPathEditor</a> *editor,
const gchar *path);
gboolean <a href="GimpPathEditor.html#gimp-path-editor-get-dir-writable">gimp_path_editor_get_dir_writable</a> (<a href="GimpPathEditor.html" title="GimpPathEditor">GimpPathEditor</a> *editor,
const gchar *directory);
void <a href="GimpPathEditor.html#gimp-path-editor-set-dir-writable">gimp_path_editor_set_dir_writable</a> (<a href="GimpPathEditor.html" title="GimpPathEditor">GimpPathEditor</a> *editor,
const gchar *directory,
gboolean writable);
</pre>
</div>
<div class="refsect1" lang="en">
<a name="id2619552"></a><h2>Object Hierarchy</h2>
<pre class="synopsis">
GObject
+----GInitiallyUnowned
+----GtkObject
+----GtkWidget
+----GtkContainer
+----GtkBox
+----GtkVBox
+----GimpPathEditor
</pre>
</div>
<div class="refsect1" lang="en">
<a name="id2615665"></a><h2>Implemented Interfaces</h2>
<p>
GimpPathEditor implements
AtkImplementorIface.</p>
</div>
<div class="refsect1" lang="en">
<a name="id2615687"></a><h2>Signals</h2>
<pre class="synopsis">
"<a href="GimpPathEditor.html#GimpPathEditor-path-changed">path-changed</a>" : Run First
"<a href="GimpPathEditor.html#GimpPathEditor-writable-changed">writable-changed</a>" : Run First
</pre>
</div>
<div class="refsect1" lang="en">
<a name="id2615718"></a><h2>Description</h2>
<p>
This widget is used to edit file search paths.
</p>
<p>
It shows a list of all directories which are in the search path. You
can click a directory to select it. The widget provides a
<a href="GimpFileEntry.html" title="GimpFileEntry"><span class="type">GimpFileEntry</span></a> to change the currently selected directory.
</p>
<p>
There are buttons to add or delete directories as well as "up" and "down"
buttons to change the order in which the directories will be searched.
</p>
<p>
Whenever the user adds, deletes, changes or reorders a directory of
the search path, the "path_changed" signal will be emitted.
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2615760"></a><h2>Details</h2>
<div class="refsect2" lang="en">
<a name="id2615771"></a><h3>
<a name="GimpPathEditor-struct"></a>GimpPathEditor</h3>
<a class="indexterm" name="id2615782"></a><pre class="programlisting">typedef struct _GimpPathEditor GimpPathEditor;</pre>
<p>
</p>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2615799"></a><h3>
<a name="gimp-path-editor-new"></a>gimp_path_editor_new ()</h3>
<a class="indexterm" name="id2615810"></a><pre class="programlisting">GtkWidget* gimp_path_editor_new (const gchar *title,
const gchar *path);</pre>
<p>
Creates a new <a href="GimpPathEditor.html" title="GimpPathEditor"><span class="type">GimpPathEditor</span></a> widget.
</p>
<p>
The elements of the initial search path must be separated with the
<span class="type">G_SEARCHPATH_SEPARATOR</span> character.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><span class="term"><em class="parameter"><code>title</code></em>&#160;:</span></td>
<td> The title of the <span class="type">GtkFileChooser</span> dialog which can be popped up.
</td>
</tr>
<tr>
<td><span class="term"><em class="parameter"><code>path</code></em>&#160;:</span></td>
<td> The initial search path.
</td>
</tr>
<tr>
<td><span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> A pointer to the new <a href="GimpPathEditor.html" title="GimpPathEditor"><span class="type">GimpPathEditor</span></a> widget.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2615924"></a><h3>
<a name="gimp-path-editor-get-path"></a>gimp_path_editor_get_path ()</h3>
<a class="indexterm" name="id2615935"></a><pre class="programlisting">gchar* gimp_path_editor_get_path (<a href="GimpPathEditor.html" title="GimpPathEditor">GimpPathEditor</a> *editor);</pre>
<p>
The elements of the returned search path string are separated with the
<span class="type">G_SEARCHPATH_SEPARATOR</span> character.
</p>
<p>
Note that you have to <code class="function">g_free()</code> the returned string.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><span class="term"><em class="parameter"><code>editor</code></em>&#160;:</span></td>
<td> The path editor you want to get the search path from.
</td>
</tr>
<tr>
<td><span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The search path the user has selected in the path editor.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2616018"></a><h3>
<a name="gimp-path-editor-set-path"></a>gimp_path_editor_set_path ()</h3>
<a class="indexterm" name="id2616029"></a><pre class="programlisting">void gimp_path_editor_set_path (<a href="GimpPathEditor.html" title="GimpPathEditor">GimpPathEditor</a> *editor,
const gchar *path);</pre>
<p>
The elements of the initial search path must be separated with the
<span class="type">G_SEARCHPATH_SEPARATOR</span> character.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><span class="term"><em class="parameter"><code>editor</code></em>&#160;:</span></td>
<td> The path editor you want to set the search path from.
</td>
</tr>
<tr>
<td><span class="term"><em class="parameter"><code>path</code></em>&#160;:</span></td>
<td> The new path to set.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2616156"></a><h3>
<a name="gimp-path-editor-get-writable-path"></a>gimp_path_editor_get_writable_path ()</h3>
<a class="indexterm" name="id2616168"></a><pre class="programlisting">gchar* gimp_path_editor_get_writable_path (<a href="GimpPathEditor.html" title="GimpPathEditor">GimpPathEditor</a> *editor);</pre>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><span class="term"><em class="parameter"><code>editor</code></em>&#160;:</span></td>
<td>
</td>
</tr>
<tr>
<td><span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2616224"></a><h3>
<a name="gimp-path-editor-set-writable-path"></a>gimp_path_editor_set_writable_path ()</h3>
<a class="indexterm" name="id2616235"></a><pre class="programlisting">void gimp_path_editor_set_writable_path (<a href="GimpPathEditor.html" title="GimpPathEditor">GimpPathEditor</a> *editor,
const gchar *path);</pre>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><span class="term"><em class="parameter"><code>editor</code></em>&#160;:</span></td>
<td>
</td>
</tr>
<tr>
<td><span class="term"><em class="parameter"><code>path</code></em>&#160;:</span></td>
<td>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2616303"></a><h3>
<a name="gimp-path-editor-get-dir-writable"></a>gimp_path_editor_get_dir_writable ()</h3>
<a class="indexterm" name="id2616315"></a><pre class="programlisting">gboolean gimp_path_editor_get_dir_writable (<a href="GimpPathEditor.html" title="GimpPathEditor">GimpPathEditor</a> *editor,
const gchar *directory);</pre>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><span class="term"><em class="parameter"><code>editor</code></em>&#160;:</span></td>
<td>
</td>
</tr>
<tr>
<td><span class="term"><em class="parameter"><code>directory</code></em>&#160;:</span></td>
<td>
</td>
</tr>
<tr>
<td><span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2616393"></a><h3>
<a name="gimp-path-editor-set-dir-writable"></a>gimp_path_editor_set_dir_writable ()</h3>
<a class="indexterm" name="id2616407"></a><pre class="programlisting">void gimp_path_editor_set_dir_writable (<a href="GimpPathEditor.html" title="GimpPathEditor">GimpPathEditor</a> *editor,
const gchar *directory,
gboolean writable);</pre>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><span class="term"><em class="parameter"><code>editor</code></em>&#160;:</span></td>
<td>
</td>
</tr>
<tr>
<td><span class="term"><em class="parameter"><code>directory</code></em>&#160;:</span></td>
<td>
</td>
</tr>
<tr>
<td><span class="term"><em class="parameter"><code>writable</code></em>&#160;:</span></td>
<td>
</td>
</tr>
</tbody>
</table></div>
</div>
</div>
<div class="refsect1" lang="en">
<a name="id2616497"></a><h2>Signal Details</h2>
<div class="refsect2" lang="en">
<a name="id2616508"></a><h3>
<a name="GimpPathEditor-path-changed"></a>The "path-changed" signal</h3>
<a class="indexterm" name="id2616516"></a><pre class="programlisting">void user_function (<a href="GimpPathEditor.html" title="GimpPathEditor">GimpPathEditor</a> *arg0,
gpointer user_data) : Run First</pre>
<p>
This signal is emitted whenever the user adds, deletes, modifies
or reorders an element of the search path.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><span class="term"><em class="parameter"><code>user_data</code></em>&#160;:</span></td>
<td>user data set when the signal handler was connected.</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2616575"></a><h3>
<a name="GimpPathEditor-writable-changed"></a>The "writable-changed" signal</h3>
<a class="indexterm" name="id2616584"></a><pre class="programlisting">void user_function (<a href="GimpPathEditor.html" title="GimpPathEditor">GimpPathEditor</a> *arg0,
gpointer user_data) : Run First</pre>
<p>
This signal is emitted whenever the "writable" column of a directory
is changed, either by the user clicking on it or by calling
<a href="GimpPathEditor.html#gimp-path-editor-set-dir-writable"><code class="function">gimp_path_editor_set_dir_writable()</code></a>.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><span class="term"><em class="parameter"><code>user_data</code></em>&#160;:</span></td>
<td>user data set when the signal handler was connected.</td>
</tr></tbody>
</table></div>
</div>
</div>
<div class="refsect1" lang="en">
<a name="id2616656"></a><h2>See Also</h2>
<p>
<a href="GimpFileEntry.html" title="GimpFileEntry"><span class="type">GimpFileEntry</span></a>
</p>
<p>
<span class="type">G_SEARCHPATH_SEPARATOR</span>
</p>
</div>
</div>
</body>
</html>