New upstream version 3.24.18

This commit is contained in:
Simon McVittie
2020-04-10 15:23:16 +01:00
386 changed files with 78008 additions and 6390 deletions

View File

@ -59,7 +59,7 @@
</colgroup>
<tbody><tr>
<td class="datatype_keyword">struct</td>
<td class="function_name"><a href="https://developer.gnome.org/gtk4/GtkFileChooserDialog.html#GtkFileChooserDialog-struct">GtkFileChooserDialog</a></td>
<td class="function_name"><a class="link" href="GtkFileChooserDialog.html#GtkFileChooserDialog-struct" title="struct GtkFileChooserDialog">GtkFileChooserDialog</a></td>
</tr></tbody>
</table></div>
</div>
@ -249,12 +249,12 @@ otherwise.</p>
<a name="gtkfilechooserdialog-setting-up"></a><h4>Setting up a file chooser dialog</h4>
<p>There are various cases in which you may need to use a <a class="link" href="GtkFileChooserDialog.html" title="GtkFileChooserDialog"><span class="type">GtkFileChooserDialog</span></a>:</p>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
<li class="listitem"><p>To select a file for opening. Use <a href="https://developer.gnome.org/gtk4/GtkFileChooser.html#GTK-FILE-CHOOSER-ACTION-OPEN:CAPS"><span class="type">GTK_FILE_CHOOSER_ACTION_OPEN</span></a>.</p></li>
<li class="listitem"><p>To save a file for the first time. Use <a href="https://developer.gnome.org/gtk4/GtkFileChooser.html#GTK-FILE-CHOOSER-ACTION-SAVE:CAPS"><span class="type">GTK_FILE_CHOOSER_ACTION_SAVE</span></a>,
<li class="listitem"><p>To select a file for opening. Use <a class="link" href="GtkFileChooser.html#GTK-FILE-CHOOSER-ACTION-OPEN:CAPS"><span class="type">GTK_FILE_CHOOSER_ACTION_OPEN</span></a>.</p></li>
<li class="listitem"><p>To save a file for the first time. Use <a class="link" href="GtkFileChooser.html#GTK-FILE-CHOOSER-ACTION-SAVE:CAPS"><span class="type">GTK_FILE_CHOOSER_ACTION_SAVE</span></a>,
and suggest a name such as “Untitled” with <a class="link" href="GtkFileChooser.html#gtk-file-chooser-set-current-name" title="gtk_file_chooser_set_current_name ()"><code class="function">gtk_file_chooser_set_current_name()</code></a>.</p></li>
<li class="listitem"><p>To save a file under a different name. Use <a href="https://developer.gnome.org/gtk4/GtkFileChooser.html#GTK-FILE-CHOOSER-ACTION-SAVE:CAPS"><span class="type">GTK_FILE_CHOOSER_ACTION_SAVE</span></a>,
<li class="listitem"><p>To save a file under a different name. Use <a class="link" href="GtkFileChooser.html#GTK-FILE-CHOOSER-ACTION-SAVE:CAPS"><span class="type">GTK_FILE_CHOOSER_ACTION_SAVE</span></a>,
and set the existing filename with <a class="link" href="GtkFileChooser.html#gtk-file-chooser-set-filename" title="gtk_file_chooser_set_filename ()"><code class="function">gtk_file_chooser_set_filename()</code></a>.</p></li>
<li class="listitem"><p>To choose a folder instead of a file. Use <a href="https://developer.gnome.org/gtk4/GtkFileChooser.html#GTK-FILE-CHOOSER-ACTION-SELECT-FOLDER:CAPS"><span class="type">GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER</span></a>.</p></li>
<li class="listitem"><p>To choose a folder instead of a file. Use <a class="link" href="GtkFileChooser.html#GTK-FILE-CHOOSER-ACTION-SELECT-FOLDER:CAPS"><span class="type">GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER</span></a>.</p></li>
</ul></div>
<p>Note that old versions of the file choosers documentation suggested
using <a class="link" href="GtkFileChooser.html#gtk-file-chooser-set-current-folder" title="gtk_file_chooser_set_current_folder ()"><code class="function">gtk_file_chooser_set_current_folder()</code></a> in various
@ -271,7 +271,7 @@ have a file saved somewhere.</p>
<a name="gtkfilechooserdialog-responses"></a><h4>Response Codes</h4>
<p><a class="link" href="GtkFileChooserDialog.html" title="GtkFileChooserDialog"><span class="type">GtkFileChooserDialog</span></a> inherits from <a class="link" href="GtkDialog.html" title="GtkDialog"><span class="type">GtkDialog</span></a>, so buttons that
go in its action area have response codes such as
<a href="https://developer.gnome.org/gtk4/GtkDialog.html#GTK-RESPONSE-ACCEPT:CAPS"><span class="type">GTK_RESPONSE_ACCEPT</span></a> and <a href="https://developer.gnome.org/gtk4/GtkDialog.html#GTK-RESPONSE-CANCEL:CAPS"><span class="type">GTK_RESPONSE_CANCEL</span></a>. For example, you
<a class="link" href="GtkDialog.html#GTK-RESPONSE-ACCEPT:CAPS"><span class="type">GTK_RESPONSE_ACCEPT</span></a> and <a class="link" href="GtkDialog.html#GTK-RESPONSE-CANCEL:CAPS"><span class="type">GTK_RESPONSE_CANCEL</span></a>. For example, you
could call <a class="link" href="GtkFileChooserDialog.html#gtk-file-chooser-dialog-new" title="gtk_file_chooser_dialog_new ()"><code class="function">gtk_file_chooser_dialog_new()</code></a> as follows:</p>
<div class="informalexample">
<table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
@ -306,16 +306,16 @@ could call <a class="link" href="GtkFileChooserDialog.html#gtk-file-chooser-dial
<p></p>
<p>This will create buttons for “Cancel” and “Open” that use stock
response identifiers from <a href="https://developer.gnome.org/gtk4/GtkDialog.html#GtkResponseType"><span class="type">GtkResponseType</span></a>. For most dialog
response identifiers from <a class="link" href="GtkDialog.html#GtkResponseType" title="enum GtkResponseType"><span class="type">GtkResponseType</span></a>. For most dialog
boxes you can use your own custom response codes rather than the
ones in <a href="https://developer.gnome.org/gtk4/GtkDialog.html#GtkResponseType"><span class="type">GtkResponseType</span></a>, but <a class="link" href="GtkFileChooserDialog.html" title="GtkFileChooserDialog"><span class="type">GtkFileChooserDialog</span></a> assumes that
ones in <a class="link" href="GtkDialog.html#GtkResponseType" title="enum GtkResponseType"><span class="type">GtkResponseType</span></a>, but <a class="link" href="GtkFileChooserDialog.html" title="GtkFileChooserDialog"><span class="type">GtkFileChooserDialog</span></a> assumes that
its “accept”-type action, e.g. an “Open” or “Save” button,
will have one of the following response codes:</p>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
<li class="listitem"><p><a href="https://developer.gnome.org/gtk4/GtkDialog.html#GTK-RESPONSE-ACCEPT:CAPS"><span class="type">GTK_RESPONSE_ACCEPT</span></a></p></li>
<li class="listitem"><p><a href="https://developer.gnome.org/gtk4/GtkDialog.html#GTK-RESPONSE-OK:CAPS"><span class="type">GTK_RESPONSE_OK</span></a></p></li>
<li class="listitem"><p><a href="https://developer.gnome.org/gtk4/GtkDialog.html#GTK-RESPONSE-YES:CAPS"><span class="type">GTK_RESPONSE_YES</span></a></p></li>
<li class="listitem"><p><a href="https://developer.gnome.org/gtk4/GtkDialog.html#GTK-RESPONSE-APPLY:CAPS"><span class="type">GTK_RESPONSE_APPLY</span></a></p></li>
<li class="listitem"><p><a class="link" href="GtkDialog.html#GTK-RESPONSE-ACCEPT:CAPS"><span class="type">GTK_RESPONSE_ACCEPT</span></a></p></li>
<li class="listitem"><p><a class="link" href="GtkDialog.html#GTK-RESPONSE-OK:CAPS"><span class="type">GTK_RESPONSE_OK</span></a></p></li>
<li class="listitem"><p><a class="link" href="GtkDialog.html#GTK-RESPONSE-YES:CAPS"><span class="type">GTK_RESPONSE_YES</span></a></p></li>
<li class="listitem"><p><a class="link" href="GtkDialog.html#GTK-RESPONSE-APPLY:CAPS"><span class="type">GTK_RESPONSE_APPLY</span></a></p></li>
</ul></div>
<p>This is because <a class="link" href="GtkFileChooserDialog.html" title="GtkFileChooserDialog"><span class="type">GtkFileChooserDialog</span></a> must intercept responses
and switch to folders if appropriate, rather than letting the
@ -334,7 +334,7 @@ when you use <a class="link" href="GtkFileChooserDialog.html" title="GtkFileChoo
<pre class="programlisting"><a class="link" href="GtkWidget.html" title="GtkWidget"><span class="returnvalue">GtkWidget</span></a> *
gtk_file_chooser_dialog_new (<em class="parameter"><code>const <span class="type">gchar</span> *title</code></em>,
<em class="parameter"><code><a class="link" href="GtkWindow.html" title="GtkWindow"><span class="type">GtkWindow</span></a> *parent</code></em>,
<em class="parameter"><code><a href="https://developer.gnome.org/gtk4/GtkFileChooser.html#GtkFileChooserAction"><span class="type">GtkFileChooserAction</span></a> action</code></em>,
<em class="parameter"><code><a class="link" href="GtkFileChooser.html#GtkFileChooserAction" title="enum GtkFileChooserAction"><span class="type">GtkFileChooserAction</span></a> action</code></em>,
<em class="parameter"><code>const <span class="type">gchar</span> *first_button_text</code></em>,
<em class="parameter"><code>...</code></em>);</pre>
<p>Creates a new <a class="link" href="GtkFileChooserDialog.html" title="GtkFileChooserDialog"><span class="type">GtkFileChooserDialog</span></a>. This function is analogous to
@ -384,6 +384,13 @@ gtk_file_chooser_dialog_new (<em class="parameter"><code>const <span class="type
</div>
</div>
<div class="refsect1">
<a name="GtkFileChooserDialog.other_details"></a><h2>Types and Values</h2>
<div class="refsect2">
<a name="GtkFileChooserDialog-struct"></a><h3>struct GtkFileChooserDialog</h3>
<pre class="programlisting">struct GtkFileChooserDialog;</pre>
</div>
</div>
<div class="refsect1">
<a name="GtkFileChooserDialog.see-also"></a><h2>See Also</h2>
<p><a class="link" href="GtkFileChooser.html" title="GtkFileChooser"><span class="type">GtkFileChooser</span></a>, <a class="link" href="GtkDialog.html" title="GtkDialog"><span class="type">GtkDialog</span></a>, GtkFileChooserNative</p>
</div>