New upstream version 3.23.0

This commit is contained in:
Iain Lane
2018-07-18 14:06:19 +01:00
731 changed files with 556100 additions and 542972 deletions

View File

@ -3,12 +3,12 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>GtkRecentChooserDialog: GTK+ 3 Reference Manual</title>
<meta name="generator" content="DocBook XSL Stylesheets Vsnapshot">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="index.html" title="GTK+ 3 Reference Manual">
<link rel="up" href="RecentDocuments.html" title="Recently Used Documents">
<link rel="prev" href="GtkRecentChooser.html" title="GtkRecentChooser">
<link rel="next" href="GtkRecentChooserMenu.html" title="GtkRecentChooserMenu">
<meta name="generator" content="GTK-Doc V1.27 (XML mode)">
<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@ -109,61 +109,31 @@ Instead, you should use the functions that work on a <a class="link" href="GtkRe
<a name="gtkrecentchooser-typical-usage"></a><h4>Typical usage</h4>
<p>In the simplest of cases, you can use the following code to use
a <a class="link" href="GtkRecentChooserDialog.html" title="GtkRecentChooserDialog"><span class="type">GtkRecentChooserDialog</span></a> to select a recently used file:</p>
<div class="informalexample">
<table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td class="listing_lines" align="right"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23</pre></td>
<td class="listing_code"><pre class="programlisting"><span class="usertype">GtkWidget</span><span class="normal"> </span><span class="symbol">*</span><span class="normal">dialog</span><span class="symbol">;</span>
<span class="usertype">gint</span><span class="normal"> res</span><span class="symbol">;</span>
<div class="informalexample"><pre class="programlisting">
GtkWidget *dialog;
gint res;
<span class="normal">dialog </span><span class="symbol">=</span><span class="normal"> </span><span class="function"><a href="GtkRecentChooserDialog.html#gtk-recent-chooser-dialog-new">gtk_recent_chooser_dialog_new</a></span><span class="normal"> </span><span class="symbol">(</span><span class="string">"Recent Documents"</span><span class="symbol">,</span>
<span class="normal"> parent_window</span><span class="symbol">,</span>
<span class="normal"> </span><span class="function">_</span><span class="symbol">(</span><span class="string">"_Cancel"</span><span class="symbol">),</span>
<span class="normal"> <a href="GtkDialog.html#GTK-RESPONSE-CANCEL:CAPS">GTK_RESPONSE_CANCEL</a></span><span class="symbol">,</span>
<span class="normal"> </span><span class="function">_</span><span class="symbol">(</span><span class="string">"_Open"</span><span class="symbol">),</span>
<span class="normal"> <a href="GtkDialog.html#GTK-RESPONSE-ACCEPT:CAPS">GTK_RESPONSE_ACCEPT</a></span><span class="symbol">,</span>
<span class="normal"> NULL</span><span class="symbol">);</span>
dialog = gtk_recent_chooser_dialog_new ("Recent Documents",
parent_window,
_("_Cancel"),
GTK_RESPONSE_CANCEL,
_("_Open"),
GTK_RESPONSE_ACCEPT,
NULL);
<span class="normal">res </span><span class="symbol">=</span><span class="normal"> </span><span class="function"><a href="GtkDialog.html#gtk-dialog-run">gtk_dialog_run</a></span><span class="normal"> </span><span class="symbol">(</span><span class="function">GTK_DIALOG</span><span class="normal"> </span><span class="symbol">(</span><span class="normal">dialog</span><span class="symbol">));</span>
<span class="keyword">if</span><span class="normal"> </span><span class="symbol">(</span><span class="normal">res </span><span class="symbol">==</span><span class="normal"> <a href="GtkDialog.html#GTK-RESPONSE-ACCEPT:CAPS">GTK_RESPONSE_ACCEPT</a></span><span class="symbol">)</span>
<span class="normal"> </span><span class="cbracket">{</span>
<span class="normal"> </span><span class="usertype">GtkRecentInfo</span><span class="normal"> </span><span class="symbol">*</span><span class="normal">info</span><span class="symbol">;</span>
<span class="normal"> </span><span class="usertype">GtkRecentChooser</span><span class="normal"> </span><span class="symbol">*</span><span class="normal">chooser </span><span class="symbol">=</span><span class="normal"> </span><span class="function">GTK_RECENT_CHOOSER</span><span class="normal"> </span><span class="symbol">(</span><span class="normal">dialog</span><span class="symbol">);</span>
res = gtk_dialog_run (GTK_DIALOG (dialog));
if (res == GTK_RESPONSE_ACCEPT)
{
GtkRecentInfo *info;
GtkRecentChooser *chooser = GTK_RECENT_CHOOSER (dialog);
<span class="normal"> info </span><span class="symbol">=</span><span class="normal"> </span><span class="function"><a href="GtkRecentChooser.html#gtk-recent-chooser-get-current-item">gtk_recent_chooser_get_current_item</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">chooser</span><span class="symbol">);</span>
<span class="normal"> </span><span class="function">open_file</span><span class="normal"> </span><span class="symbol">(</span><span class="function"><a href="GtkRecentManager.html#gtk-recent-info-get-uri">gtk_recent_info_get_uri</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">info</span><span class="symbol">));</span>
<span class="normal"> </span><span class="function"><a href="GtkRecentManager.html#gtk-recent-info-unref">gtk_recent_info_unref</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">info</span><span class="symbol">);</span>
<span class="normal"> </span><span class="cbracket">}</span>
<span class="function"><a href="GtkWidget.html#gtk-widget-destroy">gtk_widget_destroy</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">dialog</span><span class="symbol">);</span></pre></td>
</tr>
</tbody>
</table>
</div>
info = gtk_recent_chooser_get_current_item (chooser);
open_file (gtk_recent_info_get_uri (info));
gtk_recent_info_unref (info);
}
gtk_widget_destroy (dialog);
</pre></div>
<p></p>
<p>Recently used files are supported since GTK+ 2.10.</p>
</div>
@ -190,17 +160,17 @@ gtk_recent_chooser_dialog_new (<em class="parameter"><code>const <span class="ty
<tbody>
<tr>
<td class="parameter_name"><p>title</p></td>
<td class="parameter_description"><p>Title of the dialog, or <code class="literal">NULL</code>. </p></td>
<td class="parameter_description"><p> Title of the dialog, or <code class="literal">NULL</code>. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>parent</p></td>
<td class="parameter_description"><p>Transient parent of the dialog, or <code class="literal">NULL</code>,. </p></td>
<td class="parameter_description"><p> Transient parent of the dialog, or <code class="literal">NULL</code>,. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>first_button_text</p></td>
<td class="parameter_description"><p>stock ID or text to go in the first button, or <code class="literal">NULL</code>. </p></td>
<td class="parameter_description"><p> stock ID or text to go in the first button, or <code class="literal">NULL</code>. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
<tr>
@ -242,12 +212,12 @@ have a customized instance of a <a class="link" href="GtkRecentManager.html" tit
<tbody>
<tr>
<td class="parameter_name"><p>title</p></td>
<td class="parameter_description"><p>Title of the dialog, or <code class="literal">NULL</code>. </p></td>
<td class="parameter_description"><p> Title of the dialog, or <code class="literal">NULL</code>. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>parent</p></td>
<td class="parameter_description"><p>Transient parent of the dialog, or <code class="literal">NULL</code>,. </p></td>
<td class="parameter_description"><p> Transient parent of the dialog, or <code class="literal">NULL</code>,. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
<tr>
@ -257,7 +227,7 @@ have a customized instance of a <a class="link" href="GtkRecentManager.html" tit
</tr>
<tr>
<td class="parameter_name"><p>first_button_text</p></td>
<td class="parameter_description"><p>stock ID or text to go in the first button, or <code class="literal">NULL</code>. </p></td>
<td class="parameter_description"><p> stock ID or text to go in the first button, or <code class="literal">NULL</code>. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
<tr>
@ -289,6 +259,6 @@ pairs, ending with <code class="literal">NULL</code></p></td>
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.27</div>
<hr>Generated by GTK-Doc V1.25</div>
</body>
</html>