| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
<!DOCTYPE html> |
| 8 |
<html lang="en"> |
| 9 |
<head> |
| 10 |
<title>GExiv2.PreviewImage.try_write_file</title> |
| 11 |
<meta name="viewport" content="width=device-width, initial-scale=1"> |
| 12 |
|
| 13 |
<meta charset="utf-8" /> |
| 14 |
|
| 15 |
|
| 16 |
<meta property="og:type" content="website"/> |
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
<meta priority="og:title" content="GExiv2.PreviewImage.try_write_file"/> |
| 22 |
<meta priority="og:description" content="Reference for GExiv2.PreviewImage.try_write_file"/> |
| 23 |
<meta name="twitter:title" content="GExiv2.PreviewImage.try_write_file"/> |
| 24 |
<meta name="twitter:description" content="Reference for GExiv2.PreviewImage.try_write_file"/> |
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
<meta name="twitter:card" content="summary"/> |
| 29 |
|
| 30 |
|
| 31 |
|
| 32 |
|
| 33 |
|
| 34 |
|
| 35 |
<link rel="stylesheet" href="style.css" type="text/css" /> |
| 36 |
|
| 37 |
|
| 38 |
|
| 39 |
|
| 40 |
<script src="urlmap.js"></script> |
| 41 |
|
| 42 |
|
| 43 |
<script src="fzy.js"></script> |
| 44 |
<script src="search.js"></script> |
| 45 |
|
| 46 |
<script src="main.js"></script> |
| 47 |
|
| 48 |
|
| 49 |
</head> |
| 50 |
|
| 51 |
<body> |
| 52 |
<div id="body-wrapper" tabindex="-1"> |
| 53 |
|
| 54 |
<nav class="sidebar devhelp-hidden"> |
| 55 |
|
| 56 |
|
| 57 |
<div class="search section"> |
| 58 |
<form id="search-form" autocomplete="off"> |
| 59 |
<input id="search-input" type="text" name="do-not-autocomplete" placeholder="Click, or press 's' to search" autocomplete="off"/> |
| 60 |
</form> |
| 61 |
</div> |
| 62 |
|
| 63 |
<div class="section namespace"> |
| 64 |
<h3><a href="index.html">GExiv2</a></h3> |
| 65 |
<p>API Version: 0.16</p> |
| 66 |
|
| 67 |
<p>Library Version: 0.16.2</p> |
| 68 |
|
| 69 |
</div> |
| 70 |
|
| 71 |
<div class="section"> |
| 72 |
<h5>Type</h5> |
| 73 |
<div class="links"> |
| 74 |
<a href="class.PreviewImage.html">PreviewImage</a> |
| 75 |
</div> |
| 76 |
</div> |
| 77 |
<div class="section"> |
| 78 |
<h5>Methods</h5> |
| 79 |
<div class="links"> |
| 80 |
|
| 81 |
<a class="method" href="method.PreviewImage.get_data.html">get_data</a> |
| 82 |
|
| 83 |
<a class="method" href="method.PreviewImage.get_extension.html">get_extension</a> |
| 84 |
|
| 85 |
<a class="method" href="method.PreviewImage.get_height.html">get_height</a> |
| 86 |
|
| 87 |
<a class="method" href="method.PreviewImage.get_mime_type.html">get_mime_type</a> |
| 88 |
|
| 89 |
<a class="method" href="method.PreviewImage.get_width.html">get_width</a> |
| 90 |
|
| 91 |
<a class="method current" href="method.PreviewImage.try_write_file.html">try_write_file</a> |
| 92 |
|
| 93 |
<a class="method" href="method.PreviewImage.write_file.html">write_file</a> |
| 94 |
|
| 95 |
</div> |
| 96 |
</div> |
| 97 |
|
| 98 |
<div class="section generator"> |
| 99 |
<p>Generated by <a href="https://gitlab.gnome.org/GNOME/gi-docgen">gi-docgen</a> 2025.5</p> |
| 100 |
</div> |
| 101 |
</nav> |
| 102 |
|
| 103 |
<button id="btn-to-top" class="hidden"><span class="up-arrow"></span></button> |
| 104 |
|
| 105 |
|
| 106 |
<section id="main" class="content"> |
| 107 |
<header> |
| 108 |
<h3>Method</h3> |
| 109 |
<h1><a href="index.html">GExiv2</a><span class="sep"></span><a href="class.PreviewImage.html">PreviewImage</a><span class="sep"></span>try_write_file</h1> |
| 110 |
</header> |
| 111 |
|
| 112 |
<section> |
| 113 |
<div class="docblock"> |
| 114 |
<p><span class="emblem deprecated">deprecated: 0.16.0</span> <span class="emblem available">since: 0.14.0</span></p> |
| 115 |
</div> |
| 116 |
|
| 117 |
<div class="declaration toggle-wrapper"> |
| 118 |
<h4 style="display:flex;" id="declaration"> |
| 119 |
Declaration |
| 120 |
<a class="anchor" href="#declaration"></a> |
| 121 |
|
| 122 |
<a class="srclink" title="go to source location" href="https://gitlab.gnome.org/GNOME/gexiv2/-/blob/gexiv2/gexiv2-preview-image.h#L131">[src]</a> |
| 123 |
|
| 124 |
</h4> |
| 125 |
|
| 126 |
<div class="docblock c-decl"> |
| 127 |
<pre><code><div class="highlight"><pre><span></span><span class="n">glong</span> |
| 128 |
<span class="n">gexiv2_preview_image_try_write_file</span><span class="w"> </span><span class="p">(</span> |
| 129 |
<span class="w"> </span><span class="n">GExiv2PreviewImage</span><span class="o">*</span><span class="w"> </span><span class="n">self</span><span class="p">,</span> |
| 130 |
<span class="w"> </span><span class="k">const</span><span class="w"> </span><span class="n">gchar</span><span class="o">*</span><span class="w"> </span><span class="n">path</span><span class="p">,</span> |
| 131 |
<span class="w"> </span><span class="n">GError</span><span class="o">**</span><span class="w"> </span><span class="n">error</span> |
| 132 |
<span class="p">)</span> |
| 133 |
</pre></div> |
| 134 |
</code></pre> |
| 135 |
</div> |
| 136 |
</div> |
| 137 |
|
| 138 |
<div class="description toggle-wrapper"> |
| 139 |
<h4 style="display:flex;" id="description"> |
| 140 |
Description |
| 141 |
<a class="anchor" href="#description"></a> |
| 142 |
|
| 143 |
<a class="srclink" title="go to source location" href="https://gitlab.gnome.org/GNOME/gexiv2/-/blob/gexiv2/gexiv2-preview-image.h#L116">[src]</a> |
| 144 |
|
| 145 |
</h4> |
| 146 |
|
| 147 |
<div class="docblock"> |
| 148 |
<p>Write the preview image to a file in <code>path</code>.</p> |
| 149 |
</div> |
| 150 |
|
| 151 |
<div class="docblock"> |
| 152 |
|
| 153 |
<p>Available since: 0.14.0</p> |
| 154 |
<div class="admonition deprecation"> |
| 155 |
<p class="admonition-title">Deprecated since: 0.16.0</p><p>Use <a href="method.PreviewImage.write_file.html"><code>gexiv2_preview_image_write_file()</code></a> instead.</p></div> |
| 156 |
|
| 157 |
|
| 158 |
|
| 159 |
|
| 160 |
</div> |
| 161 |
|
| 162 |
|
| 163 |
</div> |
| 164 |
|
| 165 |
|
| 166 |
<div class="parameters toggle-wrapper"> |
| 167 |
<h4 id="parameters"> |
| 168 |
Parameters |
| 169 |
<a href="#parameters" class="anchor"></a> |
| 170 |
</h4> |
| 171 |
|
| 172 |
<div class="docblock"> |
| 173 |
<dl class="arguments"> |
| 174 |
|
| 175 |
|
| 176 |
|
| 177 |
<dt class="arg-name"><code>path</code></dt> |
| 178 |
<dd class="arg-description"> |
| 179 |
<p><em>Type:</em> <code>const gchar*</code></p> |
| 180 |
<p>The file path to write the preview image to.</p> |
| 181 |
<table> |
| 182 |
|
| 183 |
|
| 184 |
|
| 185 |
|
| 186 |
|
| 187 |
|
| 188 |
|
| 189 |
<tr><td title="transfer: none">The data is owned by the caller of the method.</td></tr> |
| 190 |
<tr><td>The value is a NUL terminated UTF-8 string.</td></tr> |
| 191 |
</table> |
| 192 |
</dd> |
| 193 |
|
| 194 |
|
| 195 |
|
| 196 |
<dt class="arg-name"><code>error</code></dt> |
| 197 |
<dd class="arg-description"> |
| 198 |
<p><em>Type:</em> <a href="javascript:void(0)" data-namespace="GLib" data-link="struct.Error.html" class="external"><code>GError **</code></a></p> |
| 199 |
<p>The return location for <a href="https://docs.gtk.org/glib/error-reporting.html#rules-for-use-of-gerror">a recoverable error</a>.</p> |
| 200 |
<table> |
| 201 |
<tr><td>The argument can be <code>NULL</code>.</td></tr> |
| 202 |
<tr><td>If the return location is not <code>NULL</code>, then you must initialize it to a <code>NULL</code> <code>GError*</code>.</td></tr> |
| 203 |
<tr><td>The argument will be left initialized to <code>NULL</code> by the method if there are no errors.</td></tr> |
| 204 |
<tr><td>In case of error, the argument will be set to a newly allocated <code>GError</code>; the caller will take ownership of the data, and be responsible for freeing it.</td></tr> |
| 205 |
</table> |
| 206 |
</dd> |
| 207 |
|
| 208 |
</dl> |
| 209 |
</div> |
| 210 |
</div> |
| 211 |
|
| 212 |
|
| 213 |
|
| 214 |
<div class="return-value toggle-wrapper"> |
| 215 |
<h4 id="return-value"> |
| 216 |
Return value |
| 217 |
<a href="#return-value" class="anchor"></a> |
| 218 |
</h4> |
| 219 |
|
| 220 |
<div class="docblock"> |
| 221 |
<div class="returns"> |
| 222 |
<div class="arg-description"> |
| 223 |
<p><em>Type:</em> <code>glong</code></p> |
| 224 |
<p>The number of bytes written to the file.</p> |
| 225 |
</div> |
| 226 |
<div> |
| 227 |
<table> |
| 228 |
|
| 229 |
|
| 230 |
|
| 231 |
|
| 232 |
|
| 233 |
|
| 234 |
</table> |
| 235 |
</div> |
| 236 |
</div> |
| 237 |
</div> |
| 238 |
</div> |
| 239 |
|
| 240 |
|
| 241 |
</section> |
| 242 |
</section> |
| 243 |
|
| 244 |
|
| 245 |
|
| 246 |
|
| 247 |
<section id="search" class="content hidden"></section> |
| 248 |
|
| 249 |
<footer> |
| 250 |
|
| 251 |
</footer> |
| 252 |
</div> |
| 253 |
</body> |
| 254 |
</html> |