Imported Upstream version 3.4.0
[platform/upstream/harfbuzz.git] / docs / html / harfbuzz-hb-buffer.html
1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2 <html>
3 <head>
4 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
5 <title>hb-buffer: HarfBuzz Manual</title>
6 <meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
7 <link rel="home" href="index.html" title="HarfBuzz Manual">
8 <link rel="up" href="core-api.html" title="Core API">
9 <link rel="prev" href="harfbuzz-hb-blob.html" title="hb-blob">
10 <link rel="next" href="harfbuzz-hb-common.html" title="hb-common">
11 <meta name="generator" content="GTK-Doc V1.32 (XML mode)">
12 <link rel="stylesheet" href="style.css" type="text/css">
13 </head>
14 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
15 <table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="5"><tr valign="middle">
16 <td width="100%" align="left" class="shortcuts">
17 <a href="#" class="shortcut">Top</a><span id="nav_description">  <span class="dim">|</span> 
18                   <a href="#harfbuzz-hb-buffer.description" class="shortcut">Description</a></span>
19 </td>
20 <td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td>
21 <td><a accesskey="u" href="core-api.html"><img src="up.png" width="16" height="16" border="0" alt="Up"></a></td>
22 <td><a accesskey="p" href="harfbuzz-hb-blob.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td>
23 <td><a accesskey="n" href="harfbuzz-hb-common.html"><img src="right.png" width="16" height="16" border="0" alt="Next"></a></td>
24 </tr></table>
25 <div class="refentry">
26 <a name="harfbuzz-hb-buffer"></a><div class="titlepage"></div>
27 <div class="refnamediv"><table width="100%"><tr>
28 <td valign="top">
29 <h2><span class="refentrytitle"><a name="harfbuzz-hb-buffer.top_of_page"></a>hb-buffer</span></h2>
30 <p>hb-buffer — Input and output buffers</p>
31 </td>
32 <td class="gallery_image" valign="top" align="right"></td>
33 </tr></table></div>
34 <div class="refsect1">
35 <a name="harfbuzz-hb-buffer.functions"></a><h2>Functions</h2>
36 <div class="informaltable"><table class="informaltable" width="100%" border="0">
37 <colgroup>
38 <col width="150px" class="functions_proto_type">
39 <col class="functions_proto_name">
40 </colgroup>
41 <tbody>
42 <tr>
43 <td class="function_type">
44 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="returnvalue">hb_buffer_t</span></a> *
45 </td>
46 <td class="function_name">
47 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-create" title="hb_buffer_create ()">hb_buffer_create</a> <span class="c_punctuation">()</span>
48 </td>
49 </tr>
50 <tr>
51 <td class="function_type">
52 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="returnvalue">hb_buffer_t</span></a> *
53 </td>
54 <td class="function_name">
55 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-create-similar" title="hb_buffer_create_similar ()">hb_buffer_create_similar</a> <span class="c_punctuation">()</span>
56 </td>
57 </tr>
58 <tr>
59 <td class="function_type">
60 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="returnvalue">hb_buffer_t</span></a> *
61 </td>
62 <td class="function_name">
63 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-reference" title="hb_buffer_reference ()">hb_buffer_reference</a> <span class="c_punctuation">()</span>
64 </td>
65 </tr>
66 <tr>
67 <td class="function_type">
68 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="returnvalue">hb_buffer_t</span></a> *
69 </td>
70 <td class="function_name">
71 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-empty" title="hb_buffer_get_empty ()">hb_buffer_get_empty</a> <span class="c_punctuation">()</span>
72 </td>
73 </tr>
74 <tr>
75 <td class="function_type">
76 <span class="returnvalue">void</span>
77 </td>
78 <td class="function_name">
79 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-destroy" title="hb_buffer_destroy ()">hb_buffer_destroy</a> <span class="c_punctuation">()</span>
80 </td>
81 </tr>
82 <tr>
83 <td class="function_type">
84 <span class="returnvalue">void</span>
85 </td>
86 <td class="function_name">
87 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-reset" title="hb_buffer_reset ()">hb_buffer_reset</a> <span class="c_punctuation">()</span>
88 </td>
89 </tr>
90 <tr>
91 <td class="function_type">
92 <span class="returnvalue">void</span>
93 </td>
94 <td class="function_name">
95 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-clear-contents" title="hb_buffer_clear_contents ()">hb_buffer_clear_contents</a> <span class="c_punctuation">()</span>
96 </td>
97 </tr>
98 <tr>
99 <td class="function_type">
100 <a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
101 </td>
102 <td class="function_name">
103 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-pre-allocate" title="hb_buffer_pre_allocate ()">hb_buffer_pre_allocate</a> <span class="c_punctuation">()</span>
104 </td>
105 </tr>
106 <tr>
107 <td class="function_type">
108 <a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
109 </td>
110 <td class="function_name">
111 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-allocation-successful" title="hb_buffer_allocation_successful ()">hb_buffer_allocation_successful</a> <span class="c_punctuation">()</span>
112 </td>
113 </tr>
114 <tr>
115 <td class="function_type">
116 <span class="returnvalue">void</span>
117 </td>
118 <td class="function_name">
119 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-add" title="hb_buffer_add ()">hb_buffer_add</a> <span class="c_punctuation">()</span>
120 </td>
121 </tr>
122 <tr>
123 <td class="function_type">
124 <span class="returnvalue">void</span>
125 </td>
126 <td class="function_name">
127 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-add-codepoints" title="hb_buffer_add_codepoints ()">hb_buffer_add_codepoints</a> <span class="c_punctuation">()</span>
128 </td>
129 </tr>
130 <tr>
131 <td class="function_type">
132 <span class="returnvalue">void</span>
133 </td>
134 <td class="function_name">
135 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-add-utf32" title="hb_buffer_add_utf32 ()">hb_buffer_add_utf32</a> <span class="c_punctuation">()</span>
136 </td>
137 </tr>
138 <tr>
139 <td class="function_type">
140 <span class="returnvalue">void</span>
141 </td>
142 <td class="function_name">
143 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-add-utf16" title="hb_buffer_add_utf16 ()">hb_buffer_add_utf16</a> <span class="c_punctuation">()</span>
144 </td>
145 </tr>
146 <tr>
147 <td class="function_type">
148 <span class="returnvalue">void</span>
149 </td>
150 <td class="function_name">
151 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-add-utf8" title="hb_buffer_add_utf8 ()">hb_buffer_add_utf8</a> <span class="c_punctuation">()</span>
152 </td>
153 </tr>
154 <tr>
155 <td class="function_type">
156 <span class="returnvalue">void</span>
157 </td>
158 <td class="function_name">
159 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-add-latin1" title="hb_buffer_add_latin1 ()">hb_buffer_add_latin1</a> <span class="c_punctuation">()</span>
160 </td>
161 </tr>
162 <tr>
163 <td class="function_type">
164 <span class="returnvalue">void</span>
165 </td>
166 <td class="function_name">
167 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-append" title="hb_buffer_append ()">hb_buffer_append</a> <span class="c_punctuation">()</span>
168 </td>
169 </tr>
170 <tr>
171 <td class="function_type">
172 <span class="returnvalue">void</span>
173 </td>
174 <td class="function_name">
175 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-content-type" title="hb_buffer_set_content_type ()">hb_buffer_set_content_type</a> <span class="c_punctuation">()</span>
176 </td>
177 </tr>
178 <tr>
179 <td class="function_type">
180 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-content-type-t" title="enum hb_buffer_content_type_t"><span class="returnvalue">hb_buffer_content_type_t</span></a>
181 </td>
182 <td class="function_name">
183 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-content-type" title="hb_buffer_get_content_type ()">hb_buffer_get_content_type</a> <span class="c_punctuation">()</span>
184 </td>
185 </tr>
186 <tr>
187 <td class="function_type">
188 <span class="returnvalue">void</span>
189 </td>
190 <td class="function_name">
191 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-direction" title="hb_buffer_set_direction ()">hb_buffer_set_direction</a> <span class="c_punctuation">()</span>
192 </td>
193 </tr>
194 <tr>
195 <td class="function_type">
196 <a class="link" href="harfbuzz-hb-common.html#hb-direction-t" title="enum hb_direction_t"><span class="returnvalue">hb_direction_t</span></a>
197 </td>
198 <td class="function_name">
199 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-direction" title="hb_buffer_get_direction ()">hb_buffer_get_direction</a> <span class="c_punctuation">()</span>
200 </td>
201 </tr>
202 <tr>
203 <td class="function_type">
204 <span class="returnvalue">void</span>
205 </td>
206 <td class="function_name">
207 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-script" title="hb_buffer_set_script ()">hb_buffer_set_script</a> <span class="c_punctuation">()</span>
208 </td>
209 </tr>
210 <tr>
211 <td class="function_type">
212 <a class="link" href="harfbuzz-hb-common.html#hb-script-t" title="enum hb_script_t"><span class="returnvalue">hb_script_t</span></a>
213 </td>
214 <td class="function_name">
215 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-script" title="hb_buffer_get_script ()">hb_buffer_get_script</a> <span class="c_punctuation">()</span>
216 </td>
217 </tr>
218 <tr>
219 <td class="function_type">
220 <span class="returnvalue">void</span>
221 </td>
222 <td class="function_name">
223 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-language" title="hb_buffer_set_language ()">hb_buffer_set_language</a> <span class="c_punctuation">()</span>
224 </td>
225 </tr>
226 <tr>
227 <td class="function_type">
228 <a class="link" href="harfbuzz-hb-common.html#hb-language-t" title="hb_language_t"><span class="returnvalue">hb_language_t</span></a>
229 </td>
230 <td class="function_name">
231 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-language" title="hb_buffer_get_language ()">hb_buffer_get_language</a> <span class="c_punctuation">()</span>
232 </td>
233 </tr>
234 <tr>
235 <td class="function_type">
236 <span class="returnvalue">void</span>
237 </td>
238 <td class="function_name">
239 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-flags" title="hb_buffer_set_flags ()">hb_buffer_set_flags</a> <span class="c_punctuation">()</span>
240 </td>
241 </tr>
242 <tr>
243 <td class="function_type">
244 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-flags-t" title="enum hb_buffer_flags_t"><span class="returnvalue">hb_buffer_flags_t</span></a>
245 </td>
246 <td class="function_name">
247 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-flags" title="hb_buffer_get_flags ()">hb_buffer_get_flags</a> <span class="c_punctuation">()</span>
248 </td>
249 </tr>
250 <tr>
251 <td class="function_type">
252 <span class="returnvalue">void</span>
253 </td>
254 <td class="function_name">
255 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-cluster-level" title="hb_buffer_set_cluster_level ()">hb_buffer_set_cluster_level</a> <span class="c_punctuation">()</span>
256 </td>
257 </tr>
258 <tr>
259 <td class="function_type">
260 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-cluster-level-t" title="enum hb_buffer_cluster_level_t"><span class="returnvalue">hb_buffer_cluster_level_t</span></a>
261 </td>
262 <td class="function_name">
263 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-cluster-level" title="hb_buffer_get_cluster_level ()">hb_buffer_get_cluster_level</a> <span class="c_punctuation">()</span>
264 </td>
265 </tr>
266 <tr>
267 <td class="function_type">
268 <a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
269 </td>
270 <td class="function_name">
271 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-length" title="hb_buffer_set_length ()">hb_buffer_set_length</a> <span class="c_punctuation">()</span>
272 </td>
273 </tr>
274 <tr>
275 <td class="function_type">unsigned <span class="returnvalue">int</span>
276 </td>
277 <td class="function_name">
278 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-length" title="hb_buffer_get_length ()">hb_buffer_get_length</a> <span class="c_punctuation">()</span>
279 </td>
280 </tr>
281 <tr>
282 <td class="function_type">
283 <span class="returnvalue">void</span>
284 </td>
285 <td class="function_name">
286 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-segment-properties" title="hb_buffer_set_segment_properties ()">hb_buffer_set_segment_properties</a> <span class="c_punctuation">()</span>
287 </td>
288 </tr>
289 <tr>
290 <td class="function_type">
291 <span class="returnvalue">void</span>
292 </td>
293 <td class="function_name">
294 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-segment-properties" title="hb_buffer_get_segment_properties ()">hb_buffer_get_segment_properties</a> <span class="c_punctuation">()</span>
295 </td>
296 </tr>
297 <tr>
298 <td class="function_type">
299 <span class="returnvalue">void</span>
300 </td>
301 <td class="function_name">
302 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-guess-segment-properties" title="hb_buffer_guess_segment_properties ()">hb_buffer_guess_segment_properties</a> <span class="c_punctuation">()</span>
303 </td>
304 </tr>
305 <tr>
306 <td class="function_type">
307 <span class="returnvalue">void</span>
308 </td>
309 <td class="function_name">
310 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-unicode-funcs" title="hb_buffer_set_unicode_funcs ()">hb_buffer_set_unicode_funcs</a> <span class="c_punctuation">()</span>
311 </td>
312 </tr>
313 <tr>
314 <td class="function_type">
315 <a class="link" href="harfbuzz-hb-unicode.html#hb-unicode-funcs-t" title="hb_unicode_funcs_t"><span class="returnvalue">hb_unicode_funcs_t</span></a> *
316 </td>
317 <td class="function_name">
318 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-unicode-funcs" title="hb_buffer_get_unicode_funcs ()">hb_buffer_get_unicode_funcs</a> <span class="c_punctuation">()</span>
319 </td>
320 </tr>
321 <tr>
322 <td class="function_type">
323 <a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
324 </td>
325 <td class="function_name">
326 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-user-data" title="hb_buffer_set_user_data ()">hb_buffer_set_user_data</a> <span class="c_punctuation">()</span>
327 </td>
328 </tr>
329 <tr>
330 <td class="function_type">
331 <span class="returnvalue">void</span> *
332 </td>
333 <td class="function_name">
334 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-user-data" title="hb_buffer_get_user_data ()">hb_buffer_get_user_data</a> <span class="c_punctuation">()</span>
335 </td>
336 </tr>
337 <tr>
338 <td class="function_type">
339 <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t" title="hb_glyph_info_t"><span class="returnvalue">hb_glyph_info_t</span></a> *
340 </td>
341 <td class="function_name">
342 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-glyph-infos" title="hb_buffer_get_glyph_infos ()">hb_buffer_get_glyph_infos</a> <span class="c_punctuation">()</span>
343 </td>
344 </tr>
345 <tr>
346 <td class="function_type">
347 <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-position-t" title="hb_glyph_position_t"><span class="returnvalue">hb_glyph_position_t</span></a> *
348 </td>
349 <td class="function_name">
350 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-glyph-positions" title="hb_buffer_get_glyph_positions ()">hb_buffer_get_glyph_positions</a> <span class="c_punctuation">()</span>
351 </td>
352 </tr>
353 <tr>
354 <td class="function_type">
355 <a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
356 </td>
357 <td class="function_name">
358 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-has-positions" title="hb_buffer_has_positions ()">hb_buffer_has_positions</a> <span class="c_punctuation">()</span>
359 </td>
360 </tr>
361 <tr>
362 <td class="function_type">
363 <a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="returnvalue">hb_codepoint_t</span></a>
364 </td>
365 <td class="function_name">
366 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-invisible-glyph" title="hb_buffer_get_invisible_glyph ()">hb_buffer_get_invisible_glyph</a> <span class="c_punctuation">()</span>
367 </td>
368 </tr>
369 <tr>
370 <td class="function_type">
371 <span class="returnvalue">void</span>
372 </td>
373 <td class="function_name">
374 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-invisible-glyph" title="hb_buffer_set_invisible_glyph ()">hb_buffer_set_invisible_glyph</a> <span class="c_punctuation">()</span>
375 </td>
376 </tr>
377 <tr>
378 <td class="function_type">
379 <a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="returnvalue">hb_codepoint_t</span></a>
380 </td>
381 <td class="function_name">
382 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-not-found-glyph" title="hb_buffer_get_not_found_glyph ()">hb_buffer_get_not_found_glyph</a> <span class="c_punctuation">()</span>
383 </td>
384 </tr>
385 <tr>
386 <td class="function_type">
387 <span class="returnvalue">void</span>
388 </td>
389 <td class="function_name">
390 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-not-found-glyph" title="hb_buffer_set_not_found_glyph ()">hb_buffer_set_not_found_glyph</a> <span class="c_punctuation">()</span>
391 </td>
392 </tr>
393 <tr>
394 <td class="function_type">
395 <span class="returnvalue">void</span>
396 </td>
397 <td class="function_name">
398 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-replacement-codepoint" title="hb_buffer_set_replacement_codepoint ()">hb_buffer_set_replacement_codepoint</a> <span class="c_punctuation">()</span>
399 </td>
400 </tr>
401 <tr>
402 <td class="function_type">
403 <a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="returnvalue">hb_codepoint_t</span></a>
404 </td>
405 <td class="function_name">
406 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-replacement-codepoint" title="hb_buffer_get_replacement_codepoint ()">hb_buffer_get_replacement_codepoint</a> <span class="c_punctuation">()</span>
407 </td>
408 </tr>
409 <tr>
410 <td class="function_type">
411 <span class="returnvalue">void</span>
412 </td>
413 <td class="function_name">
414 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-normalize-glyphs" title="hb_buffer_normalize_glyphs ()">hb_buffer_normalize_glyphs</a> <span class="c_punctuation">()</span>
415 </td>
416 </tr>
417 <tr>
418 <td class="function_type">
419 <span class="returnvalue">void</span>
420 </td>
421 <td class="function_name">
422 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-reverse" title="hb_buffer_reverse ()">hb_buffer_reverse</a> <span class="c_punctuation">()</span>
423 </td>
424 </tr>
425 <tr>
426 <td class="function_type">
427 <span class="returnvalue">void</span>
428 </td>
429 <td class="function_name">
430 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-reverse-range" title="hb_buffer_reverse_range ()">hb_buffer_reverse_range</a> <span class="c_punctuation">()</span>
431 </td>
432 </tr>
433 <tr>
434 <td class="function_type">
435 <span class="returnvalue">void</span>
436 </td>
437 <td class="function_name">
438 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-reverse-clusters" title="hb_buffer_reverse_clusters ()">hb_buffer_reverse_clusters</a> <span class="c_punctuation">()</span>
439 </td>
440 </tr>
441 <tr>
442 <td class="function_type">unsigned <span class="returnvalue">int</span>
443 </td>
444 <td class="function_name">
445 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize" title="hb_buffer_serialize ()">hb_buffer_serialize</a> <span class="c_punctuation">()</span>
446 </td>
447 </tr>
448 <tr>
449 <td class="function_type">unsigned <span class="returnvalue">int</span>
450 </td>
451 <td class="function_name">
452 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-glyphs" title="hb_buffer_serialize_glyphs ()">hb_buffer_serialize_glyphs</a> <span class="c_punctuation">()</span>
453 </td>
454 </tr>
455 <tr>
456 <td class="function_type">
457 <a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
458 </td>
459 <td class="function_name">
460 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-deserialize-glyphs" title="hb_buffer_deserialize_glyphs ()">hb_buffer_deserialize_glyphs</a> <span class="c_punctuation">()</span>
461 </td>
462 </tr>
463 <tr>
464 <td class="function_type">unsigned <span class="returnvalue">int</span>
465 </td>
466 <td class="function_name">
467 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-unicode" title="hb_buffer_serialize_unicode ()">hb_buffer_serialize_unicode</a> <span class="c_punctuation">()</span>
468 </td>
469 </tr>
470 <tr>
471 <td class="function_type">
472 <a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
473 </td>
474 <td class="function_name">
475 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-deserialize-unicode" title="hb_buffer_deserialize_unicode ()">hb_buffer_deserialize_unicode</a> <span class="c_punctuation">()</span>
476 </td>
477 </tr>
478 <tr>
479 <td class="function_type">
480 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="returnvalue">hb_buffer_serialize_format_t</span></a>
481 </td>
482 <td class="function_name">
483 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-from-string" title="hb_buffer_serialize_format_from_string ()">hb_buffer_serialize_format_from_string</a> <span class="c_punctuation">()</span>
484 </td>
485 </tr>
486 <tr>
487 <td class="function_type">const <span class="returnvalue">char</span> *
488 </td>
489 <td class="function_name">
490 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-to-string" title="hb_buffer_serialize_format_to_string ()">hb_buffer_serialize_format_to_string</a> <span class="c_punctuation">()</span>
491 </td>
492 </tr>
493 <tr>
494 <td class="function_type">const <span class="returnvalue">char</span> **
495 </td>
496 <td class="function_name">
497 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-list-formats" title="hb_buffer_serialize_list_formats ()">hb_buffer_serialize_list_formats</a> <span class="c_punctuation">()</span>
498 </td>
499 </tr>
500 <tr>
501 <td class="function_type">
502 <a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
503 </td>
504 <td class="function_name">
505 <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-equal" title="hb_segment_properties_equal ()">hb_segment_properties_equal</a> <span class="c_punctuation">()</span>
506 </td>
507 </tr>
508 <tr>
509 <td class="function_type">unsigned <span class="returnvalue">int</span>
510 </td>
511 <td class="function_name">
512 <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-hash" title="hb_segment_properties_hash ()">hb_segment_properties_hash</a> <span class="c_punctuation">()</span>
513 </td>
514 </tr>
515 <tr>
516 <td class="function_type">
517 <span class="returnvalue">void</span>
518 </td>
519 <td class="function_name">
520 <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-overlay" title="hb_segment_properties_overlay ()">hb_segment_properties_overlay</a> <span class="c_punctuation">()</span>
521 </td>
522 </tr>
523 <tr>
524 <td class="function_type">
525 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-diff-flags-t" title="enum hb_buffer_diff_flags_t"><span class="returnvalue">hb_buffer_diff_flags_t</span></a>
526 </td>
527 <td class="function_name">
528 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-diff" title="hb_buffer_diff ()">hb_buffer_diff</a> <span class="c_punctuation">()</span>
529 </td>
530 </tr>
531 <tr>
532 <td class="function_type">
533 <span class="returnvalue">void</span>
534 </td>
535 <td class="function_name">
536 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-message-func" title="hb_buffer_set_message_func ()">hb_buffer_set_message_func</a> <span class="c_punctuation">()</span>
537 </td>
538 </tr>
539 <tr>
540 <td class="function_type">
541 <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-flags-t" title="enum hb_glyph_flags_t"><span class="returnvalue">hb_glyph_flags_t</span></a>
542 </td>
543 <td class="function_name">
544 <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-get-glyph-flags" title="hb_glyph_info_get_glyph_flags ()">hb_glyph_info_get_glyph_flags</a> <span class="c_punctuation">()</span>
545 </td>
546 </tr>
547 <tr>
548 <td class="function_type">
549 <a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
550 </td>
551 <td class="function_name">
552 <span class="c_punctuation">(</span><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-message-func-t" title="hb_buffer_message_func_t ()">*hb_buffer_message_func_t</a><span class="c_punctuation">)</span> <span class="c_punctuation">()</span>
553 </td>
554 </tr>
555 </tbody>
556 </table></div>
557 </div>
558 <div class="refsect1">
559 <a name="harfbuzz-hb-buffer.other"></a><h2>Types and Values</h2>
560 <div class="informaltable"><table class="informaltable" width="100%" border="0">
561 <colgroup>
562 <col width="150px" class="other_proto_type">
563 <col class="other_proto_name">
564 </colgroup>
565 <tbody>
566 <tr>
567 <td class="define_keyword">#define</td>
568 <td class="function_name"><a class="link" href="harfbuzz-hb-buffer.html#HB-SEGMENT-PROPERTIES-DEFAULT:CAPS" title="HB_SEGMENT_PROPERTIES_DEFAULT">HB_SEGMENT_PROPERTIES_DEFAULT</a></td>
569 </tr>
570 <tr>
571 <td class="define_keyword">#define</td>
572 <td class="function_name"><a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-REPLACEMENT-CODEPOINT-DEFAULT:CAPS" title="HB_BUFFER_REPLACEMENT_CODEPOINT_DEFAULT">HB_BUFFER_REPLACEMENT_CODEPOINT_DEFAULT</a></td>
573 </tr>
574 <tr>
575 <td class="typedef_keyword">typedef</td>
576 <td class="function_name"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t">hb_buffer_t</a></td>
577 </tr>
578 <tr>
579 <td class="datatype_keyword"> </td>
580 <td class="function_name"><a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t" title="hb_glyph_info_t">hb_glyph_info_t</a></td>
581 </tr>
582 <tr>
583 <td class="datatype_keyword">enum</td>
584 <td class="function_name"><a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-flags-t" title="enum hb_glyph_flags_t">hb_glyph_flags_t</a></td>
585 </tr>
586 <tr>
587 <td class="datatype_keyword"> </td>
588 <td class="function_name"><a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-position-t" title="hb_glyph_position_t">hb_glyph_position_t</a></td>
589 </tr>
590 <tr>
591 <td class="datatype_keyword">enum</td>
592 <td class="function_name"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-content-type-t" title="enum hb_buffer_content_type_t">hb_buffer_content_type_t</a></td>
593 </tr>
594 <tr>
595 <td class="datatype_keyword">enum</td>
596 <td class="function_name"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-flags-t" title="enum hb_buffer_flags_t">hb_buffer_flags_t</a></td>
597 </tr>
598 <tr>
599 <td class="datatype_keyword">enum</td>
600 <td class="function_name"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-cluster-level-t" title="enum hb_buffer_cluster_level_t">hb_buffer_cluster_level_t</a></td>
601 </tr>
602 <tr>
603 <td class="datatype_keyword"> </td>
604 <td class="function_name"><a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t">hb_segment_properties_t</a></td>
605 </tr>
606 <tr>
607 <td class="datatype_keyword">enum</td>
608 <td class="function_name"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t">hb_buffer_serialize_format_t</a></td>
609 </tr>
610 <tr>
611 <td class="datatype_keyword">enum</td>
612 <td class="function_name"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-flags-t" title="enum hb_buffer_serialize_flags_t">hb_buffer_serialize_flags_t</a></td>
613 </tr>
614 <tr>
615 <td class="datatype_keyword">enum</td>
616 <td class="function_name"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-diff-flags-t" title="enum hb_buffer_diff_flags_t">hb_buffer_diff_flags_t</a></td>
617 </tr>
618 </tbody>
619 </table></div>
620 </div>
621 <div class="refsect1">
622 <a name="harfbuzz-hb-buffer.includes"></a><h2>Includes</h2>
623 <pre class="synopsis">#include &lt;hb.h&gt;
624 </pre>
625 </div>
626 <div class="refsect1">
627 <a name="harfbuzz-hb-buffer.description"></a><h2>Description</h2>
628 <p>Buffers serve a dual role in HarfBuzz; before shaping, they hold
629 the input characters that are passed to <a class="link" href="harfbuzz-hb-shape.html#hb-shape" title="hb_shape ()"><code class="function">hb_shape()</code></a>, and after
630 shaping they hold the output glyphs.</p>
631 </div>
632 <div class="refsect1">
633 <a name="harfbuzz-hb-buffer.functions_details"></a><h2>Functions</h2>
634 <div class="refsect2">
635 <a name="hb-buffer-create"></a><h3>hb_buffer_create ()</h3>
636 <pre class="programlisting"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="returnvalue">hb_buffer_t</span></a> *
637 hb_buffer_create (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
638 <p>Creates a new <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> with all properties to defaults.</p>
639 <p><span class="annotation">[Xconstructor]</span></p>
640 <div class="refsect3">
641 <a name="hb-buffer-create.returns"></a><h4>Returns</h4>
642 <p>A newly allocated <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> with a reference count of 1. The initial
643 reference count should be released with <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-destroy" title="hb_buffer_destroy ()"><code class="function">hb_buffer_destroy()</code></a> when you are done
644 using the <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a>. This function never returns <code class="literal">NULL</code>. If memory cannot
645 be allocated, a special <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> object will be returned on which
646 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-allocation-successful" title="hb_buffer_allocation_successful ()"><code class="function">hb_buffer_allocation_successful()</code></a> returns <code class="literal">false</code>. </p>
647 <p><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p>
648 </div>
649 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
650 </div>
651 <hr>
652 <div class="refsect2">
653 <a name="hb-buffer-create-similar"></a><h3>hb_buffer_create_similar ()</h3>
654 <pre class="programlisting"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="returnvalue">hb_buffer_t</span></a> *
655 hb_buffer_create_similar (<em class="parameter"><code>const <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *src</code></em>);</pre>
656 <p>Creates a new <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a>, similar to <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-create" title="hb_buffer_create ()"><code class="function">hb_buffer_create()</code></a>. The only
657 difference is that the buffer is configured similarly to <em class="parameter"><code>src</code></em>
658 .</p>
659 <div class="refsect3">
660 <a name="hb-buffer-create-similar.parameters"></a><h4>Parameters</h4>
661 <div class="informaltable"><table class="informaltable" width="100%" border="0">
662 <colgroup>
663 <col width="150px" class="parameters_name">
664 <col class="parameters_description">
665 <col width="200px" class="parameters_annotations">
666 </colgroup>
667 <tbody><tr>
668 <td class="parameter_name"><p>src</p></td>
669 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
670 <td class="parameter_annotations"> </td>
671 </tr></tbody>
672 </table></div>
673 </div>
674 <div class="refsect3">
675 <a name="hb-buffer-create-similar.returns"></a><h4>Returns</h4>
676 <p>A newly allocated <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a>, similar to <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-create" title="hb_buffer_create ()"><code class="function">hb_buffer_create()</code></a>. </p>
677 <p><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p>
678 </div>
679 <p class="since">Since: <a class="link" href="api-index-3-3-0.html#api-index-3.3.0">3.3.0</a></p>
680 </div>
681 <hr>
682 <div class="refsect2">
683 <a name="hb-buffer-reference"></a><h3>hb_buffer_reference ()</h3>
684 <pre class="programlisting"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="returnvalue">hb_buffer_t</span></a> *
685 hb_buffer_reference (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
686 <p>Increases the reference count on <em class="parameter"><code>buffer</code></em>
687  by one. This prevents <em class="parameter"><code>buffer</code></em>
688  from
689 being destroyed until a matching call to <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-destroy" title="hb_buffer_destroy ()"><code class="function">hb_buffer_destroy()</code></a> is made.</p>
690 <p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
691 <div class="refsect3">
692 <a name="hb-buffer-reference.parameters"></a><h4>Parameters</h4>
693 <div class="informaltable"><table class="informaltable" width="100%" border="0">
694 <colgroup>
695 <col width="150px" class="parameters_name">
696 <col class="parameters_description">
697 <col width="200px" class="parameters_annotations">
698 </colgroup>
699 <tbody><tr>
700 <td class="parameter_name"><p>buffer</p></td>
701 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
702 <td class="parameter_annotations"> </td>
703 </tr></tbody>
704 </table></div>
705 </div>
706 <div class="refsect3">
707 <a name="hb-buffer-reference.returns"></a><h4>Returns</h4>
708 <p>The referenced <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a>. </p>
709 <p><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p>
710 </div>
711 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
712 </div>
713 <hr>
714 <div class="refsect2">
715 <a name="hb-buffer-get-empty"></a><h3>hb_buffer_get_empty ()</h3>
716 <pre class="programlisting"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="returnvalue">hb_buffer_t</span></a> *
717 hb_buffer_get_empty (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
718 <p>Fetches an empty <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a>.</p>
719 <div class="refsect3">
720 <a name="hb-buffer-get-empty.returns"></a><h4>Returns</h4>
721 <p>The empty buffer. </p>
722 <p><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p>
723 </div>
724 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
725 </div>
726 <hr>
727 <div class="refsect2">
728 <a name="hb-buffer-destroy"></a><h3>hb_buffer_destroy ()</h3>
729 <pre class="programlisting"><span class="returnvalue">void</span>
730 hb_buffer_destroy (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
731 <p>Deallocate the <em class="parameter"><code>buffer</code></em>
732 .
733 Decreases the reference count on <em class="parameter"><code>buffer</code></em>
734  by one. If the result is zero, then
735 <em class="parameter"><code>buffer</code></em>
736  and all associated resources are freed. See <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-reference" title="hb_buffer_reference ()"><code class="function">hb_buffer_reference()</code></a>.</p>
737 <p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
738 <div class="refsect3">
739 <a name="hb-buffer-destroy.parameters"></a><h4>Parameters</h4>
740 <div class="informaltable"><table class="informaltable" width="100%" border="0">
741 <colgroup>
742 <col width="150px" class="parameters_name">
743 <col class="parameters_description">
744 <col width="200px" class="parameters_annotations">
745 </colgroup>
746 <tbody><tr>
747 <td class="parameter_name"><p>buffer</p></td>
748 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
749 <td class="parameter_annotations"> </td>
750 </tr></tbody>
751 </table></div>
752 </div>
753 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
754 </div>
755 <hr>
756 <div class="refsect2">
757 <a name="hb-buffer-reset"></a><h3>hb_buffer_reset ()</h3>
758 <pre class="programlisting"><span class="returnvalue">void</span>
759 hb_buffer_reset (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
760 <p>Resets the buffer to its initial status, as if it was just newly created
761 with <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-create" title="hb_buffer_create ()"><code class="function">hb_buffer_create()</code></a>.</p>
762 <div class="refsect3">
763 <a name="hb-buffer-reset.parameters"></a><h4>Parameters</h4>
764 <div class="informaltable"><table class="informaltable" width="100%" border="0">
765 <colgroup>
766 <col width="150px" class="parameters_name">
767 <col class="parameters_description">
768 <col width="200px" class="parameters_annotations">
769 </colgroup>
770 <tbody><tr>
771 <td class="parameter_name"><p>buffer</p></td>
772 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
773 <td class="parameter_annotations"> </td>
774 </tr></tbody>
775 </table></div>
776 </div>
777 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
778 </div>
779 <hr>
780 <div class="refsect2">
781 <a name="hb-buffer-clear-contents"></a><h3>hb_buffer_clear_contents ()</h3>
782 <pre class="programlisting"><span class="returnvalue">void</span>
783 hb_buffer_clear_contents (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
784 <p>Similar to <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-reset" title="hb_buffer_reset ()"><code class="function">hb_buffer_reset()</code></a>, but does not clear the Unicode functions and
785 the replacement code point.</p>
786 <div class="refsect3">
787 <a name="hb-buffer-clear-contents.parameters"></a><h4>Parameters</h4>
788 <div class="informaltable"><table class="informaltable" width="100%" border="0">
789 <colgroup>
790 <col width="150px" class="parameters_name">
791 <col class="parameters_description">
792 <col width="200px" class="parameters_annotations">
793 </colgroup>
794 <tbody><tr>
795 <td class="parameter_name"><p>buffer</p></td>
796 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
797 <td class="parameter_annotations"> </td>
798 </tr></tbody>
799 </table></div>
800 </div>
801 <p class="since">Since: <a class="link" href="api-index-0-9-11.html#api-index-0.9.11">0.9.11</a></p>
802 </div>
803 <hr>
804 <div class="refsect2">
805 <a name="hb-buffer-pre-allocate"></a><h3>hb_buffer_pre_allocate ()</h3>
806 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
807 hb_buffer_pre_allocate (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
808                         <em class="parameter"><code>unsigned <span class="type">int</span> size</code></em>);</pre>
809 <p>Pre allocates memory for <em class="parameter"><code>buffer</code></em>
810  to fit at least <em class="parameter"><code>size</code></em>
811  number of items.</p>
812 <div class="refsect3">
813 <a name="hb-buffer-pre-allocate.parameters"></a><h4>Parameters</h4>
814 <div class="informaltable"><table class="informaltable" width="100%" border="0">
815 <colgroup>
816 <col width="150px" class="parameters_name">
817 <col class="parameters_description">
818 <col width="200px" class="parameters_annotations">
819 </colgroup>
820 <tbody>
821 <tr>
822 <td class="parameter_name"><p>buffer</p></td>
823 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
824 <td class="parameter_annotations"> </td>
825 </tr>
826 <tr>
827 <td class="parameter_name"><p>size</p></td>
828 <td class="parameter_description"><p>Number of items to pre allocate.</p></td>
829 <td class="parameter_annotations"> </td>
830 </tr>
831 </tbody>
832 </table></div>
833 </div>
834 <div class="refsect3">
835 <a name="hb-buffer-pre-allocate.returns"></a><h4>Returns</h4>
836 <p><code class="literal">true</code> if <em class="parameter"><code>buffer</code></em>
837 memory allocation succeeded, <code class="literal">false</code> otherwise</p>
838 </div>
839 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
840 </div>
841 <hr>
842 <div class="refsect2">
843 <a name="hb-buffer-allocation-successful"></a><h3>hb_buffer_allocation_successful ()</h3>
844 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
845 hb_buffer_allocation_successful (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
846 <p>Check if allocating memory for the buffer succeeded.</p>
847 <div class="refsect3">
848 <a name="hb-buffer-allocation-successful.parameters"></a><h4>Parameters</h4>
849 <div class="informaltable"><table class="informaltable" width="100%" border="0">
850 <colgroup>
851 <col width="150px" class="parameters_name">
852 <col class="parameters_description">
853 <col width="200px" class="parameters_annotations">
854 </colgroup>
855 <tbody><tr>
856 <td class="parameter_name"><p>buffer</p></td>
857 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
858 <td class="parameter_annotations"> </td>
859 </tr></tbody>
860 </table></div>
861 </div>
862 <div class="refsect3">
863 <a name="hb-buffer-allocation-successful.returns"></a><h4>Returns</h4>
864 <p><code class="literal">true</code> if <em class="parameter"><code>buffer</code></em>
865 memory allocation succeeded, <code class="literal">false</code> otherwise.</p>
866 </div>
867 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
868 </div>
869 <hr>
870 <div class="refsect2">
871 <a name="hb-buffer-add"></a><h3>hb_buffer_add ()</h3>
872 <pre class="programlisting"><span class="returnvalue">void</span>
873 hb_buffer_add (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
874                <em class="parameter"><code><a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a> codepoint</code></em>,
875                <em class="parameter"><code>unsigned <span class="type">int</span> cluster</code></em>);</pre>
876 <p>Appends a character with the Unicode value of <em class="parameter"><code>codepoint</code></em>
877  to <em class="parameter"><code>buffer</code></em>
878 , and
879 gives it the initial cluster value of <em class="parameter"><code>cluster</code></em>
880 . Clusters can be any thing
881 the client wants, they are usually used to refer to the index of the
882 character in the input text stream and are output in
883 <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t.cluster"><span class="type">hb_glyph_info_t.cluster</span></a> field.</p>
884 <p>This function does not check the validity of <em class="parameter"><code>codepoint</code></em>
885 , it is up to the
886 caller to ensure it is a valid Unicode code point.</p>
887 <div class="refsect3">
888 <a name="hb-buffer-add.parameters"></a><h4>Parameters</h4>
889 <div class="informaltable"><table class="informaltable" width="100%" border="0">
890 <colgroup>
891 <col width="150px" class="parameters_name">
892 <col class="parameters_description">
893 <col width="200px" class="parameters_annotations">
894 </colgroup>
895 <tbody>
896 <tr>
897 <td class="parameter_name"><p>buffer</p></td>
898 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
899 <td class="parameter_annotations"> </td>
900 </tr>
901 <tr>
902 <td class="parameter_name"><p>codepoint</p></td>
903 <td class="parameter_description"><p>A Unicode code point.</p></td>
904 <td class="parameter_annotations"> </td>
905 </tr>
906 <tr>
907 <td class="parameter_name"><p>cluster</p></td>
908 <td class="parameter_description"><p>The cluster value of <em class="parameter"><code>codepoint</code></em>
909 .</p></td>
910 <td class="parameter_annotations"> </td>
911 </tr>
912 </tbody>
913 </table></div>
914 </div>
915 <p class="since">Since: <a class="link" href="api-index-0-9-7.html#api-index-0.9.7">0.9.7</a></p>
916 </div>
917 <hr>
918 <div class="refsect2">
919 <a name="hb-buffer-add-codepoints"></a><h3>hb_buffer_add_codepoints ()</h3>
920 <pre class="programlisting"><span class="returnvalue">void</span>
921 hb_buffer_add_codepoints (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
922                           <em class="parameter"><code>const <a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a> *text</code></em>,
923                           <em class="parameter"><code><span class="type">int</span> text_length</code></em>,
924                           <em class="parameter"><code>unsigned <span class="type">int</span> item_offset</code></em>,
925                           <em class="parameter"><code><span class="type">int</span> item_length</code></em>);</pre>
926 <p>Appends characters from <em class="parameter"><code>text</code></em>
927  array to <em class="parameter"><code>buffer</code></em>
928 . The <em class="parameter"><code>item_offset</code></em>
929  is the
930 position of the first character from <em class="parameter"><code>text</code></em>
931  that will be appended, and
932 <em class="parameter"><code>item_length</code></em>
933  is the number of character. When shaping part of a larger text
934 (e.g. a run of text from a paragraph), instead of passing just the substring
935 corresponding to the run, it is preferable to pass the whole
936 paragraph and specify the run start and length as <em class="parameter"><code>item_offset</code></em>
937  and
938 <em class="parameter"><code>item_length</code></em>
939 , respectively, to give HarfBuzz the full context to be able,
940 for example, to do cross-run Arabic shaping or properly handle combining
941 marks at stat of run.</p>
942 <p>This function does not check the validity of <em class="parameter"><code>text</code></em>
943 , it is up to the caller
944 to ensure it contains a valid Unicode code points.</p>
945 <div class="refsect3">
946 <a name="hb-buffer-add-codepoints.parameters"></a><h4>Parameters</h4>
947 <div class="informaltable"><table class="informaltable" width="100%" border="0">
948 <colgroup>
949 <col width="150px" class="parameters_name">
950 <col class="parameters_description">
951 <col width="200px" class="parameters_annotations">
952 </colgroup>
953 <tbody>
954 <tr>
955 <td class="parameter_name"><p>buffer</p></td>
956 <td class="parameter_description"><p>a <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> to append characters to.</p></td>
957 <td class="parameter_annotations"> </td>
958 </tr>
959 <tr>
960 <td class="parameter_name"><p>text</p></td>
961 <td class="parameter_description"><p>an array of Unicode code points to append. </p></td>
962 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=text_length]</span></td>
963 </tr>
964 <tr>
965 <td class="parameter_name"><p>text_length</p></td>
966 <td class="parameter_description"><p>the length of the <em class="parameter"><code>text</code></em>
967 , or -1 if it is <code class="literal">NULL</code> terminated.</p></td>
968 <td class="parameter_annotations"> </td>
969 </tr>
970 <tr>
971 <td class="parameter_name"><p>item_offset</p></td>
972 <td class="parameter_description"><p>the offset of the first code point to add to the <em class="parameter"><code>buffer</code></em>
973 .</p></td>
974 <td class="parameter_annotations"> </td>
975 </tr>
976 <tr>
977 <td class="parameter_name"><p>item_length</p></td>
978 <td class="parameter_description"><p>the number of code points to add to the <em class="parameter"><code>buffer</code></em>
979 , or -1 for the
980 end of <em class="parameter"><code>text</code></em>
981 (assuming it is <code class="literal">NULL</code> terminated).</p></td>
982 <td class="parameter_annotations"> </td>
983 </tr>
984 </tbody>
985 </table></div>
986 </div>
987 <p class="since">Since: <a class="link" href="api-index-0-9-31.html#api-index-0.9.31">0.9.31</a></p>
988 </div>
989 <hr>
990 <div class="refsect2">
991 <a name="hb-buffer-add-utf32"></a><h3>hb_buffer_add_utf32 ()</h3>
992 <pre class="programlisting"><span class="returnvalue">void</span>
993 hb_buffer_add_utf32 (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
994                      <em class="parameter"><code>const <span class="type">uint32_t</span> *text</code></em>,
995                      <em class="parameter"><code><span class="type">int</span> text_length</code></em>,
996                      <em class="parameter"><code>unsigned <span class="type">int</span> item_offset</code></em>,
997                      <em class="parameter"><code><span class="type">int</span> item_length</code></em>);</pre>
998 <p>See <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-add-codepoints" title="hb_buffer_add_codepoints ()"><code class="function">hb_buffer_add_codepoints()</code></a>.</p>
999 <p>Replaces invalid UTF-32 characters with the <em class="parameter"><code>buffer</code></em>
1000  replacement code point,
1001 see <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-replacement-codepoint" title="hb_buffer_set_replacement_codepoint ()"><code class="function">hb_buffer_set_replacement_codepoint()</code></a>.</p>
1002 <div class="refsect3">
1003 <a name="hb-buffer-add-utf32.parameters"></a><h4>Parameters</h4>
1004 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1005 <colgroup>
1006 <col width="150px" class="parameters_name">
1007 <col class="parameters_description">
1008 <col width="200px" class="parameters_annotations">
1009 </colgroup>
1010 <tbody>
1011 <tr>
1012 <td class="parameter_name"><p>buffer</p></td>
1013 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1014 <td class="parameter_annotations"> </td>
1015 </tr>
1016 <tr>
1017 <td class="parameter_name"><p>text</p></td>
1018 <td class="parameter_description"><p>An array of UTF-32 characters to append. </p></td>
1019 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=text_length]</span></td>
1020 </tr>
1021 <tr>
1022 <td class="parameter_name"><p>text_length</p></td>
1023 <td class="parameter_description"><p>The length of the <em class="parameter"><code>text</code></em>
1024 , or -1 if it is <code class="literal">NULL</code> terminated</p></td>
1025 <td class="parameter_annotations"> </td>
1026 </tr>
1027 <tr>
1028 <td class="parameter_name"><p>item_offset</p></td>
1029 <td class="parameter_description"><p>The offset of the first character to add to the <em class="parameter"><code>buffer</code></em>
1030 </p></td>
1031 <td class="parameter_annotations"> </td>
1032 </tr>
1033 <tr>
1034 <td class="parameter_name"><p>item_length</p></td>
1035 <td class="parameter_description"><p>The number of characters to add to the <em class="parameter"><code>buffer</code></em>
1036 , or -1 for the
1037 end of <em class="parameter"><code>text</code></em>
1038 (assuming it is <code class="literal">NULL</code> terminated)</p></td>
1039 <td class="parameter_annotations"> </td>
1040 </tr>
1041 </tbody>
1042 </table></div>
1043 </div>
1044 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1045 </div>
1046 <hr>
1047 <div class="refsect2">
1048 <a name="hb-buffer-add-utf16"></a><h3>hb_buffer_add_utf16 ()</h3>
1049 <pre class="programlisting"><span class="returnvalue">void</span>
1050 hb_buffer_add_utf16 (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1051                      <em class="parameter"><code>const <span class="type">uint16_t</span> *text</code></em>,
1052                      <em class="parameter"><code><span class="type">int</span> text_length</code></em>,
1053                      <em class="parameter"><code>unsigned <span class="type">int</span> item_offset</code></em>,
1054                      <em class="parameter"><code><span class="type">int</span> item_length</code></em>);</pre>
1055 <p>See <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-add-codepoints" title="hb_buffer_add_codepoints ()"><code class="function">hb_buffer_add_codepoints()</code></a>.</p>
1056 <p>Replaces invalid UTF-16 characters with the <em class="parameter"><code>buffer</code></em>
1057  replacement code point,
1058 see <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-replacement-codepoint" title="hb_buffer_set_replacement_codepoint ()"><code class="function">hb_buffer_set_replacement_codepoint()</code></a>.</p>
1059 <div class="refsect3">
1060 <a name="hb-buffer-add-utf16.parameters"></a><h4>Parameters</h4>
1061 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1062 <colgroup>
1063 <col width="150px" class="parameters_name">
1064 <col class="parameters_description">
1065 <col width="200px" class="parameters_annotations">
1066 </colgroup>
1067 <tbody>
1068 <tr>
1069 <td class="parameter_name"><p>buffer</p></td>
1070 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1071 <td class="parameter_annotations"> </td>
1072 </tr>
1073 <tr>
1074 <td class="parameter_name"><p>text</p></td>
1075 <td class="parameter_description"><p>An array of UTF-16 characters to append. </p></td>
1076 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=text_length]</span></td>
1077 </tr>
1078 <tr>
1079 <td class="parameter_name"><p>text_length</p></td>
1080 <td class="parameter_description"><p>The length of the <em class="parameter"><code>text</code></em>
1081 , or -1 if it is <code class="literal">NULL</code> terminated</p></td>
1082 <td class="parameter_annotations"> </td>
1083 </tr>
1084 <tr>
1085 <td class="parameter_name"><p>item_offset</p></td>
1086 <td class="parameter_description"><p>The offset of the first character to add to the <em class="parameter"><code>buffer</code></em>
1087 </p></td>
1088 <td class="parameter_annotations"> </td>
1089 </tr>
1090 <tr>
1091 <td class="parameter_name"><p>item_length</p></td>
1092 <td class="parameter_description"><p>The number of characters to add to the <em class="parameter"><code>buffer</code></em>
1093 , or -1 for the
1094 end of <em class="parameter"><code>text</code></em>
1095 (assuming it is <code class="literal">NULL</code> terminated)</p></td>
1096 <td class="parameter_annotations"> </td>
1097 </tr>
1098 </tbody>
1099 </table></div>
1100 </div>
1101 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1102 </div>
1103 <hr>
1104 <div class="refsect2">
1105 <a name="hb-buffer-add-utf8"></a><h3>hb_buffer_add_utf8 ()</h3>
1106 <pre class="programlisting"><span class="returnvalue">void</span>
1107 hb_buffer_add_utf8 (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1108                     <em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
1109                     <em class="parameter"><code><span class="type">int</span> text_length</code></em>,
1110                     <em class="parameter"><code>unsigned <span class="type">int</span> item_offset</code></em>,
1111                     <em class="parameter"><code><span class="type">int</span> item_length</code></em>);</pre>
1112 <p>See <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-add-codepoints" title="hb_buffer_add_codepoints ()"><code class="function">hb_buffer_add_codepoints()</code></a>.</p>
1113 <p>Replaces invalid UTF-8 characters with the <em class="parameter"><code>buffer</code></em>
1114  replacement code point,
1115 see <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-replacement-codepoint" title="hb_buffer_set_replacement_codepoint ()"><code class="function">hb_buffer_set_replacement_codepoint()</code></a>.</p>
1116 <div class="refsect3">
1117 <a name="hb-buffer-add-utf8.parameters"></a><h4>Parameters</h4>
1118 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1119 <colgroup>
1120 <col width="150px" class="parameters_name">
1121 <col class="parameters_description">
1122 <col width="200px" class="parameters_annotations">
1123 </colgroup>
1124 <tbody>
1125 <tr>
1126 <td class="parameter_name"><p>buffer</p></td>
1127 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1128 <td class="parameter_annotations"> </td>
1129 </tr>
1130 <tr>
1131 <td class="parameter_name"><p>text</p></td>
1132 <td class="parameter_description"><p>An array of UTF-8
1133 characters to append. </p></td>
1134 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=text_length][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> uint8_t]</span></td>
1135 </tr>
1136 <tr>
1137 <td class="parameter_name"><p>text_length</p></td>
1138 <td class="parameter_description"><p>The length of the <em class="parameter"><code>text</code></em>
1139 , or -1 if it is <code class="literal">NULL</code> terminated.</p></td>
1140 <td class="parameter_annotations"> </td>
1141 </tr>
1142 <tr>
1143 <td class="parameter_name"><p>item_offset</p></td>
1144 <td class="parameter_description"><p>The offset of the first character to add to the <em class="parameter"><code>buffer</code></em>
1145 .</p></td>
1146 <td class="parameter_annotations"> </td>
1147 </tr>
1148 <tr>
1149 <td class="parameter_name"><p>item_length</p></td>
1150 <td class="parameter_description"><p>The number of characters to add to the <em class="parameter"><code>buffer</code></em>
1151 , or -1 for the
1152 end of <em class="parameter"><code>text</code></em>
1153 (assuming it is <code class="literal">NULL</code> terminated).</p></td>
1154 <td class="parameter_annotations"> </td>
1155 </tr>
1156 </tbody>
1157 </table></div>
1158 </div>
1159 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1160 </div>
1161 <hr>
1162 <div class="refsect2">
1163 <a name="hb-buffer-add-latin1"></a><h3>hb_buffer_add_latin1 ()</h3>
1164 <pre class="programlisting"><span class="returnvalue">void</span>
1165 hb_buffer_add_latin1 (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1166                       <em class="parameter"><code>const <span class="type">uint8_t</span> *text</code></em>,
1167                       <em class="parameter"><code><span class="type">int</span> text_length</code></em>,
1168                       <em class="parameter"><code>unsigned <span class="type">int</span> item_offset</code></em>,
1169                       <em class="parameter"><code><span class="type">int</span> item_length</code></em>);</pre>
1170 <p>Similar to <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-add-codepoints" title="hb_buffer_add_codepoints ()"><code class="function">hb_buffer_add_codepoints()</code></a>, but allows only access to first 256
1171 Unicode code points that can fit in 8-bit strings.</p>
1172 <div class="note">Has nothing to do with non-Unicode Latin-1 encoding.</div>
1173 <div class="refsect3">
1174 <a name="hb-buffer-add-latin1.parameters"></a><h4>Parameters</h4>
1175 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1176 <colgroup>
1177 <col width="150px" class="parameters_name">
1178 <col class="parameters_description">
1179 <col width="200px" class="parameters_annotations">
1180 </colgroup>
1181 <tbody>
1182 <tr>
1183 <td class="parameter_name"><p>buffer</p></td>
1184 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1185 <td class="parameter_annotations"> </td>
1186 </tr>
1187 <tr>
1188 <td class="parameter_name"><p>text</p></td>
1189 <td class="parameter_description"><p>an array of UTF-8
1190 characters to append. </p></td>
1191 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=text_length][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> uint8_t]</span></td>
1192 </tr>
1193 <tr>
1194 <td class="parameter_name"><p>text_length</p></td>
1195 <td class="parameter_description"><p>the length of the <em class="parameter"><code>text</code></em>
1196 , or -1 if it is <code class="literal">NULL</code> terminated</p></td>
1197 <td class="parameter_annotations"> </td>
1198 </tr>
1199 <tr>
1200 <td class="parameter_name"><p>item_offset</p></td>
1201 <td class="parameter_description"><p>the offset of the first character to add to the <em class="parameter"><code>buffer</code></em>
1202 </p></td>
1203 <td class="parameter_annotations"> </td>
1204 </tr>
1205 <tr>
1206 <td class="parameter_name"><p>item_length</p></td>
1207 <td class="parameter_description"><p>the number of characters to add to the <em class="parameter"><code>buffer</code></em>
1208 , or -1 for the
1209 end of <em class="parameter"><code>text</code></em>
1210 (assuming it is <code class="literal">NULL</code> terminated)</p></td>
1211 <td class="parameter_annotations"> </td>
1212 </tr>
1213 </tbody>
1214 </table></div>
1215 </div>
1216 <p class="since">Since: <a class="link" href="api-index-0-9-39.html#api-index-0.9.39">0.9.39</a></p>
1217 </div>
1218 <hr>
1219 <div class="refsect2">
1220 <a name="hb-buffer-append"></a><h3>hb_buffer_append ()</h3>
1221 <pre class="programlisting"><span class="returnvalue">void</span>
1222 hb_buffer_append (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1223                   <em class="parameter"><code>const <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *source</code></em>,
1224                   <em class="parameter"><code>unsigned <span class="type">int</span> start</code></em>,
1225                   <em class="parameter"><code>unsigned <span class="type">int</span> end</code></em>);</pre>
1226 <p>Append (part of) contents of another buffer to this buffer.</p>
1227 <div class="refsect3">
1228 <a name="hb-buffer-append.parameters"></a><h4>Parameters</h4>
1229 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1230 <colgroup>
1231 <col width="150px" class="parameters_name">
1232 <col class="parameters_description">
1233 <col width="200px" class="parameters_annotations">
1234 </colgroup>
1235 <tbody>
1236 <tr>
1237 <td class="parameter_name"><p>buffer</p></td>
1238 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1239 <td class="parameter_annotations"> </td>
1240 </tr>
1241 <tr>
1242 <td class="parameter_name"><p>source</p></td>
1243 <td class="parameter_description"><p>source <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1244 <td class="parameter_annotations"> </td>
1245 </tr>
1246 <tr>
1247 <td class="parameter_name"><p>start</p></td>
1248 <td class="parameter_description"><p>start index into source buffer to copy.  Use 0 to copy from start of buffer.</p></td>
1249 <td class="parameter_annotations"> </td>
1250 </tr>
1251 <tr>
1252 <td class="parameter_name"><p>end</p></td>
1253 <td class="parameter_description"><p>end index into source buffer to copy.  Use <em class="parameter"><code>HB_FEATURE_GLOBAL_END</code></em>
1254 to copy to end of buffer.</p></td>
1255 <td class="parameter_annotations"> </td>
1256 </tr>
1257 </tbody>
1258 </table></div>
1259 </div>
1260 <p class="since">Since: <a class="link" href="api-index-1-5-0.html#api-index-1.5.0">1.5.0</a></p>
1261 </div>
1262 <hr>
1263 <div class="refsect2">
1264 <a name="hb-buffer-set-content-type"></a><h3>hb_buffer_set_content_type ()</h3>
1265 <pre class="programlisting"><span class="returnvalue">void</span>
1266 hb_buffer_set_content_type (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1267                             <em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-content-type-t" title="enum hb_buffer_content_type_t"><span class="type">hb_buffer_content_type_t</span></a> content_type</code></em>);</pre>
1268 <p>Sets the type of <em class="parameter"><code>buffer</code></em>
1269  contents. Buffers are either empty, contain
1270 characters (before shaping), or contain glyphs (the result of shaping).</p>
1271 <div class="refsect3">
1272 <a name="hb-buffer-set-content-type.parameters"></a><h4>Parameters</h4>
1273 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1274 <colgroup>
1275 <col width="150px" class="parameters_name">
1276 <col class="parameters_description">
1277 <col width="200px" class="parameters_annotations">
1278 </colgroup>
1279 <tbody>
1280 <tr>
1281 <td class="parameter_name"><p>buffer</p></td>
1282 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1283 <td class="parameter_annotations"> </td>
1284 </tr>
1285 <tr>
1286 <td class="parameter_name"><p>content_type</p></td>
1287 <td class="parameter_description"><p>The type of buffer contents to set</p></td>
1288 <td class="parameter_annotations"> </td>
1289 </tr>
1290 </tbody>
1291 </table></div>
1292 </div>
1293 <p class="since">Since: <a class="link" href="api-index-0-9-5.html#api-index-0.9.5">0.9.5</a></p>
1294 </div>
1295 <hr>
1296 <div class="refsect2">
1297 <a name="hb-buffer-get-content-type"></a><h3>hb_buffer_get_content_type ()</h3>
1298 <pre class="programlisting"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-content-type-t" title="enum hb_buffer_content_type_t"><span class="returnvalue">hb_buffer_content_type_t</span></a>
1299 hb_buffer_get_content_type (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
1300 <p>Fetches the type of <em class="parameter"><code>buffer</code></em>
1301  contents. Buffers are either empty, contain
1302 characters (before shaping), or contain glyphs (the result of shaping).</p>
1303 <div class="refsect3">
1304 <a name="hb-buffer-get-content-type.parameters"></a><h4>Parameters</h4>
1305 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1306 <colgroup>
1307 <col width="150px" class="parameters_name">
1308 <col class="parameters_description">
1309 <col width="200px" class="parameters_annotations">
1310 </colgroup>
1311 <tbody><tr>
1312 <td class="parameter_name"><p>buffer</p></td>
1313 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1314 <td class="parameter_annotations"> </td>
1315 </tr></tbody>
1316 </table></div>
1317 </div>
1318 <div class="refsect3">
1319 <a name="hb-buffer-get-content-type.returns"></a><h4>Returns</h4>
1320 <p>The type of <em class="parameter"><code>buffer</code></em>
1321 contents</p>
1322 </div>
1323 <p class="since">Since: <a class="link" href="api-index-0-9-5.html#api-index-0.9.5">0.9.5</a></p>
1324 </div>
1325 <hr>
1326 <div class="refsect2">
1327 <a name="hb-buffer-set-direction"></a><h3>hb_buffer_set_direction ()</h3>
1328 <pre class="programlisting"><span class="returnvalue">void</span>
1329 hb_buffer_set_direction (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1330                          <em class="parameter"><code><a class="link" href="harfbuzz-hb-common.html#hb-direction-t" title="enum hb_direction_t"><span class="type">hb_direction_t</span></a> direction</code></em>);</pre>
1331 <p>Set the text flow direction of the buffer. No shaping can happen without
1332 setting <em class="parameter"><code>buffer</code></em>
1333  direction, and it controls the visual direction for the
1334 output glyphs; for RTL direction the glyphs will be reversed. Many layout
1335 features depend on the proper setting of the direction, for example,
1336 reversing RTL text before shaping, then shaping with LTR direction is not
1337 the same as keeping the text in logical order and shaping with RTL
1338 direction.</p>
1339 <div class="refsect3">
1340 <a name="hb-buffer-set-direction.parameters"></a><h4>Parameters</h4>
1341 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1342 <colgroup>
1343 <col width="150px" class="parameters_name">
1344 <col class="parameters_description">
1345 <col width="200px" class="parameters_annotations">
1346 </colgroup>
1347 <tbody>
1348 <tr>
1349 <td class="parameter_name"><p>buffer</p></td>
1350 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1351 <td class="parameter_annotations"> </td>
1352 </tr>
1353 <tr>
1354 <td class="parameter_name"><p>direction</p></td>
1355 <td class="parameter_description"><p>the <a class="link" href="harfbuzz-hb-common.html#hb-direction-t" title="enum hb_direction_t"><span class="type">hb_direction_t</span></a> of the <em class="parameter"><code>buffer</code></em>
1356 </p></td>
1357 <td class="parameter_annotations"> </td>
1358 </tr>
1359 </tbody>
1360 </table></div>
1361 </div>
1362 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1363 </div>
1364 <hr>
1365 <div class="refsect2">
1366 <a name="hb-buffer-get-direction"></a><h3>hb_buffer_get_direction ()</h3>
1367 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-direction-t" title="enum hb_direction_t"><span class="returnvalue">hb_direction_t</span></a>
1368 hb_buffer_get_direction (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
1369 <p>See <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-direction" title="hb_buffer_set_direction ()"><code class="function">hb_buffer_set_direction()</code></a></p>
1370 <div class="refsect3">
1371 <a name="hb-buffer-get-direction.parameters"></a><h4>Parameters</h4>
1372 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1373 <colgroup>
1374 <col width="150px" class="parameters_name">
1375 <col class="parameters_description">
1376 <col width="200px" class="parameters_annotations">
1377 </colgroup>
1378 <tbody><tr>
1379 <td class="parameter_name"><p>buffer</p></td>
1380 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1381 <td class="parameter_annotations"> </td>
1382 </tr></tbody>
1383 </table></div>
1384 </div>
1385 <div class="refsect3">
1386 <a name="hb-buffer-get-direction.returns"></a><h4>Returns</h4>
1387 <p>The direction of the <em class="parameter"><code>buffer</code></em>
1388 .</p>
1389 </div>
1390 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1391 </div>
1392 <hr>
1393 <div class="refsect2">
1394 <a name="hb-buffer-set-script"></a><h3>hb_buffer_set_script ()</h3>
1395 <pre class="programlisting"><span class="returnvalue">void</span>
1396 hb_buffer_set_script (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1397                       <em class="parameter"><code><a class="link" href="harfbuzz-hb-common.html#hb-script-t" title="enum hb_script_t"><span class="type">hb_script_t</span></a> script</code></em>);</pre>
1398 <p>Sets the script of <em class="parameter"><code>buffer</code></em>
1399  to <em class="parameter"><code>script</code></em>
1400 .</p>
1401 <p>Script is crucial for choosing the proper shaping behaviour for scripts that
1402 require it (e.g. Arabic) and the which OpenType features defined in the font
1403 to be applied.</p>
1404 <p>You can pass one of the predefined <a class="link" href="harfbuzz-hb-common.html#hb-script-t" title="enum hb_script_t"><span class="type">hb_script_t</span></a> values, or use
1405 <a class="link" href="harfbuzz-hb-common.html#hb-script-from-string" title="hb_script_from_string ()"><code class="function">hb_script_from_string()</code></a> or <a class="link" href="harfbuzz-hb-common.html#hb-script-from-iso15924-tag" title="hb_script_from_iso15924_tag ()"><code class="function">hb_script_from_iso15924_tag()</code></a> to get the
1406 corresponding script from an ISO 15924 script tag.</p>
1407 <div class="refsect3">
1408 <a name="hb-buffer-set-script.parameters"></a><h4>Parameters</h4>
1409 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1410 <colgroup>
1411 <col width="150px" class="parameters_name">
1412 <col class="parameters_description">
1413 <col width="200px" class="parameters_annotations">
1414 </colgroup>
1415 <tbody>
1416 <tr>
1417 <td class="parameter_name"><p>buffer</p></td>
1418 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1419 <td class="parameter_annotations"> </td>
1420 </tr>
1421 <tr>
1422 <td class="parameter_name"><p>script</p></td>
1423 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-common.html#hb-script-t" title="enum hb_script_t"><span class="type">hb_script_t</span></a> to set.</p></td>
1424 <td class="parameter_annotations"> </td>
1425 </tr>
1426 </tbody>
1427 </table></div>
1428 </div>
1429 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1430 </div>
1431 <hr>
1432 <div class="refsect2">
1433 <a name="hb-buffer-get-script"></a><h3>hb_buffer_get_script ()</h3>
1434 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-script-t" title="enum hb_script_t"><span class="returnvalue">hb_script_t</span></a>
1435 hb_buffer_get_script (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
1436 <p>Fetches the script of <em class="parameter"><code>buffer</code></em>
1437 .</p>
1438 <div class="refsect3">
1439 <a name="hb-buffer-get-script.parameters"></a><h4>Parameters</h4>
1440 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1441 <colgroup>
1442 <col width="150px" class="parameters_name">
1443 <col class="parameters_description">
1444 <col width="200px" class="parameters_annotations">
1445 </colgroup>
1446 <tbody><tr>
1447 <td class="parameter_name"><p>buffer</p></td>
1448 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1449 <td class="parameter_annotations"> </td>
1450 </tr></tbody>
1451 </table></div>
1452 </div>
1453 <div class="refsect3">
1454 <a name="hb-buffer-get-script.returns"></a><h4>Returns</h4>
1455 <p>The <a class="link" href="harfbuzz-hb-common.html#hb-script-t" title="enum hb_script_t"><span class="type">hb_script_t</span></a> of the <em class="parameter"><code>buffer</code></em>
1456 </p>
1457 </div>
1458 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1459 </div>
1460 <hr>
1461 <div class="refsect2">
1462 <a name="hb-buffer-set-language"></a><h3>hb_buffer_set_language ()</h3>
1463 <pre class="programlisting"><span class="returnvalue">void</span>
1464 hb_buffer_set_language (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1465                         <em class="parameter"><code><a class="link" href="harfbuzz-hb-common.html#hb-language-t" title="hb_language_t"><span class="type">hb_language_t</span></a> language</code></em>);</pre>
1466 <p>Sets the language of <em class="parameter"><code>buffer</code></em>
1467  to <em class="parameter"><code>language</code></em>
1468 .</p>
1469 <p>Languages are crucial for selecting which OpenType feature to apply to the
1470 buffer which can result in applying language-specific behaviour. Languages
1471 are orthogonal to the scripts, and though they are related, they are
1472 different concepts and should not be confused with each other.</p>
1473 <p>Use <a class="link" href="harfbuzz-hb-common.html#hb-language-from-string" title="hb_language_from_string ()"><code class="function">hb_language_from_string()</code></a> to convert from BCP 47 language tags to
1474 <a class="link" href="harfbuzz-hb-common.html#hb-language-t" title="hb_language_t"><span class="type">hb_language_t</span></a>.</p>
1475 <div class="refsect3">
1476 <a name="hb-buffer-set-language.parameters"></a><h4>Parameters</h4>
1477 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1478 <colgroup>
1479 <col width="150px" class="parameters_name">
1480 <col class="parameters_description">
1481 <col width="200px" class="parameters_annotations">
1482 </colgroup>
1483 <tbody>
1484 <tr>
1485 <td class="parameter_name"><p>buffer</p></td>
1486 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1487 <td class="parameter_annotations"> </td>
1488 </tr>
1489 <tr>
1490 <td class="parameter_name"><p>language</p></td>
1491 <td class="parameter_description"><p>An hb_language_t to set</p></td>
1492 <td class="parameter_annotations"> </td>
1493 </tr>
1494 </tbody>
1495 </table></div>
1496 </div>
1497 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1498 </div>
1499 <hr>
1500 <div class="refsect2">
1501 <a name="hb-buffer-get-language"></a><h3>hb_buffer_get_language ()</h3>
1502 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-language-t" title="hb_language_t"><span class="returnvalue">hb_language_t</span></a>
1503 hb_buffer_get_language (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
1504 <p>See <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-language" title="hb_buffer_set_language ()"><code class="function">hb_buffer_set_language()</code></a>.</p>
1505 <div class="refsect3">
1506 <a name="hb-buffer-get-language.parameters"></a><h4>Parameters</h4>
1507 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1508 <colgroup>
1509 <col width="150px" class="parameters_name">
1510 <col class="parameters_description">
1511 <col width="200px" class="parameters_annotations">
1512 </colgroup>
1513 <tbody><tr>
1514 <td class="parameter_name"><p>buffer</p></td>
1515 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1516 <td class="parameter_annotations"> </td>
1517 </tr></tbody>
1518 </table></div>
1519 </div>
1520 <div class="refsect3">
1521 <a name="hb-buffer-get-language.returns"></a><h4>Returns</h4>
1522 <p>The <a class="link" href="harfbuzz-hb-common.html#hb-language-t" title="hb_language_t"><span class="type">hb_language_t</span></a> of the buffer. Must not be freed by the caller. </p>
1523 <p><span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span></p>
1524 </div>
1525 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1526 </div>
1527 <hr>
1528 <div class="refsect2">
1529 <a name="hb-buffer-set-flags"></a><h3>hb_buffer_set_flags ()</h3>
1530 <pre class="programlisting"><span class="returnvalue">void</span>
1531 hb_buffer_set_flags (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1532                      <em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-flags-t" title="enum hb_buffer_flags_t"><span class="type">hb_buffer_flags_t</span></a> flags</code></em>);</pre>
1533 <p>Sets <em class="parameter"><code>buffer</code></em>
1534  flags to <em class="parameter"><code>flags</code></em>
1535 . See <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-flags-t" title="enum hb_buffer_flags_t"><span class="type">hb_buffer_flags_t</span></a>.</p>
1536 <div class="refsect3">
1537 <a name="hb-buffer-set-flags.parameters"></a><h4>Parameters</h4>
1538 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1539 <colgroup>
1540 <col width="150px" class="parameters_name">
1541 <col class="parameters_description">
1542 <col width="200px" class="parameters_annotations">
1543 </colgroup>
1544 <tbody>
1545 <tr>
1546 <td class="parameter_name"><p>buffer</p></td>
1547 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1548 <td class="parameter_annotations"> </td>
1549 </tr>
1550 <tr>
1551 <td class="parameter_name"><p>flags</p></td>
1552 <td class="parameter_description"><p>The buffer flags to set</p></td>
1553 <td class="parameter_annotations"> </td>
1554 </tr>
1555 </tbody>
1556 </table></div>
1557 </div>
1558 <p class="since">Since: <a class="link" href="api-index-0-9-7.html#api-index-0.9.7">0.9.7</a></p>
1559 </div>
1560 <hr>
1561 <div class="refsect2">
1562 <a name="hb-buffer-get-flags"></a><h3>hb_buffer_get_flags ()</h3>
1563 <pre class="programlisting"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-flags-t" title="enum hb_buffer_flags_t"><span class="returnvalue">hb_buffer_flags_t</span></a>
1564 hb_buffer_get_flags (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
1565 <p>Fetches the <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-flags-t" title="enum hb_buffer_flags_t"><span class="type">hb_buffer_flags_t</span></a> of <em class="parameter"><code>buffer</code></em>
1566 .</p>
1567 <div class="refsect3">
1568 <a name="hb-buffer-get-flags.parameters"></a><h4>Parameters</h4>
1569 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1570 <colgroup>
1571 <col width="150px" class="parameters_name">
1572 <col class="parameters_description">
1573 <col width="200px" class="parameters_annotations">
1574 </colgroup>
1575 <tbody><tr>
1576 <td class="parameter_name"><p>buffer</p></td>
1577 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1578 <td class="parameter_annotations"> </td>
1579 </tr></tbody>
1580 </table></div>
1581 </div>
1582 <div class="refsect3">
1583 <a name="hb-buffer-get-flags.returns"></a><h4>Returns</h4>
1584 <p>The <em class="parameter"><code>buffer</code></em>
1585 flags</p>
1586 </div>
1587 <p class="since">Since: <a class="link" href="api-index-0-9-7.html#api-index-0.9.7">0.9.7</a></p>
1588 </div>
1589 <hr>
1590 <div class="refsect2">
1591 <a name="hb-buffer-set-cluster-level"></a><h3>hb_buffer_set_cluster_level ()</h3>
1592 <pre class="programlisting"><span class="returnvalue">void</span>
1593 hb_buffer_set_cluster_level (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1594                              <em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-cluster-level-t" title="enum hb_buffer_cluster_level_t"><span class="type">hb_buffer_cluster_level_t</span></a> cluster_level</code></em>);</pre>
1595 <p>Sets the cluster level of a buffer. The <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-cluster-level-t" title="enum hb_buffer_cluster_level_t"><span class="type">hb_buffer_cluster_level_t</span></a>
1596 dictates one aspect of how HarfBuzz will treat non-base characters 
1597 during shaping.</p>
1598 <div class="refsect3">
1599 <a name="hb-buffer-set-cluster-level.parameters"></a><h4>Parameters</h4>
1600 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1601 <colgroup>
1602 <col width="150px" class="parameters_name">
1603 <col class="parameters_description">
1604 <col width="200px" class="parameters_annotations">
1605 </colgroup>
1606 <tbody>
1607 <tr>
1608 <td class="parameter_name"><p>buffer</p></td>
1609 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1610 <td class="parameter_annotations"> </td>
1611 </tr>
1612 <tr>
1613 <td class="parameter_name"><p>cluster_level</p></td>
1614 <td class="parameter_description"><p>The cluster level to set on the buffer</p></td>
1615 <td class="parameter_annotations"> </td>
1616 </tr>
1617 </tbody>
1618 </table></div>
1619 </div>
1620 <p class="since">Since: <a class="link" href="api-index-0-9-42.html#api-index-0.9.42">0.9.42</a></p>
1621 </div>
1622 <hr>
1623 <div class="refsect2">
1624 <a name="hb-buffer-get-cluster-level"></a><h3>hb_buffer_get_cluster_level ()</h3>
1625 <pre class="programlisting"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-cluster-level-t" title="enum hb_buffer_cluster_level_t"><span class="returnvalue">hb_buffer_cluster_level_t</span></a>
1626 hb_buffer_get_cluster_level (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
1627 <p>Fetches the cluster level of a buffer. The <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-cluster-level-t" title="enum hb_buffer_cluster_level_t"><span class="type">hb_buffer_cluster_level_t</span></a>
1628 dictates one aspect of how HarfBuzz will treat non-base characters 
1629 during shaping.</p>
1630 <div class="refsect3">
1631 <a name="hb-buffer-get-cluster-level.parameters"></a><h4>Parameters</h4>
1632 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1633 <colgroup>
1634 <col width="150px" class="parameters_name">
1635 <col class="parameters_description">
1636 <col width="200px" class="parameters_annotations">
1637 </colgroup>
1638 <tbody><tr>
1639 <td class="parameter_name"><p>buffer</p></td>
1640 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1641 <td class="parameter_annotations"> </td>
1642 </tr></tbody>
1643 </table></div>
1644 </div>
1645 <div class="refsect3">
1646 <a name="hb-buffer-get-cluster-level.returns"></a><h4>Returns</h4>
1647 <p> The cluster level of <em class="parameter"><code>buffer</code></em>
1648 </p>
1649 </div>
1650 <p class="since">Since: <a class="link" href="api-index-0-9-42.html#api-index-0.9.42">0.9.42</a></p>
1651 </div>
1652 <hr>
1653 <div class="refsect2">
1654 <a name="hb-buffer-set-length"></a><h3>hb_buffer_set_length ()</h3>
1655 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
1656 hb_buffer_set_length (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1657                       <em class="parameter"><code>unsigned <span class="type">int</span> length</code></em>);</pre>
1658 <p>Similar to <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-pre-allocate" title="hb_buffer_pre_allocate ()"><code class="function">hb_buffer_pre_allocate()</code></a>, but clears any new items added at the
1659 end.</p>
1660 <div class="refsect3">
1661 <a name="hb-buffer-set-length.parameters"></a><h4>Parameters</h4>
1662 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1663 <colgroup>
1664 <col width="150px" class="parameters_name">
1665 <col class="parameters_description">
1666 <col width="200px" class="parameters_annotations">
1667 </colgroup>
1668 <tbody>
1669 <tr>
1670 <td class="parameter_name"><p>buffer</p></td>
1671 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1672 <td class="parameter_annotations"> </td>
1673 </tr>
1674 <tr>
1675 <td class="parameter_name"><p>length</p></td>
1676 <td class="parameter_description"><p>The new length of <em class="parameter"><code>buffer</code></em>
1677 </p></td>
1678 <td class="parameter_annotations"> </td>
1679 </tr>
1680 </tbody>
1681 </table></div>
1682 </div>
1683 <div class="refsect3">
1684 <a name="hb-buffer-set-length.returns"></a><h4>Returns</h4>
1685 <p><code class="literal">true</code> if <em class="parameter"><code>buffer</code></em>
1686 memory allocation succeeded, <code class="literal">false</code> otherwise.</p>
1687 </div>
1688 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1689 </div>
1690 <hr>
1691 <div class="refsect2">
1692 <a name="hb-buffer-get-length"></a><h3>hb_buffer_get_length ()</h3>
1693 <pre class="programlisting">unsigned <span class="returnvalue">int</span>
1694 hb_buffer_get_length (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
1695 <p>Returns the number of items in the buffer.</p>
1696 <div class="refsect3">
1697 <a name="hb-buffer-get-length.parameters"></a><h4>Parameters</h4>
1698 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1699 <colgroup>
1700 <col width="150px" class="parameters_name">
1701 <col class="parameters_description">
1702 <col width="200px" class="parameters_annotations">
1703 </colgroup>
1704 <tbody><tr>
1705 <td class="parameter_name"><p>buffer</p></td>
1706 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1707 <td class="parameter_annotations"> </td>
1708 </tr></tbody>
1709 </table></div>
1710 </div>
1711 <div class="refsect3">
1712 <a name="hb-buffer-get-length.returns"></a><h4>Returns</h4>
1713 <p>The <em class="parameter"><code>buffer</code></em>
1714 length.
1715 The value valid as long as buffer has not been modified.</p>
1716 </div>
1717 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1718 </div>
1719 <hr>
1720 <div class="refsect2">
1721 <a name="hb-buffer-set-segment-properties"></a><h3>hb_buffer_set_segment_properties ()</h3>
1722 <pre class="programlisting"><span class="returnvalue">void</span>
1723 hb_buffer_set_segment_properties (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1724                                   <em class="parameter"><code>const <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> *props</code></em>);</pre>
1725 <p>Sets the segment properties of the buffer, a shortcut for calling
1726 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-direction" title="hb_buffer_set_direction ()"><code class="function">hb_buffer_set_direction()</code></a>, <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-script" title="hb_buffer_set_script ()"><code class="function">hb_buffer_set_script()</code></a> and
1727 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-language" title="hb_buffer_set_language ()"><code class="function">hb_buffer_set_language()</code></a> individually.</p>
1728 <div class="refsect3">
1729 <a name="hb-buffer-set-segment-properties.parameters"></a><h4>Parameters</h4>
1730 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1731 <colgroup>
1732 <col width="150px" class="parameters_name">
1733 <col class="parameters_description">
1734 <col width="200px" class="parameters_annotations">
1735 </colgroup>
1736 <tbody>
1737 <tr>
1738 <td class="parameter_name"><p>buffer</p></td>
1739 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1740 <td class="parameter_annotations"> </td>
1741 </tr>
1742 <tr>
1743 <td class="parameter_name"><p>props</p></td>
1744 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> to use</p></td>
1745 <td class="parameter_annotations"> </td>
1746 </tr>
1747 </tbody>
1748 </table></div>
1749 </div>
1750 <p class="since">Since: <a class="link" href="api-index-0-9-7.html#api-index-0.9.7">0.9.7</a></p>
1751 </div>
1752 <hr>
1753 <div class="refsect2">
1754 <a name="hb-buffer-get-segment-properties"></a><h3>hb_buffer_get_segment_properties ()</h3>
1755 <pre class="programlisting"><span class="returnvalue">void</span>
1756 hb_buffer_get_segment_properties (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1757                                   <em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> *props</code></em>);</pre>
1758 <p>Sets <em class="parameter"><code>props</code></em>
1759  to the <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> of <em class="parameter"><code>buffer</code></em>
1760 .</p>
1761 <div class="refsect3">
1762 <a name="hb-buffer-get-segment-properties.parameters"></a><h4>Parameters</h4>
1763 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1764 <colgroup>
1765 <col width="150px" class="parameters_name">
1766 <col class="parameters_description">
1767 <col width="200px" class="parameters_annotations">
1768 </colgroup>
1769 <tbody>
1770 <tr>
1771 <td class="parameter_name"><p>buffer</p></td>
1772 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1773 <td class="parameter_annotations"> </td>
1774 </tr>
1775 <tr>
1776 <td class="parameter_name"><p>props</p></td>
1777 <td class="parameter_description"><p>The output <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a>. </p></td>
1778 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span></td>
1779 </tr>
1780 </tbody>
1781 </table></div>
1782 </div>
1783 <p class="since">Since: <a class="link" href="api-index-0-9-7.html#api-index-0.9.7">0.9.7</a></p>
1784 </div>
1785 <hr>
1786 <div class="refsect2">
1787 <a name="hb-buffer-guess-segment-properties"></a><h3>hb_buffer_guess_segment_properties ()</h3>
1788 <pre class="programlisting"><span class="returnvalue">void</span>
1789 hb_buffer_guess_segment_properties (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
1790 <p>Sets unset buffer segment properties based on buffer Unicode
1791 contents.  If buffer is not empty, it must have content type
1792 <a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-CONTENT-TYPE-UNICODE:CAPS"><span class="type">HB_BUFFER_CONTENT_TYPE_UNICODE</span></a>.</p>
1793 <p>If buffer script is not set (ie. is <a class="link" href="harfbuzz-hb-common.html#HB-SCRIPT-INVALID:CAPS"><span class="type">HB_SCRIPT_INVALID</span></a>), it
1794 will be set to the Unicode script of the first character in
1795 the buffer that has a script other than <a class="link" href="harfbuzz-hb-common.html#HB-SCRIPT-COMMON:CAPS"><span class="type">HB_SCRIPT_COMMON</span></a>,
1796 <a class="link" href="harfbuzz-hb-common.html#HB-SCRIPT-INHERITED:CAPS"><span class="type">HB_SCRIPT_INHERITED</span></a>, and <a class="link" href="harfbuzz-hb-common.html#HB-SCRIPT-UNKNOWN:CAPS"><span class="type">HB_SCRIPT_UNKNOWN</span></a>.</p>
1797 <p>Next, if buffer direction is not set (ie. is <a class="link" href="harfbuzz-hb-common.html#HB-DIRECTION-INVALID:CAPS"><span class="type">HB_DIRECTION_INVALID</span></a>),
1798 it will be set to the natural horizontal direction of the
1799 buffer script as returned by <a class="link" href="harfbuzz-hb-common.html#hb-script-get-horizontal-direction" title="hb_script_get_horizontal_direction ()"><code class="function">hb_script_get_horizontal_direction()</code></a>.
1800 If <a class="link" href="harfbuzz-hb-common.html#hb-script-get-horizontal-direction" title="hb_script_get_horizontal_direction ()"><code class="function">hb_script_get_horizontal_direction()</code></a> returns <a class="link" href="harfbuzz-hb-common.html#HB-DIRECTION-INVALID:CAPS"><span class="type">HB_DIRECTION_INVALID</span></a>,
1801 then <a class="link" href="harfbuzz-hb-common.html#HB-DIRECTION-LTR:CAPS"><span class="type">HB_DIRECTION_LTR</span></a> is used.</p>
1802 <p>Finally, if buffer language is not set (ie. is <a class="link" href="harfbuzz-hb-common.html#HB-LANGUAGE-INVALID:CAPS" title="HB_LANGUAGE_INVALID"><span class="type">HB_LANGUAGE_INVALID</span></a>),
1803 it will be set to the process's default language as returned by
1804 <a class="link" href="harfbuzz-hb-common.html#hb-language-get-default" title="hb_language_get_default ()"><code class="function">hb_language_get_default()</code></a>.  This may change in the future by
1805 taking buffer script into consideration when choosing a language.
1806 Note that <a class="link" href="harfbuzz-hb-common.html#hb-language-get-default" title="hb_language_get_default ()"><code class="function">hb_language_get_default()</code></a> is NOT threadsafe the first time
1807 it is called.  See documentation for that function for details.</p>
1808 <div class="refsect3">
1809 <a name="hb-buffer-guess-segment-properties.parameters"></a><h4>Parameters</h4>
1810 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1811 <colgroup>
1812 <col width="150px" class="parameters_name">
1813 <col class="parameters_description">
1814 <col width="200px" class="parameters_annotations">
1815 </colgroup>
1816 <tbody><tr>
1817 <td class="parameter_name"><p>buffer</p></td>
1818 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1819 <td class="parameter_annotations"> </td>
1820 </tr></tbody>
1821 </table></div>
1822 </div>
1823 <p class="since">Since: <a class="link" href="api-index-0-9-7.html#api-index-0.9.7">0.9.7</a></p>
1824 </div>
1825 <hr>
1826 <div class="refsect2">
1827 <a name="hb-buffer-set-unicode-funcs"></a><h3>hb_buffer_set_unicode_funcs ()</h3>
1828 <pre class="programlisting"><span class="returnvalue">void</span>
1829 hb_buffer_set_unicode_funcs (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1830                              <em class="parameter"><code><a class="link" href="harfbuzz-hb-unicode.html#hb-unicode-funcs-t" title="hb_unicode_funcs_t"><span class="type">hb_unicode_funcs_t</span></a> *unicode_funcs</code></em>);</pre>
1831 <p>Sets the Unicode-functions structure of a buffer to
1832 <em class="parameter"><code>unicode_funcs</code></em>
1833 .</p>
1834 <div class="refsect3">
1835 <a name="hb-buffer-set-unicode-funcs.parameters"></a><h4>Parameters</h4>
1836 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1837 <colgroup>
1838 <col width="150px" class="parameters_name">
1839 <col class="parameters_description">
1840 <col width="200px" class="parameters_annotations">
1841 </colgroup>
1842 <tbody>
1843 <tr>
1844 <td class="parameter_name"><p>buffer</p></td>
1845 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1846 <td class="parameter_annotations"> </td>
1847 </tr>
1848 <tr>
1849 <td class="parameter_name"><p>unicode_funcs</p></td>
1850 <td class="parameter_description"><p>The Unicode-functions structure</p></td>
1851 <td class="parameter_annotations"> </td>
1852 </tr>
1853 </tbody>
1854 </table></div>
1855 </div>
1856 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1857 </div>
1858 <hr>
1859 <div class="refsect2">
1860 <a name="hb-buffer-get-unicode-funcs"></a><h3>hb_buffer_get_unicode_funcs ()</h3>
1861 <pre class="programlisting"><a class="link" href="harfbuzz-hb-unicode.html#hb-unicode-funcs-t" title="hb_unicode_funcs_t"><span class="returnvalue">hb_unicode_funcs_t</span></a> *
1862 hb_buffer_get_unicode_funcs (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
1863 <p>Fetches the Unicode-functions structure of a buffer.</p>
1864 <div class="refsect3">
1865 <a name="hb-buffer-get-unicode-funcs.parameters"></a><h4>Parameters</h4>
1866 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1867 <colgroup>
1868 <col width="150px" class="parameters_name">
1869 <col class="parameters_description">
1870 <col width="200px" class="parameters_annotations">
1871 </colgroup>
1872 <tbody><tr>
1873 <td class="parameter_name"><p>buffer</p></td>
1874 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1875 <td class="parameter_annotations"> </td>
1876 </tr></tbody>
1877 </table></div>
1878 </div>
1879 <div class="refsect3">
1880 <a name="hb-buffer-get-unicode-funcs.returns"></a><h4>Returns</h4>
1881 <p> The Unicode-functions structure</p>
1882 </div>
1883 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1884 </div>
1885 <hr>
1886 <div class="refsect2">
1887 <a name="hb-buffer-set-user-data"></a><h3>hb_buffer_set_user_data ()</h3>
1888 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
1889 hb_buffer_set_user_data (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1890                          <em class="parameter"><code><a class="link" href="harfbuzz-hb-common.html#hb-user-data-key-t" title="hb_user_data_key_t"><span class="type">hb_user_data_key_t</span></a> *key</code></em>,
1891                          <em class="parameter"><code><span class="type">void</span> *data</code></em>,
1892                          <em class="parameter"><code><a class="link" href="harfbuzz-hb-common.html#hb-destroy-func-t" title="hb_destroy_func_t ()"><span class="type">hb_destroy_func_t</span></a> destroy</code></em>,
1893                          <em class="parameter"><code><a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="type">hb_bool_t</span></a> replace</code></em>);</pre>
1894 <p>Attaches a user-data key/data pair to the specified buffer.</p>
1895 <p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
1896 <div class="refsect3">
1897 <a name="hb-buffer-set-user-data.parameters"></a><h4>Parameters</h4>
1898 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1899 <colgroup>
1900 <col width="150px" class="parameters_name">
1901 <col class="parameters_description">
1902 <col width="200px" class="parameters_annotations">
1903 </colgroup>
1904 <tbody>
1905 <tr>
1906 <td class="parameter_name"><p>buffer</p></td>
1907 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1908 <td class="parameter_annotations"> </td>
1909 </tr>
1910 <tr>
1911 <td class="parameter_name"><p>key</p></td>
1912 <td class="parameter_description"><p>The user-data key</p></td>
1913 <td class="parameter_annotations"> </td>
1914 </tr>
1915 <tr>
1916 <td class="parameter_name"><p>data</p></td>
1917 <td class="parameter_description"><p>A pointer to the user data</p></td>
1918 <td class="parameter_annotations"> </td>
1919 </tr>
1920 <tr>
1921 <td class="parameter_name"><p>destroy</p></td>
1922 <td class="parameter_description"><p>A callback to call when <em class="parameter"><code>data</code></em>
1923 is not needed anymore. </p></td>
1924 <td class="parameter_annotations"><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>]</span></td>
1925 </tr>
1926 <tr>
1927 <td class="parameter_name"><p>replace</p></td>
1928 <td class="parameter_description"><p>Whether to replace an existing data with the same key</p></td>
1929 <td class="parameter_annotations"> </td>
1930 </tr>
1931 </tbody>
1932 </table></div>
1933 </div>
1934 <div class="refsect3">
1935 <a name="hb-buffer-set-user-data.returns"></a><h4>Returns</h4>
1936 <p> <code class="literal">true</code> if success, <code class="literal">false</code> otherwise</p>
1937 </div>
1938 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1939 </div>
1940 <hr>
1941 <div class="refsect2">
1942 <a name="hb-buffer-get-user-data"></a><h3>hb_buffer_get_user_data ()</h3>
1943 <pre class="programlisting"><span class="returnvalue">void</span> *
1944 hb_buffer_get_user_data (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1945                          <em class="parameter"><code><a class="link" href="harfbuzz-hb-common.html#hb-user-data-key-t" title="hb_user_data_key_t"><span class="type">hb_user_data_key_t</span></a> *key</code></em>);</pre>
1946 <p>Fetches the user data associated with the specified key,
1947 attached to the specified buffer.</p>
1948 <p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
1949 <div class="refsect3">
1950 <a name="hb-buffer-get-user-data.parameters"></a><h4>Parameters</h4>
1951 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1952 <colgroup>
1953 <col width="150px" class="parameters_name">
1954 <col class="parameters_description">
1955 <col width="200px" class="parameters_annotations">
1956 </colgroup>
1957 <tbody>
1958 <tr>
1959 <td class="parameter_name"><p>buffer</p></td>
1960 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
1961 <td class="parameter_annotations"> </td>
1962 </tr>
1963 <tr>
1964 <td class="parameter_name"><p>key</p></td>
1965 <td class="parameter_description"><p>The user-data key to query</p></td>
1966 <td class="parameter_annotations"> </td>
1967 </tr>
1968 </tbody>
1969 </table></div>
1970 </div>
1971 <div class="refsect3">
1972 <a name="hb-buffer-get-user-data.returns"></a><h4>Returns</h4>
1973 <p>A pointer to the user data. </p>
1974 <p><span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span></p>
1975 </div>
1976 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
1977 </div>
1978 <hr>
1979 <div class="refsect2">
1980 <a name="hb-buffer-get-glyph-infos"></a><h3>hb_buffer_get_glyph_infos ()</h3>
1981 <pre class="programlisting"><a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t" title="hb_glyph_info_t"><span class="returnvalue">hb_glyph_info_t</span></a> *
1982 hb_buffer_get_glyph_infos (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
1983                            <em class="parameter"><code>unsigned <span class="type">int</span> *length</code></em>);</pre>
1984 <p>Returns <em class="parameter"><code>buffer</code></em>
1985  glyph information array.  Returned pointer
1986 is valid as long as <em class="parameter"><code>buffer</code></em>
1987  contents are not modified.</p>
1988 <div class="refsect3">
1989 <a name="hb-buffer-get-glyph-infos.parameters"></a><h4>Parameters</h4>
1990 <div class="informaltable"><table class="informaltable" width="100%" border="0">
1991 <colgroup>
1992 <col width="150px" class="parameters_name">
1993 <col class="parameters_description">
1994 <col width="200px" class="parameters_annotations">
1995 </colgroup>
1996 <tbody>
1997 <tr>
1998 <td class="parameter_name"><p>buffer</p></td>
1999 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
2000 <td class="parameter_annotations"> </td>
2001 </tr>
2002 <tr>
2003 <td class="parameter_name"><p>length</p></td>
2004 <td class="parameter_description"><p>The output-array length. </p></td>
2005 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span></td>
2006 </tr>
2007 </tbody>
2008 </table></div>
2009 </div>
2010 <div class="refsect3">
2011 <a name="hb-buffer-get-glyph-infos.returns"></a><h4>Returns</h4>
2012 <p>The <em class="parameter"><code>buffer</code></em>
2013 glyph information array.
2014 The value valid as long as buffer has not been modified. </p>
2015 <p><span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>][<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=length]</span></p>
2016 </div>
2017 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
2018 </div>
2019 <hr>
2020 <div class="refsect2">
2021 <a name="hb-buffer-get-glyph-positions"></a><h3>hb_buffer_get_glyph_positions ()</h3>
2022 <pre class="programlisting"><a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-position-t" title="hb_glyph_position_t"><span class="returnvalue">hb_glyph_position_t</span></a> *
2023 hb_buffer_get_glyph_positions (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
2024                                <em class="parameter"><code>unsigned <span class="type">int</span> *length</code></em>);</pre>
2025 <p>Returns <em class="parameter"><code>buffer</code></em>
2026  glyph position array.  Returned pointer
2027 is valid as long as <em class="parameter"><code>buffer</code></em>
2028  contents are not modified.</p>
2029 <p>If buffer did not have positions before, the positions will be
2030 initialized to zeros, unless this function is called from
2031 within a buffer message callback (see <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-message-func" title="hb_buffer_set_message_func ()"><code class="function">hb_buffer_set_message_func()</code></a>),
2032 in which case <code class="literal">NULL</code> is returned.</p>
2033 <div class="refsect3">
2034 <a name="hb-buffer-get-glyph-positions.parameters"></a><h4>Parameters</h4>
2035 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2036 <colgroup>
2037 <col width="150px" class="parameters_name">
2038 <col class="parameters_description">
2039 <col width="200px" class="parameters_annotations">
2040 </colgroup>
2041 <tbody>
2042 <tr>
2043 <td class="parameter_name"><p>buffer</p></td>
2044 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
2045 <td class="parameter_annotations"> </td>
2046 </tr>
2047 <tr>
2048 <td class="parameter_name"><p>length</p></td>
2049 <td class="parameter_description"><p>The output length. </p></td>
2050 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span></td>
2051 </tr>
2052 </tbody>
2053 </table></div>
2054 </div>
2055 <div class="refsect3">
2056 <a name="hb-buffer-get-glyph-positions.returns"></a><h4>Returns</h4>
2057 <p>The <em class="parameter"><code>buffer</code></em>
2058 glyph position array.
2059 The value valid as long as buffer has not been modified. </p>
2060 <p><span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>][<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=length]</span></p>
2061 </div>
2062 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
2063 </div>
2064 <hr>
2065 <div class="refsect2">
2066 <a name="hb-buffer-has-positions"></a><h3>hb_buffer_has_positions ()</h3>
2067 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
2068 hb_buffer_has_positions (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
2069 <p>Returns whether <em class="parameter"><code>buffer</code></em>
2070  has glyph position data.
2071 A buffer gains position data when <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-glyph-positions" title="hb_buffer_get_glyph_positions ()"><code class="function">hb_buffer_get_glyph_positions()</code></a> is called on it,
2072 and cleared of position data when <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-clear-contents" title="hb_buffer_clear_contents ()"><code class="function">hb_buffer_clear_contents()</code></a> is called.</p>
2073 <div class="refsect3">
2074 <a name="hb-buffer-has-positions.parameters"></a><h4>Parameters</h4>
2075 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2076 <colgroup>
2077 <col width="150px" class="parameters_name">
2078 <col class="parameters_description">
2079 <col width="200px" class="parameters_annotations">
2080 </colgroup>
2081 <tbody><tr>
2082 <td class="parameter_name"><p>buffer</p></td>
2083 <td class="parameter_description"><p>an <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a>.</p></td>
2084 <td class="parameter_annotations"> </td>
2085 </tr></tbody>
2086 </table></div>
2087 </div>
2088 <div class="refsect3">
2089 <a name="hb-buffer-has-positions.returns"></a><h4>Returns</h4>
2090 <p><code class="literal">true</code> if the <em class="parameter"><code>buffer</code></em>
2091 has position array, <code class="literal">false</code> otherwise.</p>
2092 </div>
2093 <p class="since">Since: <a class="link" href="api-index-2-7-3.html#api-index-2.7.3">2.7.3</a></p>
2094 </div>
2095 <hr>
2096 <div class="refsect2">
2097 <a name="hb-buffer-get-invisible-glyph"></a><h3>hb_buffer_get_invisible_glyph ()</h3>
2098 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="returnvalue">hb_codepoint_t</span></a>
2099 hb_buffer_get_invisible_glyph (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
2100 <p>See <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-invisible-glyph" title="hb_buffer_set_invisible_glyph ()"><code class="function">hb_buffer_set_invisible_glyph()</code></a>.</p>
2101 <div class="refsect3">
2102 <a name="hb-buffer-get-invisible-glyph.parameters"></a><h4>Parameters</h4>
2103 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2104 <colgroup>
2105 <col width="150px" class="parameters_name">
2106 <col class="parameters_description">
2107 <col width="200px" class="parameters_annotations">
2108 </colgroup>
2109 <tbody><tr>
2110 <td class="parameter_name"><p>buffer</p></td>
2111 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
2112 <td class="parameter_annotations"> </td>
2113 </tr></tbody>
2114 </table></div>
2115 </div>
2116 <div class="refsect3">
2117 <a name="hb-buffer-get-invisible-glyph.returns"></a><h4>Returns</h4>
2118 <p>The <em class="parameter"><code>buffer</code></em>
2119 invisible <a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a></p>
2120 </div>
2121 <p class="since">Since: <a class="link" href="api-index-2-0-0.html#api-index-2.0.0">2.0.0</a></p>
2122 </div>
2123 <hr>
2124 <div class="refsect2">
2125 <a name="hb-buffer-set-invisible-glyph"></a><h3>hb_buffer_set_invisible_glyph ()</h3>
2126 <pre class="programlisting"><span class="returnvalue">void</span>
2127 hb_buffer_set_invisible_glyph (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
2128                                <em class="parameter"><code><a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a> invisible</code></em>);</pre>
2129 <p>Sets the <a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a> that replaces invisible characters in
2130 the shaping result.  If set to zero (default), the glyph for the
2131 U+0020 SPACE character is used.  Otherwise, this value is used
2132 verbatim.</p>
2133 <div class="refsect3">
2134 <a name="hb-buffer-set-invisible-glyph.parameters"></a><h4>Parameters</h4>
2135 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2136 <colgroup>
2137 <col width="150px" class="parameters_name">
2138 <col class="parameters_description">
2139 <col width="200px" class="parameters_annotations">
2140 </colgroup>
2141 <tbody>
2142 <tr>
2143 <td class="parameter_name"><p>buffer</p></td>
2144 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
2145 <td class="parameter_annotations"> </td>
2146 </tr>
2147 <tr>
2148 <td class="parameter_name"><p>invisible</p></td>
2149 <td class="parameter_description"><p>the invisible <a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a></p></td>
2150 <td class="parameter_annotations"> </td>
2151 </tr>
2152 </tbody>
2153 </table></div>
2154 </div>
2155 <p class="since">Since: <a class="link" href="api-index-2-0-0.html#api-index-2.0.0">2.0.0</a></p>
2156 </div>
2157 <hr>
2158 <div class="refsect2">
2159 <a name="hb-buffer-get-not-found-glyph"></a><h3>hb_buffer_get_not_found_glyph ()</h3>
2160 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="returnvalue">hb_codepoint_t</span></a>
2161 hb_buffer_get_not_found_glyph (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
2162 <p>See <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-not-found-glyph" title="hb_buffer_set_not_found_glyph ()"><code class="function">hb_buffer_set_not_found_glyph()</code></a>.</p>
2163 <div class="refsect3">
2164 <a name="hb-buffer-get-not-found-glyph.parameters"></a><h4>Parameters</h4>
2165 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2166 <colgroup>
2167 <col width="150px" class="parameters_name">
2168 <col class="parameters_description">
2169 <col width="200px" class="parameters_annotations">
2170 </colgroup>
2171 <tbody><tr>
2172 <td class="parameter_name"><p>buffer</p></td>
2173 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
2174 <td class="parameter_annotations"> </td>
2175 </tr></tbody>
2176 </table></div>
2177 </div>
2178 <div class="refsect3">
2179 <a name="hb-buffer-get-not-found-glyph.returns"></a><h4>Returns</h4>
2180 <p>The <em class="parameter"><code>buffer</code></em>
2181 not-found <a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a></p>
2182 </div>
2183 <p class="since">Since: <a class="link" href="api-index-3-1-0.html#api-index-3.1.0">3.1.0</a></p>
2184 </div>
2185 <hr>
2186 <div class="refsect2">
2187 <a name="hb-buffer-set-not-found-glyph"></a><h3>hb_buffer_set_not_found_glyph ()</h3>
2188 <pre class="programlisting"><span class="returnvalue">void</span>
2189 hb_buffer_set_not_found_glyph (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
2190                                <em class="parameter"><code><a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a> not_found</code></em>);</pre>
2191 <p>Sets the <a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a> that replaces characters not found in
2192 the font during shaping.</p>
2193 <p>The not-found glyph defaults to zero, sometimes knows as the
2194 ".notdef" glyph.  This API allows for differentiating the two.</p>
2195 <div class="refsect3">
2196 <a name="hb-buffer-set-not-found-glyph.parameters"></a><h4>Parameters</h4>
2197 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2198 <colgroup>
2199 <col width="150px" class="parameters_name">
2200 <col class="parameters_description">
2201 <col width="200px" class="parameters_annotations">
2202 </colgroup>
2203 <tbody>
2204 <tr>
2205 <td class="parameter_name"><p>buffer</p></td>
2206 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
2207 <td class="parameter_annotations"> </td>
2208 </tr>
2209 <tr>
2210 <td class="parameter_name"><p>not_found</p></td>
2211 <td class="parameter_description"><p>the not-found <a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a></p></td>
2212 <td class="parameter_annotations"> </td>
2213 </tr>
2214 </tbody>
2215 </table></div>
2216 </div>
2217 <p class="since">Since: <a class="link" href="api-index-3-1-0.html#api-index-3.1.0">3.1.0</a></p>
2218 </div>
2219 <hr>
2220 <div class="refsect2">
2221 <a name="hb-buffer-set-replacement-codepoint"></a><h3>hb_buffer_set_replacement_codepoint ()</h3>
2222 <pre class="programlisting"><span class="returnvalue">void</span>
2223 hb_buffer_set_replacement_codepoint (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
2224                                      <em class="parameter"><code><a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a> replacement</code></em>);</pre>
2225 <p>Sets the <a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a> that replaces invalid entries for a given encoding
2226 when adding text to <em class="parameter"><code>buffer</code></em>
2227 .</p>
2228 <p>Default is <a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-REPLACEMENT-CODEPOINT-DEFAULT:CAPS" title="HB_BUFFER_REPLACEMENT_CODEPOINT_DEFAULT"><span class="type">HB_BUFFER_REPLACEMENT_CODEPOINT_DEFAULT</span></a>.</p>
2229 <div class="refsect3">
2230 <a name="hb-buffer-set-replacement-codepoint.parameters"></a><h4>Parameters</h4>
2231 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2232 <colgroup>
2233 <col width="150px" class="parameters_name">
2234 <col class="parameters_description">
2235 <col width="200px" class="parameters_annotations">
2236 </colgroup>
2237 <tbody>
2238 <tr>
2239 <td class="parameter_name"><p>buffer</p></td>
2240 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
2241 <td class="parameter_annotations"> </td>
2242 </tr>
2243 <tr>
2244 <td class="parameter_name"><p>replacement</p></td>
2245 <td class="parameter_description"><p>the replacement <a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a></p></td>
2246 <td class="parameter_annotations"> </td>
2247 </tr>
2248 </tbody>
2249 </table></div>
2250 </div>
2251 <p class="since">Since: <a class="link" href="api-index-0-9-31.html#api-index-0.9.31">0.9.31</a></p>
2252 </div>
2253 <hr>
2254 <div class="refsect2">
2255 <a name="hb-buffer-get-replacement-codepoint"></a><h3>hb_buffer_get_replacement_codepoint ()</h3>
2256 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="returnvalue">hb_codepoint_t</span></a>
2257 hb_buffer_get_replacement_codepoint (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
2258 <p>Fetches the <a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a> that replaces invalid entries for a given encoding
2259 when adding text to <em class="parameter"><code>buffer</code></em>
2260 .</p>
2261 <div class="refsect3">
2262 <a name="hb-buffer-get-replacement-codepoint.parameters"></a><h4>Parameters</h4>
2263 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2264 <colgroup>
2265 <col width="150px" class="parameters_name">
2266 <col class="parameters_description">
2267 <col width="200px" class="parameters_annotations">
2268 </colgroup>
2269 <tbody><tr>
2270 <td class="parameter_name"><p>buffer</p></td>
2271 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
2272 <td class="parameter_annotations"> </td>
2273 </tr></tbody>
2274 </table></div>
2275 </div>
2276 <div class="refsect3">
2277 <a name="hb-buffer-get-replacement-codepoint.returns"></a><h4>Returns</h4>
2278 <p>The <em class="parameter"><code>buffer</code></em>
2279 replacement <a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a></p>
2280 </div>
2281 <p class="since">Since: <a class="link" href="api-index-0-9-31.html#api-index-0.9.31">0.9.31</a></p>
2282 </div>
2283 <hr>
2284 <div class="refsect2">
2285 <a name="hb-buffer-normalize-glyphs"></a><h3>hb_buffer_normalize_glyphs ()</h3>
2286 <pre class="programlisting"><span class="returnvalue">void</span>
2287 hb_buffer_normalize_glyphs (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
2288 <p>Reorders a glyph buffer to have canonical in-cluster glyph order / position.
2289 The resulting clusters should behave identical to pre-reordering clusters.</p>
2290 <div class="note">This has nothing to do with Unicode normalization.</div>
2291 <div class="refsect3">
2292 <a name="hb-buffer-normalize-glyphs.parameters"></a><h4>Parameters</h4>
2293 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2294 <colgroup>
2295 <col width="150px" class="parameters_name">
2296 <col class="parameters_description">
2297 <col width="200px" class="parameters_annotations">
2298 </colgroup>
2299 <tbody><tr>
2300 <td class="parameter_name"><p>buffer</p></td>
2301 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
2302 <td class="parameter_annotations"> </td>
2303 </tr></tbody>
2304 </table></div>
2305 </div>
2306 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
2307 </div>
2308 <hr>
2309 <div class="refsect2">
2310 <a name="hb-buffer-reverse"></a><h3>hb_buffer_reverse ()</h3>
2311 <pre class="programlisting"><span class="returnvalue">void</span>
2312 hb_buffer_reverse (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
2313 <p>Reverses buffer contents.</p>
2314 <div class="refsect3">
2315 <a name="hb-buffer-reverse.parameters"></a><h4>Parameters</h4>
2316 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2317 <colgroup>
2318 <col width="150px" class="parameters_name">
2319 <col class="parameters_description">
2320 <col width="200px" class="parameters_annotations">
2321 </colgroup>
2322 <tbody><tr>
2323 <td class="parameter_name"><p>buffer</p></td>
2324 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
2325 <td class="parameter_annotations"> </td>
2326 </tr></tbody>
2327 </table></div>
2328 </div>
2329 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
2330 </div>
2331 <hr>
2332 <div class="refsect2">
2333 <a name="hb-buffer-reverse-range"></a><h3>hb_buffer_reverse_range ()</h3>
2334 <pre class="programlisting"><span class="returnvalue">void</span>
2335 hb_buffer_reverse_range (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
2336                          <em class="parameter"><code>unsigned <span class="type">int</span> start</code></em>,
2337                          <em class="parameter"><code>unsigned <span class="type">int</span> end</code></em>);</pre>
2338 <p>Reverses buffer contents between <em class="parameter"><code>start</code></em>
2339  and <em class="parameter"><code>end</code></em>
2340 .</p>
2341 <div class="refsect3">
2342 <a name="hb-buffer-reverse-range.parameters"></a><h4>Parameters</h4>
2343 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2344 <colgroup>
2345 <col width="150px" class="parameters_name">
2346 <col class="parameters_description">
2347 <col width="200px" class="parameters_annotations">
2348 </colgroup>
2349 <tbody>
2350 <tr>
2351 <td class="parameter_name"><p>buffer</p></td>
2352 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
2353 <td class="parameter_annotations"> </td>
2354 </tr>
2355 <tr>
2356 <td class="parameter_name"><p>start</p></td>
2357 <td class="parameter_description"><p>start index</p></td>
2358 <td class="parameter_annotations"> </td>
2359 </tr>
2360 <tr>
2361 <td class="parameter_name"><p>end</p></td>
2362 <td class="parameter_description"><p>end index</p></td>
2363 <td class="parameter_annotations"> </td>
2364 </tr>
2365 </tbody>
2366 </table></div>
2367 </div>
2368 <p class="since">Since: <a class="link" href="api-index-0-9-41.html#api-index-0.9.41">0.9.41</a></p>
2369 </div>
2370 <hr>
2371 <div class="refsect2">
2372 <a name="hb-buffer-reverse-clusters"></a><h3>hb_buffer_reverse_clusters ()</h3>
2373 <pre class="programlisting"><span class="returnvalue">void</span>
2374 hb_buffer_reverse_clusters (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>);</pre>
2375 <p>Reverses buffer clusters.  That is, the buffer contents are
2376 reversed, then each cluster (consecutive items having the
2377 same cluster number) are reversed again.</p>
2378 <div class="refsect3">
2379 <a name="hb-buffer-reverse-clusters.parameters"></a><h4>Parameters</h4>
2380 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2381 <colgroup>
2382 <col width="150px" class="parameters_name">
2383 <col class="parameters_description">
2384 <col width="200px" class="parameters_annotations">
2385 </colgroup>
2386 <tbody><tr>
2387 <td class="parameter_name"><p>buffer</p></td>
2388 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
2389 <td class="parameter_annotations"> </td>
2390 </tr></tbody>
2391 </table></div>
2392 </div>
2393 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
2394 </div>
2395 <hr>
2396 <div class="refsect2">
2397 <a name="hb-buffer-serialize"></a><h3>hb_buffer_serialize ()</h3>
2398 <pre class="programlisting">unsigned <span class="returnvalue">int</span>
2399 hb_buffer_serialize (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
2400                      <em class="parameter"><code>unsigned <span class="type">int</span> start</code></em>,
2401                      <em class="parameter"><code>unsigned <span class="type">int</span> end</code></em>,
2402                      <em class="parameter"><code><span class="type">char</span> *buf</code></em>,
2403                      <em class="parameter"><code>unsigned <span class="type">int</span> buf_size</code></em>,
2404                      <em class="parameter"><code>unsigned <span class="type">int</span> *buf_consumed</code></em>,
2405                      <em class="parameter"><code><a class="link" href="harfbuzz-hb-font.html#hb-font-t" title="hb_font_t"><span class="type">hb_font_t</span></a> *font</code></em>,
2406                      <em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a> format</code></em>,
2407                      <em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-flags-t" title="enum hb_buffer_serialize_flags_t"><span class="type">hb_buffer_serialize_flags_t</span></a> flags</code></em>);</pre>
2408 <p>Serializes <em class="parameter"><code>buffer</code></em>
2409  into a textual representation of its content, whether
2410 Unicode codepoints or glyph identifiers and positioning information. This is
2411 useful for showing the contents of the buffer, for example during debugging.
2412 See the documentation of <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-unicode" title="hb_buffer_serialize_unicode ()"><code class="function">hb_buffer_serialize_unicode()</code></a> and
2413 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-glyphs" title="hb_buffer_serialize_glyphs ()"><code class="function">hb_buffer_serialize_glyphs()</code></a> for a description of the output format.</p>
2414 <div class="refsect3">
2415 <a name="hb-buffer-serialize.parameters"></a><h4>Parameters</h4>
2416 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2417 <colgroup>
2418 <col width="150px" class="parameters_name">
2419 <col class="parameters_description">
2420 <col width="200px" class="parameters_annotations">
2421 </colgroup>
2422 <tbody>
2423 <tr>
2424 <td class="parameter_name"><p>buffer</p></td>
2425 <td class="parameter_description"><p>an <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> buffer.</p></td>
2426 <td class="parameter_annotations"> </td>
2427 </tr>
2428 <tr>
2429 <td class="parameter_name"><p>start</p></td>
2430 <td class="parameter_description"><p>the first item in <em class="parameter"><code>buffer</code></em>
2431 to serialize.</p></td>
2432 <td class="parameter_annotations"> </td>
2433 </tr>
2434 <tr>
2435 <td class="parameter_name"><p>end</p></td>
2436 <td class="parameter_description"><p>the last item in <em class="parameter"><code>buffer</code></em>
2437 to serialize.</p></td>
2438 <td class="parameter_annotations"> </td>
2439 </tr>
2440 <tr>
2441 <td class="parameter_name"><p>buf</p></td>
2442 <td class="parameter_description"><p>output string to
2443 write serialized buffer into. </p></td>
2444 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=buf_size][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> uint8_t]</span></td>
2445 </tr>
2446 <tr>
2447 <td class="parameter_name"><p>buf_size</p></td>
2448 <td class="parameter_description"><p>the size of <em class="parameter"><code>buf</code></em>
2449 .</p></td>
2450 <td class="parameter_annotations"> </td>
2451 </tr>
2452 <tr>
2453 <td class="parameter_name"><p>buf_consumed</p></td>
2454 <td class="parameter_description"><p>if not <code class="literal">NULL</code>, will be set to the number of byes written into <em class="parameter"><code>buf</code></em>
2455 . </p></td>
2456 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL may be passed instead of a pointer to a location."><span class="acronym">optional</span></acronym>]</span></td>
2457 </tr>
2458 <tr>
2459 <td class="parameter_name"><p>font</p></td>
2460 <td class="parameter_description"><p>the <a class="link" href="harfbuzz-hb-font.html#hb-font-t" title="hb_font_t"><span class="type">hb_font_t</span></a> used to shape this buffer, needed to
2461 read glyph names and extents. If <code class="literal">NULL</code>, and empty font will be used. </p></td>
2462 <td class="parameter_annotations"><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>]</span></td>
2463 </tr>
2464 <tr>
2465 <td class="parameter_name"><p>format</p></td>
2466 <td class="parameter_description"><p>the <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a> to use for formatting the output.</p></td>
2467 <td class="parameter_annotations"> </td>
2468 </tr>
2469 <tr>
2470 <td class="parameter_name"><p>flags</p></td>
2471 <td class="parameter_description"><p>the <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-flags-t" title="enum hb_buffer_serialize_flags_t"><span class="type">hb_buffer_serialize_flags_t</span></a> that control what glyph properties
2472 to serialize.</p></td>
2473 <td class="parameter_annotations"> </td>
2474 </tr>
2475 </tbody>
2476 </table></div>
2477 </div>
2478 <div class="refsect3">
2479 <a name="hb-buffer-serialize.returns"></a><h4>Returns</h4>
2480 <p>The number of serialized items.</p>
2481 </div>
2482 <p class="since">Since: <a class="link" href="api-index-2-7-3.html#api-index-2.7.3">2.7.3</a></p>
2483 </div>
2484 <hr>
2485 <div class="refsect2">
2486 <a name="hb-buffer-serialize-glyphs"></a><h3>hb_buffer_serialize_glyphs ()</h3>
2487 <pre class="programlisting">unsigned <span class="returnvalue">int</span>
2488 hb_buffer_serialize_glyphs (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
2489                             <em class="parameter"><code>unsigned <span class="type">int</span> start</code></em>,
2490                             <em class="parameter"><code>unsigned <span class="type">int</span> end</code></em>,
2491                             <em class="parameter"><code><span class="type">char</span> *buf</code></em>,
2492                             <em class="parameter"><code>unsigned <span class="type">int</span> buf_size</code></em>,
2493                             <em class="parameter"><code>unsigned <span class="type">int</span> *buf_consumed</code></em>,
2494                             <em class="parameter"><code><a class="link" href="harfbuzz-hb-font.html#hb-font-t" title="hb_font_t"><span class="type">hb_font_t</span></a> *font</code></em>,
2495                             <em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a> format</code></em>,
2496                             <em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-flags-t" title="enum hb_buffer_serialize_flags_t"><span class="type">hb_buffer_serialize_flags_t</span></a> flags</code></em>);</pre>
2497 <p>Serializes <em class="parameter"><code>buffer</code></em>
2498  into a textual representation of its glyph content,
2499 useful for showing the contents of the buffer, for example during debugging.
2500 There are currently two supported serialization formats:</p>
2501 <div class="refsect3">
2502 <a name="id-1.3.3.3.7.53.5"></a><h4>text</h4>
2503 <p>A human-readable, plain text format.
2504 The serialized glyphs will look something like:</p>
2505 <p><code class="literal">
2506 [uni0651=0@518,0+0|uni0628=0+1897]
2507 </code></p>
2508 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
2509 <li class="listitem"><p>The serialized glyphs are delimited with <code class="literal">[</code> and <code class="literal">]</code>.</p></li>
2510 <li class="listitem"><p>Glyphs are separated with <code class="literal">|</code></p></li>
2511 <li class="listitem">
2512 <p>Each glyph starts with glyph name, or glyph index if
2513 <a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-SERIALIZE-FLAG-NO-GLYPH-NAMES:CAPS"><span class="type">HB_BUFFER_SERIALIZE_FLAG_NO_GLYPH_NAMES</span></a> flag is set. Then,</p>
2514 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: circle; ">
2515 <li class="listitem"><p>If <a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-SERIALIZE-FLAG-NO-CLUSTERS:CAPS"><span class="type">HB_BUFFER_SERIALIZE_FLAG_NO_CLUSTERS</span></a> is not set, <code class="literal">=</code> then <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t.cluster"><span class="type">hb_glyph_info_t.cluster</span></a>.</p></li>
2516 <li class="listitem">
2517 <p>If <a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-SERIALIZE-FLAG-NO-POSITIONS:CAPS"><span class="type">HB_BUFFER_SERIALIZE_FLAG_NO_POSITIONS</span></a> is not set, the <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-position-t" title="hb_glyph_position_t"><span class="type">hb_glyph_position_t</span></a> in the format:</p>
2518 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: square; ">
2519 <li class="listitem"><p>If both <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-position-t.x-offset"><span class="type">hb_glyph_position_t.x_offset</span></a> and <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-position-t.y-offset"><span class="type">hb_glyph_position_t.y_offset</span></a> are not 0, <code class="literal">@x_offset,y_offset</code>. Then,</p></li>
2520 <li class="listitem"><p><code class="literal">+x_advance</code>, then <code class="literal">,y_advance</code> if <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-position-t.y-advance"><span class="type">hb_glyph_position_t.y_advance</span></a> is not 0. Then,</p></li>
2521 </ul></div>
2522 </li>
2523 <li class="listitem"><p>If <a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-SERIALIZE-FLAG-GLYPH-EXTENTS:CAPS"><span class="type">HB_BUFFER_SERIALIZE_FLAG_GLYPH_EXTENTS</span></a> is set, the <a class="link" href="harfbuzz-hb-font.html#hb-glyph-extents-t" title="hb_glyph_extents_t"><span class="type">hb_glyph_extents_t</span></a> in the format <code class="literal">&lt;x_bearing,y_bearing,width,height&gt;</code></p></li>
2524 </ul></div>
2525 </li>
2526 </ul></div>
2527 </div>
2528 <div class="refsect3">
2529 <a name="id-1.3.3.3.7.53.6"></a><h4>json</h4>
2530 <p>A machine-readable, structured format.
2531 The serialized glyphs will look something like:</p>
2532 <p><code class="literal">
2533 [{"g":"uni0651","cl":0,"dx":518,"dy":0,"ax":0,"ay":0},
2534 {"g":"uni0628","cl":0,"dx":0,"dy":0,"ax":1897,"ay":0}]
2535 </code></p>
2536 <p>Each glyph is a JSON object, with the following properties:</p>
2537 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
2538 <li class="listitem"><p><code class="literal">g</code>: the glyph name or glyph index if
2539 <a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-SERIALIZE-FLAG-NO-GLYPH-NAMES:CAPS"><span class="type">HB_BUFFER_SERIALIZE_FLAG_NO_GLYPH_NAMES</span></a> flag is set.</p></li>
2540 <li class="listitem"><p><code class="literal">cl</code>: <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t.cluster"><span class="type">hb_glyph_info_t.cluster</span></a> if
2541 <a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-SERIALIZE-FLAG-NO-CLUSTERS:CAPS"><span class="type">HB_BUFFER_SERIALIZE_FLAG_NO_CLUSTERS</span></a> is not set.</p></li>
2542 <li class="listitem"><p><code class="literal">dx</code>,<code class="literal">dy</code>,<code class="literal">ax</code>,<code class="literal">ay</code>: <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-position-t.x-offset"><span class="type">hb_glyph_position_t.x_offset</span></a>, <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-position-t.y-offset"><span class="type">hb_glyph_position_t.y_offset</span></a>,
2543 <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-position-t.x-advance"><span class="type">hb_glyph_position_t.x_advance</span></a> and <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-position-t.y-advance"><span class="type">hb_glyph_position_t.y_advance</span></a>
2544 respectively, if <a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-SERIALIZE-FLAG-NO-POSITIONS:CAPS"><span class="type">HB_BUFFER_SERIALIZE_FLAG_NO_POSITIONS</span></a> is not set.</p></li>
2545 <li class="listitem"><p><code class="literal">xb</code>,<code class="literal">yb</code>,<code class="literal">w</code>,<code class="literal">h</code>: <a class="link" href="harfbuzz-hb-font.html#hb-glyph-extents-t.x-bearing"><span class="type">hb_glyph_extents_t.x_bearing</span></a>, <a class="link" href="harfbuzz-hb-font.html#hb-glyph-extents-t.y-bearing"><span class="type">hb_glyph_extents_t.y_bearing</span></a>,
2546 <a class="link" href="harfbuzz-hb-font.html#hb-glyph-extents-t.width"><span class="type">hb_glyph_extents_t.width</span></a> and <a class="link" href="harfbuzz-hb-font.html#hb-glyph-extents-t.height"><span class="type">hb_glyph_extents_t.height</span></a> respectively if
2547 <a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-SERIALIZE-FLAG-GLYPH-EXTENTS:CAPS"><span class="type">HB_BUFFER_SERIALIZE_FLAG_GLYPH_EXTENTS</span></a> is set.</p></li>
2548 </ul></div>
2549 </div>
2550 <div class="refsect3">
2551 <a name="hb-buffer-serialize-glyphs.parameters"></a><h4>Parameters</h4>
2552 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2553 <colgroup>
2554 <col width="150px" class="parameters_name">
2555 <col class="parameters_description">
2556 <col width="200px" class="parameters_annotations">
2557 </colgroup>
2558 <tbody>
2559 <tr>
2560 <td class="parameter_name"><p>buffer</p></td>
2561 <td class="parameter_description"><p>an <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> buffer.</p></td>
2562 <td class="parameter_annotations"> </td>
2563 </tr>
2564 <tr>
2565 <td class="parameter_name"><p>start</p></td>
2566 <td class="parameter_description"><p>the first item in <em class="parameter"><code>buffer</code></em>
2567 to serialize.</p></td>
2568 <td class="parameter_annotations"> </td>
2569 </tr>
2570 <tr>
2571 <td class="parameter_name"><p>end</p></td>
2572 <td class="parameter_description"><p>the last item in <em class="parameter"><code>buffer</code></em>
2573 to serialize.</p></td>
2574 <td class="parameter_annotations"> </td>
2575 </tr>
2576 <tr>
2577 <td class="parameter_name"><p>buf</p></td>
2578 <td class="parameter_description"><p>output string to
2579 write serialized buffer into. </p></td>
2580 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=buf_size][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> uint8_t]</span></td>
2581 </tr>
2582 <tr>
2583 <td class="parameter_name"><p>buf_size</p></td>
2584 <td class="parameter_description"><p>the size of <em class="parameter"><code>buf</code></em>
2585 .</p></td>
2586 <td class="parameter_annotations"> </td>
2587 </tr>
2588 <tr>
2589 <td class="parameter_name"><p>buf_consumed</p></td>
2590 <td class="parameter_description"><p>if not <code class="literal">NULL</code>, will be set to the number of byes written into <em class="parameter"><code>buf</code></em>
2591 . </p></td>
2592 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL may be passed instead of a pointer to a location."><span class="acronym">optional</span></acronym>]</span></td>
2593 </tr>
2594 <tr>
2595 <td class="parameter_name"><p>font</p></td>
2596 <td class="parameter_description"><p>the <a class="link" href="harfbuzz-hb-font.html#hb-font-t" title="hb_font_t"><span class="type">hb_font_t</span></a> used to shape this buffer, needed to
2597 read glyph names and extents. If <code class="literal">NULL</code>, and empty font will be used. </p></td>
2598 <td class="parameter_annotations"><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>]</span></td>
2599 </tr>
2600 <tr>
2601 <td class="parameter_name"><p>format</p></td>
2602 <td class="parameter_description"><p>the <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a> to use for formatting the output.</p></td>
2603 <td class="parameter_annotations"> </td>
2604 </tr>
2605 <tr>
2606 <td class="parameter_name"><p>flags</p></td>
2607 <td class="parameter_description"><p>the <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-flags-t" title="enum hb_buffer_serialize_flags_t"><span class="type">hb_buffer_serialize_flags_t</span></a> that control what glyph properties
2608 to serialize.</p></td>
2609 <td class="parameter_annotations"> </td>
2610 </tr>
2611 </tbody>
2612 </table></div>
2613 </div>
2614 <div class="refsect3">
2615 <a name="hb-buffer-serialize-glyphs.returns"></a><h4>Returns</h4>
2616 <p>The number of serialized items.</p>
2617 </div>
2618 <p class="since">Since: <a class="link" href="api-index-0-9-7.html#api-index-0.9.7">0.9.7</a></p>
2619 </div>
2620 <hr>
2621 <div class="refsect2">
2622 <a name="hb-buffer-deserialize-glyphs"></a><h3>hb_buffer_deserialize_glyphs ()</h3>
2623 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
2624 hb_buffer_deserialize_glyphs (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
2625                               <em class="parameter"><code>const <span class="type">char</span> *buf</code></em>,
2626                               <em class="parameter"><code><span class="type">int</span> buf_len</code></em>,
2627                               <em class="parameter"><code>const <span class="type">char</span> **end_ptr</code></em>,
2628                               <em class="parameter"><code><a class="link" href="harfbuzz-hb-font.html#hb-font-t" title="hb_font_t"><span class="type">hb_font_t</span></a> *font</code></em>,
2629                               <em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a> format</code></em>);</pre>
2630 <p>Deserializes glyphs <em class="parameter"><code>buffer</code></em>
2631  from textual representation in the format
2632 produced by <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-glyphs" title="hb_buffer_serialize_glyphs ()"><code class="function">hb_buffer_serialize_glyphs()</code></a>.</p>
2633 <div class="refsect3">
2634 <a name="hb-buffer-deserialize-glyphs.parameters"></a><h4>Parameters</h4>
2635 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2636 <colgroup>
2637 <col width="150px" class="parameters_name">
2638 <col class="parameters_description">
2639 <col width="200px" class="parameters_annotations">
2640 </colgroup>
2641 <tbody>
2642 <tr>
2643 <td class="parameter_name"><p>buffer</p></td>
2644 <td class="parameter_description"><p>an <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> buffer.</p></td>
2645 <td class="parameter_annotations"> </td>
2646 </tr>
2647 <tr>
2648 <td class="parameter_name"><p>buf</p></td>
2649 <td class="parameter_description"><p>string to deserialize. </p></td>
2650 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=buf_len]</span></td>
2651 </tr>
2652 <tr>
2653 <td class="parameter_name"><p>buf_len</p></td>
2654 <td class="parameter_description"><p>the size of <em class="parameter"><code>buf</code></em>
2655 , or -1 if it is <code class="literal">NULL</code>-terminated</p></td>
2656 <td class="parameter_annotations"> </td>
2657 </tr>
2658 <tr>
2659 <td class="parameter_name"><p>end_ptr</p></td>
2660 <td class="parameter_description"><p>output pointer to the character after last
2661 consumed one. </p></td>
2662 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL may be passed instead of a pointer to a location."><span class="acronym">optional</span></acronym>]</span></td>
2663 </tr>
2664 <tr>
2665 <td class="parameter_name"><p>font</p></td>
2666 <td class="parameter_description"><p>font for getting glyph IDs. </p></td>
2667 <td class="parameter_annotations"><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>]</span></td>
2668 </tr>
2669 <tr>
2670 <td class="parameter_name"><p>format</p></td>
2671 <td class="parameter_description"><p>the <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a> of the input <em class="parameter"><code>buf</code></em>
2672 </p></td>
2673 <td class="parameter_annotations"> </td>
2674 </tr>
2675 </tbody>
2676 </table></div>
2677 </div>
2678 <div class="refsect3">
2679 <a name="hb-buffer-deserialize-glyphs.returns"></a><h4>Returns</h4>
2680 <p> <code class="literal">true</code> if <em class="parameter"><code>buf</code></em>
2681 is not fully consumed, <code class="literal">false</code> otherwise.</p>
2682 </div>
2683 <p class="since">Since: <a class="link" href="api-index-0-9-7.html#api-index-0.9.7">0.9.7</a></p>
2684 </div>
2685 <hr>
2686 <div class="refsect2">
2687 <a name="hb-buffer-serialize-unicode"></a><h3>hb_buffer_serialize_unicode ()</h3>
2688 <pre class="programlisting">unsigned <span class="returnvalue">int</span>
2689 hb_buffer_serialize_unicode (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
2690                              <em class="parameter"><code>unsigned <span class="type">int</span> start</code></em>,
2691                              <em class="parameter"><code>unsigned <span class="type">int</span> end</code></em>,
2692                              <em class="parameter"><code><span class="type">char</span> *buf</code></em>,
2693                              <em class="parameter"><code>unsigned <span class="type">int</span> buf_size</code></em>,
2694                              <em class="parameter"><code>unsigned <span class="type">int</span> *buf_consumed</code></em>,
2695                              <em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a> format</code></em>,
2696                              <em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-flags-t" title="enum hb_buffer_serialize_flags_t"><span class="type">hb_buffer_serialize_flags_t</span></a> flags</code></em>);</pre>
2697 <p>Serializes <em class="parameter"><code>buffer</code></em>
2698  into a textual representation of its content,
2699 when the buffer contains Unicode codepoints (i.e., before shaping). This is
2700 useful for showing the contents of the buffer, for example during debugging.
2701 There are currently two supported serialization formats:</p>
2702 <div class="refsect3">
2703 <a name="id-1.3.3.3.7.55.5"></a><h4>text</h4>
2704 <p>A human-readable, plain text format.
2705 The serialized codepoints will look something like:</p>
2706 <p><code class="literal">
2707  &lt;U+0651=0|U+0628=1&gt;
2708 </code></p>
2709 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
2710 <li class="listitem"><p>Glyphs are separated with <code class="literal">|</code></p></li>
2711 <li class="listitem"><p>Unicode codepoints are expressed as zero-padded four (or more)
2712 digit hexadecimal numbers preceded by <code class="literal">U+</code></p></li>
2713 <li class="listitem"><p>If <a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-SERIALIZE-FLAG-NO-CLUSTERS:CAPS"><span class="type">HB_BUFFER_SERIALIZE_FLAG_NO_CLUSTERS</span></a> is not set, the cluster
2714 will be indicated with a <code class="literal">=</code> then <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t.cluster"><span class="type">hb_glyph_info_t.cluster</span></a>.</p></li>
2715 </ul></div>
2716 </div>
2717 <div class="refsect3">
2718 <a name="id-1.3.3.3.7.55.6"></a><h4>json</h4>
2719 <p>A machine-readable, structured format.
2720 The serialized codepoints will be a list of objects with the following
2721 properties:</p>
2722 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
2723 <li class="listitem"><p><code class="literal">u</code>: the Unicode codepoint as a decimal integer</p></li>
2724 <li class="listitem"><p><code class="literal">cl</code>: <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t.cluster"><span class="type">hb_glyph_info_t.cluster</span></a> if
2725 <a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-SERIALIZE-FLAG-NO-CLUSTERS:CAPS"><span class="type">HB_BUFFER_SERIALIZE_FLAG_NO_CLUSTERS</span></a> is not set.</p></li>
2726 </ul></div>
2727 <p>For example:</p>
2728 <p><code class="literal">
2729 [{u:1617,cl:0},{u:1576,cl:1}]
2730 </code></p>
2731 </div>
2732 <div class="refsect3">
2733 <a name="hb-buffer-serialize-unicode.parameters"></a><h4>Parameters</h4>
2734 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2735 <colgroup>
2736 <col width="150px" class="parameters_name">
2737 <col class="parameters_description">
2738 <col width="200px" class="parameters_annotations">
2739 </colgroup>
2740 <tbody>
2741 <tr>
2742 <td class="parameter_name"><p>buffer</p></td>
2743 <td class="parameter_description"><p>an <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> buffer.</p></td>
2744 <td class="parameter_annotations"> </td>
2745 </tr>
2746 <tr>
2747 <td class="parameter_name"><p>start</p></td>
2748 <td class="parameter_description"><p>the first item in <em class="parameter"><code>buffer</code></em>
2749 to serialize.</p></td>
2750 <td class="parameter_annotations"> </td>
2751 </tr>
2752 <tr>
2753 <td class="parameter_name"><p>end</p></td>
2754 <td class="parameter_description"><p>the last item in <em class="parameter"><code>buffer</code></em>
2755 to serialize.</p></td>
2756 <td class="parameter_annotations"> </td>
2757 </tr>
2758 <tr>
2759 <td class="parameter_name"><p>buf</p></td>
2760 <td class="parameter_description"><p>output string to
2761 write serialized buffer into. </p></td>
2762 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=buf_size][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> uint8_t]</span></td>
2763 </tr>
2764 <tr>
2765 <td class="parameter_name"><p>buf_size</p></td>
2766 <td class="parameter_description"><p>the size of <em class="parameter"><code>buf</code></em>
2767 .</p></td>
2768 <td class="parameter_annotations"> </td>
2769 </tr>
2770 <tr>
2771 <td class="parameter_name"><p>buf_consumed</p></td>
2772 <td class="parameter_description"><p>if not <code class="literal">NULL</code>, will be set to the number of byes written into <em class="parameter"><code>buf</code></em>
2773 . </p></td>
2774 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL may be passed instead of a pointer to a location."><span class="acronym">optional</span></acronym>]</span></td>
2775 </tr>
2776 <tr>
2777 <td class="parameter_name"><p>format</p></td>
2778 <td class="parameter_description"><p>the <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a> to use for formatting the output.</p></td>
2779 <td class="parameter_annotations"> </td>
2780 </tr>
2781 <tr>
2782 <td class="parameter_name"><p>flags</p></td>
2783 <td class="parameter_description"><p>the <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-flags-t" title="enum hb_buffer_serialize_flags_t"><span class="type">hb_buffer_serialize_flags_t</span></a> that control what glyph properties
2784 to serialize.</p></td>
2785 <td class="parameter_annotations"> </td>
2786 </tr>
2787 </tbody>
2788 </table></div>
2789 </div>
2790 <div class="refsect3">
2791 <a name="hb-buffer-serialize-unicode.returns"></a><h4>Returns</h4>
2792 <p>The number of serialized items.</p>
2793 </div>
2794 <p class="since">Since: <a class="link" href="api-index-2-7-3.html#api-index-2.7.3">2.7.3</a></p>
2795 </div>
2796 <hr>
2797 <div class="refsect2">
2798 <a name="hb-buffer-deserialize-unicode"></a><h3>hb_buffer_deserialize_unicode ()</h3>
2799 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
2800 hb_buffer_deserialize_unicode (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
2801                                <em class="parameter"><code>const <span class="type">char</span> *buf</code></em>,
2802                                <em class="parameter"><code><span class="type">int</span> buf_len</code></em>,
2803                                <em class="parameter"><code>const <span class="type">char</span> **end_ptr</code></em>,
2804                                <em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a> format</code></em>);</pre>
2805 <p>Deserializes Unicode <em class="parameter"><code>buffer</code></em>
2806  from textual representation in the format
2807 produced by <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-unicode" title="hb_buffer_serialize_unicode ()"><code class="function">hb_buffer_serialize_unicode()</code></a>.</p>
2808 <div class="refsect3">
2809 <a name="hb-buffer-deserialize-unicode.parameters"></a><h4>Parameters</h4>
2810 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2811 <colgroup>
2812 <col width="150px" class="parameters_name">
2813 <col class="parameters_description">
2814 <col width="200px" class="parameters_annotations">
2815 </colgroup>
2816 <tbody>
2817 <tr>
2818 <td class="parameter_name"><p>buffer</p></td>
2819 <td class="parameter_description"><p>an <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> buffer.</p></td>
2820 <td class="parameter_annotations"> </td>
2821 </tr>
2822 <tr>
2823 <td class="parameter_name"><p>buf</p></td>
2824 <td class="parameter_description"><p>string to deserialize. </p></td>
2825 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=buf_len]</span></td>
2826 </tr>
2827 <tr>
2828 <td class="parameter_name"><p>buf_len</p></td>
2829 <td class="parameter_description"><p>the size of <em class="parameter"><code>buf</code></em>
2830 , or -1 if it is <code class="literal">NULL</code>-terminated</p></td>
2831 <td class="parameter_annotations"> </td>
2832 </tr>
2833 <tr>
2834 <td class="parameter_name"><p>end_ptr</p></td>
2835 <td class="parameter_description"><p>output pointer to the character after last
2836 consumed one. </p></td>
2837 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL may be passed instead of a pointer to a location."><span class="acronym">optional</span></acronym>]</span></td>
2838 </tr>
2839 <tr>
2840 <td class="parameter_name"><p>format</p></td>
2841 <td class="parameter_description"><p>the <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a> of the input <em class="parameter"><code>buf</code></em>
2842 </p></td>
2843 <td class="parameter_annotations"> </td>
2844 </tr>
2845 </tbody>
2846 </table></div>
2847 </div>
2848 <div class="refsect3">
2849 <a name="hb-buffer-deserialize-unicode.returns"></a><h4>Returns</h4>
2850 <p> <code class="literal">true</code> if <em class="parameter"><code>buf</code></em>
2851 is not fully consumed, <code class="literal">false</code> otherwise.</p>
2852 </div>
2853 <p class="since">Since: <a class="link" href="api-index-2-7-3.html#api-index-2.7.3">2.7.3</a></p>
2854 </div>
2855 <hr>
2856 <div class="refsect2">
2857 <a name="hb-buffer-serialize-format-from-string"></a><h3>hb_buffer_serialize_format_from_string ()</h3>
2858 <pre class="programlisting"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="returnvalue">hb_buffer_serialize_format_t</span></a>
2859 hb_buffer_serialize_format_from_string
2860                                (<em class="parameter"><code>const <span class="type">char</span> *str</code></em>,
2861                                 <em class="parameter"><code><span class="type">int</span> len</code></em>);</pre>
2862 <p>Parses a string into an <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a>. Does not check if
2863 <em class="parameter"><code>str</code></em>
2864  is a valid buffer serialization format, use
2865 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-list-formats" title="hb_buffer_serialize_list_formats ()"><code class="function">hb_buffer_serialize_list_formats()</code></a> to get the list of supported formats.</p>
2866 <div class="refsect3">
2867 <a name="hb-buffer-serialize-format-from-string.parameters"></a><h4>Parameters</h4>
2868 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2869 <colgroup>
2870 <col width="150px" class="parameters_name">
2871 <col class="parameters_description">
2872 <col width="200px" class="parameters_annotations">
2873 </colgroup>
2874 <tbody>
2875 <tr>
2876 <td class="parameter_name"><p>str</p></td>
2877 <td class="parameter_description"><p>a string to parse. </p></td>
2878 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> length=len][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> uint8_t]</span></td>
2879 </tr>
2880 <tr>
2881 <td class="parameter_name"><p>len</p></td>
2882 <td class="parameter_description"><p>length of <em class="parameter"><code>str</code></em>
2883 , or -1 if string is <code class="literal">NULL</code> terminated</p></td>
2884 <td class="parameter_annotations"> </td>
2885 </tr>
2886 </tbody>
2887 </table></div>
2888 </div>
2889 <div class="refsect3">
2890 <a name="hb-buffer-serialize-format-from-string.returns"></a><h4>Returns</h4>
2891 <p>The parsed <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a>.</p>
2892 </div>
2893 <p class="since">Since: <a class="link" href="api-index-0-9-7.html#api-index-0.9.7">0.9.7</a></p>
2894 </div>
2895 <hr>
2896 <div class="refsect2">
2897 <a name="hb-buffer-serialize-format-to-string"></a><h3>hb_buffer_serialize_format_to_string ()</h3>
2898 <pre class="programlisting">const <span class="returnvalue">char</span> *
2899 hb_buffer_serialize_format_to_string (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a> format</code></em>);</pre>
2900 <p>Converts <em class="parameter"><code>format</code></em>
2901  to the string corresponding it, or <code class="literal">NULL</code> if it is not a valid
2902 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a>.</p>
2903 <div class="refsect3">
2904 <a name="hb-buffer-serialize-format-to-string.parameters"></a><h4>Parameters</h4>
2905 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2906 <colgroup>
2907 <col width="150px" class="parameters_name">
2908 <col class="parameters_description">
2909 <col width="200px" class="parameters_annotations">
2910 </colgroup>
2911 <tbody><tr>
2912 <td class="parameter_name"><p>format</p></td>
2913 <td class="parameter_description"><p>an <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-format-t" title="enum hb_buffer_serialize_format_t"><span class="type">hb_buffer_serialize_format_t</span></a> to convert.</p></td>
2914 <td class="parameter_annotations"> </td>
2915 </tr></tbody>
2916 </table></div>
2917 </div>
2918 <div class="refsect3">
2919 <a name="hb-buffer-serialize-format-to-string.returns"></a><h4>Returns</h4>
2920 <p>A <code class="literal">NULL</code> terminated string corresponding to <em class="parameter"><code>format</code></em>
2921 . Should not be freed. </p>
2922 <p><span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span></p>
2923 </div>
2924 <p class="since">Since: <a class="link" href="api-index-0-9-7.html#api-index-0.9.7">0.9.7</a></p>
2925 </div>
2926 <hr>
2927 <div class="refsect2">
2928 <a name="hb-buffer-serialize-list-formats"></a><h3>hb_buffer_serialize_list_formats ()</h3>
2929 <pre class="programlisting">const <span class="returnvalue">char</span> **
2930 hb_buffer_serialize_list_formats (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
2931 <p>Returns a list of supported buffer serialization formats.</p>
2932 <div class="refsect3">
2933 <a name="hb-buffer-serialize-list-formats.returns"></a><h4>Returns</h4>
2934 <p>A string array of buffer serialization formats. Should not be freed. </p>
2935 <p><span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span></p>
2936 </div>
2937 <p class="since">Since: <a class="link" href="api-index-0-9-7.html#api-index-0.9.7">0.9.7</a></p>
2938 </div>
2939 <hr>
2940 <div class="refsect2">
2941 <a name="hb-segment-properties-equal"></a><h3>hb_segment_properties_equal ()</h3>
2942 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
2943 hb_segment_properties_equal (<em class="parameter"><code>const <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> *a</code></em>,
2944                              <em class="parameter"><code>const <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> *b</code></em>);</pre>
2945 <p>Checks the equality of two <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a>'s.</p>
2946 <div class="refsect3">
2947 <a name="hb-segment-properties-equal.parameters"></a><h4>Parameters</h4>
2948 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2949 <colgroup>
2950 <col width="150px" class="parameters_name">
2951 <col class="parameters_description">
2952 <col width="200px" class="parameters_annotations">
2953 </colgroup>
2954 <tbody>
2955 <tr>
2956 <td class="parameter_name"><p>a</p></td>
2957 <td class="parameter_description"><p>first <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> to compare.</p></td>
2958 <td class="parameter_annotations"> </td>
2959 </tr>
2960 <tr>
2961 <td class="parameter_name"><p>b</p></td>
2962 <td class="parameter_description"><p>second <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> to compare.</p></td>
2963 <td class="parameter_annotations"> </td>
2964 </tr>
2965 </tbody>
2966 </table></div>
2967 </div>
2968 <div class="refsect3">
2969 <a name="hb-segment-properties-equal.returns"></a><h4>Returns</h4>
2970 <p><code class="literal">true</code> if all properties of <em class="parameter"><code>a</code></em>
2971 equal those of <em class="parameter"><code>b</code></em>
2972 , <code class="literal">false</code> otherwise.</p>
2973 </div>
2974 <p class="since">Since: <a class="link" href="api-index-0-9-7.html#api-index-0.9.7">0.9.7</a></p>
2975 </div>
2976 <hr>
2977 <div class="refsect2">
2978 <a name="hb-segment-properties-hash"></a><h3>hb_segment_properties_hash ()</h3>
2979 <pre class="programlisting">unsigned <span class="returnvalue">int</span>
2980 hb_segment_properties_hash (<em class="parameter"><code>const <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> *p</code></em>);</pre>
2981 <p>Creates a hash representing <em class="parameter"><code>p</code></em>
2982 .</p>
2983 <div class="refsect3">
2984 <a name="hb-segment-properties-hash.parameters"></a><h4>Parameters</h4>
2985 <div class="informaltable"><table class="informaltable" width="100%" border="0">
2986 <colgroup>
2987 <col width="150px" class="parameters_name">
2988 <col class="parameters_description">
2989 <col width="200px" class="parameters_annotations">
2990 </colgroup>
2991 <tbody><tr>
2992 <td class="parameter_name"><p>p</p></td>
2993 <td class="parameter_description"><p><a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> to hash.</p></td>
2994 <td class="parameter_annotations"> </td>
2995 </tr></tbody>
2996 </table></div>
2997 </div>
2998 <div class="refsect3">
2999 <a name="hb-segment-properties-hash.returns"></a><h4>Returns</h4>
3000 <p>A hash of <em class="parameter"><code>p</code></em>
3001 .</p>
3002 </div>
3003 <p class="since">Since: <a class="link" href="api-index-0-9-7.html#api-index-0.9.7">0.9.7</a></p>
3004 </div>
3005 <hr>
3006 <div class="refsect2">
3007 <a name="hb-segment-properties-overlay"></a><h3>hb_segment_properties_overlay ()</h3>
3008 <pre class="programlisting"><span class="returnvalue">void</span>
3009 hb_segment_properties_overlay (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> *p</code></em>,
3010                                <em class="parameter"><code>const <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> *src</code></em>);</pre>
3011 <p>Fills in missing fields of <em class="parameter"><code>p</code></em>
3012  from <em class="parameter"><code>src</code></em>
3013  in a considered manner.</p>
3014 <p>First, if <em class="parameter"><code>p</code></em>
3015  does not have direction set, direction is copied from <em class="parameter"><code>src</code></em>
3016 .</p>
3017 <p>Next, if <em class="parameter"><code>p</code></em>
3018  and <em class="parameter"><code>src</code></em>
3019  have the same direction (which can be unset), if <em class="parameter"><code>p</code></em>
3020
3021 does not have script set, script is copied from <em class="parameter"><code>src</code></em>
3022 .</p>
3023 <p>Finally, if <em class="parameter"><code>p</code></em>
3024  and <em class="parameter"><code>src</code></em>
3025  have the same direction and script (which either
3026 can be unset), if <em class="parameter"><code>p</code></em>
3027  does not have language set, language is copied from
3028 <em class="parameter"><code>src</code></em>
3029 .</p>
3030 <div class="refsect3">
3031 <a name="hb-segment-properties-overlay.parameters"></a><h4>Parameters</h4>
3032 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3033 <colgroup>
3034 <col width="150px" class="parameters_name">
3035 <col class="parameters_description">
3036 <col width="200px" class="parameters_annotations">
3037 </colgroup>
3038 <tbody>
3039 <tr>
3040 <td class="parameter_name"><p>p</p></td>
3041 <td class="parameter_description"><p><a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> to fill in.</p></td>
3042 <td class="parameter_annotations"> </td>
3043 </tr>
3044 <tr>
3045 <td class="parameter_name"><p>src</p></td>
3046 <td class="parameter_description"><p><a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> to fill in from.</p></td>
3047 <td class="parameter_annotations"> </td>
3048 </tr>
3049 </tbody>
3050 </table></div>
3051 </div>
3052 <p class="since">Since: <a class="link" href="api-index-3-3-0.html#api-index-3.3.0">3.3.0</a></p>
3053 </div>
3054 <hr>
3055 <div class="refsect2">
3056 <a name="hb-buffer-diff"></a><h3>hb_buffer_diff ()</h3>
3057 <pre class="programlisting"><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-diff-flags-t" title="enum hb_buffer_diff_flags_t"><span class="returnvalue">hb_buffer_diff_flags_t</span></a>
3058 hb_buffer_diff (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
3059                 <em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *reference</code></em>,
3060                 <em class="parameter"><code><a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a> dottedcircle_glyph</code></em>,
3061                 <em class="parameter"><code>unsigned <span class="type">int</span> position_fuzz</code></em>);</pre>
3062 <p>If dottedcircle_glyph is (hb_codepoint_t) -1 then <a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-DIFF-FLAG-DOTTED-CIRCLE-PRESENT:CAPS"><span class="type">HB_BUFFER_DIFF_FLAG_DOTTED_CIRCLE_PRESENT</span></a>
3063 and <a class="link" href="harfbuzz-hb-buffer.html#HB-BUFFER-DIFF-FLAG-NOTDEF-PRESENT:CAPS"><span class="type">HB_BUFFER_DIFF_FLAG_NOTDEF_PRESENT</span></a> are never returned.  This should be used by most
3064 callers if just comparing two buffers is needed.</p>
3065 <div class="refsect3">
3066 <a name="hb-buffer-diff.parameters"></a><h4>Parameters</h4>
3067 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3068 <colgroup>
3069 <col width="150px" class="parameters_name">
3070 <col class="parameters_description">
3071 <col width="200px" class="parameters_annotations">
3072 </colgroup>
3073 <tbody>
3074 <tr>
3075 <td class="parameter_name"><p>buffer</p></td>
3076 <td class="parameter_description"><p>a buffer.</p></td>
3077 <td class="parameter_annotations"> </td>
3078 </tr>
3079 <tr>
3080 <td class="parameter_name"><p>reference</p></td>
3081 <td class="parameter_description"><p>other buffer to compare to.</p></td>
3082 <td class="parameter_annotations"> </td>
3083 </tr>
3084 <tr>
3085 <td class="parameter_name"><p>dottedcircle_glyph</p></td>
3086 <td class="parameter_description"><p>glyph id of U+25CC DOTTED CIRCLE, or (hb_codepont_t) -1.</p></td>
3087 <td class="parameter_annotations"> </td>
3088 </tr>
3089 <tr>
3090 <td class="parameter_name"><p>position_fuzz</p></td>
3091 <td class="parameter_description"><p>allowed absolute difference in position values.</p></td>
3092 <td class="parameter_annotations"> </td>
3093 </tr>
3094 </tbody>
3095 </table></div>
3096 </div>
3097 <p class="since">Since: <a class="link" href="api-index-1-5-0.html#api-index-1.5.0">1.5.0</a></p>
3098 </div>
3099 <hr>
3100 <div class="refsect2">
3101 <a name="hb-buffer-set-message-func"></a><h3>hb_buffer_set_message_func ()</h3>
3102 <pre class="programlisting"><span class="returnvalue">void</span>
3103 hb_buffer_set_message_func (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
3104                             <em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-message-func-t" title="hb_buffer_message_func_t ()"><span class="type">hb_buffer_message_func_t</span></a> func</code></em>,
3105                             <em class="parameter"><code><span class="type">void</span> *user_data</code></em>,
3106                             <em class="parameter"><code><a class="link" href="harfbuzz-hb-common.html#hb-destroy-func-t" title="hb_destroy_func_t ()"><span class="type">hb_destroy_func_t</span></a> destroy</code></em>);</pre>
3107 <p>Sets the implementation function for <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-message-func-t" title="hb_buffer_message_func_t ()"><span class="type">hb_buffer_message_func_t</span></a>.</p>
3108 <div class="refsect3">
3109 <a name="hb-buffer-set-message-func.parameters"></a><h4>Parameters</h4>
3110 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3111 <colgroup>
3112 <col width="150px" class="parameters_name">
3113 <col class="parameters_description">
3114 <col width="200px" class="parameters_annotations">
3115 </colgroup>
3116 <tbody>
3117 <tr>
3118 <td class="parameter_name"><p>buffer</p></td>
3119 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a></p></td>
3120 <td class="parameter_annotations"> </td>
3121 </tr>
3122 <tr>
3123 <td class="parameter_name"><p>func</p></td>
3124 <td class="parameter_description"><p>Callback function. </p></td>
3125 <td class="parameter_annotations"><span class="annotation">[<acronym title="This parameter is a 'user_data', for callbacks; many bindings can pass NULL here."><span class="acronym">closure</span></acronym> user_data][<acronym title="This parameter is a 'destroy_data', for callbacks."><span class="acronym">destroy</span></acronym> destroy][<acronym title="The callback is valid until the GDestroyNotify argument is called."><span class="acronym">scope notified</span></acronym>]</span></td>
3126 </tr>
3127 <tr>
3128 <td class="parameter_name"><p>user_data</p></td>
3129 <td class="parameter_description"><p>Data to pass to <em class="parameter"><code>func</code></em>
3130 . </p></td>
3131 <td class="parameter_annotations"><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>]</span></td>
3132 </tr>
3133 <tr>
3134 <td class="parameter_name"><p>destroy</p></td>
3135 <td class="parameter_description"><p>The function to call when <em class="parameter"><code>user_data</code></em>
3136 is not needed anymore. </p></td>
3137 <td class="parameter_annotations"><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>]</span></td>
3138 </tr>
3139 </tbody>
3140 </table></div>
3141 </div>
3142 <p class="since">Since: <a class="link" href="api-index-1-1-3.html#api-index-1.1.3">1.1.3</a></p>
3143 </div>
3144 <hr>
3145 <div class="refsect2">
3146 <a name="hb-glyph-info-get-glyph-flags"></a><h3>hb_glyph_info_get_glyph_flags ()</h3>
3147 <pre class="programlisting"><a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-flags-t" title="enum hb_glyph_flags_t"><span class="returnvalue">hb_glyph_flags_t</span></a>
3148 hb_glyph_info_get_glyph_flags (<em class="parameter"><code>const <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t" title="hb_glyph_info_t"><span class="type">hb_glyph_info_t</span></a> *info</code></em>);</pre>
3149 <p>Returns glyph flags encoded within a <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t" title="hb_glyph_info_t"><span class="type">hb_glyph_info_t</span></a>.</p>
3150 <div class="refsect3">
3151 <a name="hb-glyph-info-get-glyph-flags.parameters"></a><h4>Parameters</h4>
3152 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3153 <colgroup>
3154 <col width="150px" class="parameters_name">
3155 <col class="parameters_description">
3156 <col width="200px" class="parameters_annotations">
3157 </colgroup>
3158 <tbody><tr>
3159 <td class="parameter_name"><p>info</p></td>
3160 <td class="parameter_description"><p>a <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t" title="hb_glyph_info_t"><span class="type">hb_glyph_info_t</span></a></p></td>
3161 <td class="parameter_annotations"> </td>
3162 </tr></tbody>
3163 </table></div>
3164 </div>
3165 <div class="refsect3">
3166 <a name="hb-glyph-info-get-glyph-flags.returns"></a><h4>Returns</h4>
3167 <p>The <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-flags-t" title="enum hb_glyph_flags_t"><span class="type">hb_glyph_flags_t</span></a> encoded within <em class="parameter"><code>info</code></em>
3168 </p>
3169 </div>
3170 <p class="since">Since: <a class="link" href="api-index-1-5-0.html#api-index-1.5.0">1.5.0</a></p>
3171 </div>
3172 <hr>
3173 <div class="refsect2">
3174 <a name="hb-buffer-message-func-t"></a><h3>hb_buffer_message_func_t ()</h3>
3175 <pre class="programlisting"><a class="link" href="harfbuzz-hb-common.html#hb-bool-t" title="hb_bool_t"><span class="returnvalue">hb_bool_t</span></a>
3176 <span class="c_punctuation">(</span>*hb_buffer_message_func_t<span class="c_punctuation">)</span> (<em class="parameter"><code><a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> *buffer</code></em>,
3177                              <em class="parameter"><code><a class="link" href="harfbuzz-hb-font.html#hb-font-t" title="hb_font_t"><span class="type">hb_font_t</span></a> *font</code></em>,
3178                              <em class="parameter"><code>const <span class="type">char</span> *message</code></em>,
3179                              <em class="parameter"><code><span class="type">void</span> *user_data</code></em>);</pre>
3180 <p>A callback method for <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a>. The method gets called with the
3181 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> it was set on, the <a class="link" href="harfbuzz-hb-font.html#hb-font-t" title="hb_font_t"><span class="type">hb_font_t</span></a> the buffer is shaped with and a
3182 message describing what step of the shaping process will be performed.
3183 Returning <code class="literal">false</code> from this method will skip this shaping step and move to
3184 the next one.</p>
3185 <div class="refsect3">
3186 <a name="hb-buffer-message-func-t.parameters"></a><h4>Parameters</h4>
3187 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3188 <colgroup>
3189 <col width="150px" class="parameters_name">
3190 <col class="parameters_description">
3191 <col width="200px" class="parameters_annotations">
3192 </colgroup>
3193 <tbody>
3194 <tr>
3195 <td class="parameter_name"><p>buffer</p></td>
3196 <td class="parameter_description"><p>An <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> to work upon</p></td>
3197 <td class="parameter_annotations"> </td>
3198 </tr>
3199 <tr>
3200 <td class="parameter_name"><p>font</p></td>
3201 <td class="parameter_description"><p>The <a class="link" href="harfbuzz-hb-font.html#hb-font-t" title="hb_font_t"><span class="type">hb_font_t</span></a> the <em class="parameter"><code>buffer</code></em>
3202 is shaped with</p></td>
3203 <td class="parameter_annotations"> </td>
3204 </tr>
3205 <tr>
3206 <td class="parameter_name"><p>message</p></td>
3207 <td class="parameter_description"><p><code class="literal">NULL</code>-terminated message passed to the function</p></td>
3208 <td class="parameter_annotations"> </td>
3209 </tr>
3210 <tr>
3211 <td class="parameter_name"><p>user_data</p></td>
3212 <td class="parameter_description"><p>User data pointer passed by the caller</p></td>
3213 <td class="parameter_annotations"> </td>
3214 </tr>
3215 </tbody>
3216 </table></div>
3217 </div>
3218 <div class="refsect3">
3219 <a name="hb-buffer-message-func-t.returns"></a><h4>Returns</h4>
3220 <p> <code class="literal">true</code> to perform the shaping step, <code class="literal">false</code> to skip it.</p>
3221 </div>
3222 <p class="since">Since: <a class="link" href="api-index-1-1-3.html#api-index-1.1.3">1.1.3</a></p>
3223 </div>
3224 </div>
3225 <div class="refsect1">
3226 <a name="harfbuzz-hb-buffer.other_details"></a><h2>Types and Values</h2>
3227 <div class="refsect2">
3228 <a name="HB-SEGMENT-PROPERTIES-DEFAULT:CAPS"></a><h3>HB_SEGMENT_PROPERTIES_DEFAULT</h3>
3229 <pre class="programlisting">#define             HB_SEGMENT_PROPERTIES_DEFAULT</pre>
3230 <p>The default <a class="link" href="harfbuzz-hb-buffer.html#hb-segment-properties-t" title="hb_segment_properties_t"><span class="type">hb_segment_properties_t</span></a> of of freshly created <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a>.</p>
3231 </div>
3232 <hr>
3233 <div class="refsect2">
3234 <a name="HB-BUFFER-REPLACEMENT-CODEPOINT-DEFAULT:CAPS"></a><h3>HB_BUFFER_REPLACEMENT_CODEPOINT_DEFAULT</h3>
3235 <pre class="programlisting">#define HB_BUFFER_REPLACEMENT_CODEPOINT_DEFAULT 0xFFFDu
3236 </pre>
3237 <p>The default code point for replacing invalid characters in a given encoding.
3238 Set to U+FFFD REPLACEMENT CHARACTER.</p>
3239 <p class="since">Since: <a class="link" href="api-index-0-9-31.html#api-index-0.9.31">0.9.31</a></p>
3240 </div>
3241 <hr>
3242 <div class="refsect2">
3243 <a name="hb-buffer-t"></a><h3>hb_buffer_t</h3>
3244 <pre class="programlisting">typedef struct hb_buffer_t hb_buffer_t;
3245 </pre>
3246 <p>The main structure holding the input text and its properties before shaping,
3247 and output glyphs and their information after shaping.</p>
3248 </div>
3249 <hr>
3250 <div class="refsect2">
3251 <a name="hb-glyph-info-t"></a><h3>hb_glyph_info_t</h3>
3252 <pre class="programlisting">typedef struct {
3253   hb_codepoint_t codepoint;
3254   uint32_t       cluster;
3255 } hb_glyph_info_t;
3256 </pre>
3257 <p>The <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t" title="hb_glyph_info_t"><span class="type">hb_glyph_info_t</span></a> is the structure that holds information about the
3258 glyphs and their relation to input text.</p>
3259 <div class="refsect3">
3260 <a name="hb-glyph-info-t.members"></a><h4>Members</h4>
3261 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3262 <colgroup>
3263 <col width="300px" class="struct_members_name">
3264 <col class="struct_members_description">
3265 <col width="200px" class="struct_members_annotations">
3266 </colgroup>
3267 <tbody>
3268 <tr>
3269 <td class="struct_member_name"><p><a class="link" href="harfbuzz-hb-common.html#hb-codepoint-t" title="hb_codepoint_t"><span class="type">hb_codepoint_t</span></a> <em class="structfield"><code><a name="hb-glyph-info-t.codepoint"></a>codepoint</code></em>;</p></td>
3270 <td class="struct_member_description"><p>either a Unicode code point (before shaping) or a glyph index
3271 (after shaping).</p></td>
3272 <td class="struct_member_annotations"> </td>
3273 </tr>
3274 <tr>
3275 <td class="struct_member_name"><p><span class="type">uint32_t</span> <em class="structfield"><code><a name="hb-glyph-info-t.cluster"></a>cluster</code></em>;</p></td>
3276 <td class="struct_member_description"><p>the index of the character in the original text that corresponds
3277 to this <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t" title="hb_glyph_info_t"><span class="type">hb_glyph_info_t</span></a>, or whatever the client passes to
3278 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-add" title="hb_buffer_add ()"><code class="function">hb_buffer_add()</code></a>. More than one <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t" title="hb_glyph_info_t"><span class="type">hb_glyph_info_t</span></a> can have the same
3279 <em class="parameter"><code>cluster</code></em>
3280 value, if they resulted from the same character (e.g. one
3281 to many glyph substitution), and when more than one character gets
3282 merged in the same glyph (e.g. many to one glyph substitution) the
3283 <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t" title="hb_glyph_info_t"><span class="type">hb_glyph_info_t</span></a> will have the smallest cluster value of them.
3284 By default some characters are merged into the same cluster
3285 (e.g. combining marks have the same cluster as their bases)
3286 even if they are separate glyphs, <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-cluster-level" title="hb_buffer_set_cluster_level ()"><code class="function">hb_buffer_set_cluster_level()</code></a>
3287 allow selecting more fine-grained cluster handling.</p></td>
3288 <td class="struct_member_annotations"> </td>
3289 </tr>
3290 </tbody>
3291 </table></div>
3292 </div>
3293 </div>
3294 <hr>
3295 <div class="refsect2">
3296 <a name="hb-glyph-flags-t"></a><h3>enum hb_glyph_flags_t</h3>
3297 <p>Flags for <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t" title="hb_glyph_info_t"><span class="type">hb_glyph_info_t</span></a>.</p>
3298 <div class="refsect3">
3299 <a name="hb-glyph-flags-t.members"></a><h4>Members</h4>
3300 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3301 <colgroup>
3302 <col width="300px" class="enum_members_name">
3303 <col class="enum_members_description">
3304 <col width="200px" class="enum_members_annotations">
3305 </colgroup>
3306 <tbody>
3307 <tr>
3308 <td class="enum_member_name"><p><a name="HB-GLYPH-FLAG-UNSAFE-TO-BREAK:CAPS"></a>HB_GLYPH_FLAG_UNSAFE_TO_BREAK</p></td>
3309 <td class="enum_member_description">
3310 <p>Indicates that if input text is broken at the
3311                                    beginning of the cluster this glyph is part of,
3312                                    then both sides need to be re-shaped, as the
3313                                    result might be different.
3314                                    On the flip side, it means that when this
3315                                    flag is not present, then it is safe to break
3316                                    the glyph-run at the beginning of this
3317                                    cluster, and the two sides will represent the
3318                                    exact same result one would get if breaking
3319                                    input text at the beginning of this cluster
3320                                    and shaping the two sides separately.
3321                                    This can be used to optimize paragraph
3322                                    layout, by avoiding re-shaping of each line
3323                                    after line-breaking.</p>
3324 </td>
3325 <td class="enum_member_annotations"> </td>
3326 </tr>
3327 <tr>
3328 <td class="enum_member_name"><p><a name="HB-GLYPH-FLAG-UNSAFE-TO-CONCAT:CAPS"></a>HB_GLYPH_FLAG_UNSAFE_TO_CONCAT</p></td>
3329 <td class="enum_member_description">
3330 <p>Indicates that if input text is changed on one
3331                                    side of the beginning of the cluster this glyph
3332                                    is part of, then the shaping results for the
3333                                    other side might change.
3334                                    Note that the absence of this flag will NOT by
3335                                    itself mean that it IS safe to concat text.
3336                                    Only two pieces of text both of which clear of
3337                                    this flag can be concatenated safely.
3338                                    This can be used to optimize paragraph
3339                                    layout, by avoiding re-shaping of each line
3340                                    after line-breaking, by limiting the
3341                                    reshaping to a small piece around the
3342                                    breaking positin only, even if the breaking
3343                                    position carries the
3344                                    <a class="link" href="harfbuzz-hb-buffer.html#HB-GLYPH-FLAG-UNSAFE-TO-BREAK:CAPS"><span class="type">HB_GLYPH_FLAG_UNSAFE_TO_BREAK</span></a> or when
3345                                    hyphenation or other text transformation
3346                                    happens at line-break position, in the following
3347                                    way:
3348                                    1. Iterate back from the line-break position
3349                                    until the first cluster start position that is
3350                                    NOT unsafe-to-concat, 2. shape the segment from
3351                                    there till the end of line, 3. check whether the
3352                                    resulting glyph-run also is clear of the
3353                                    unsafe-to-concat at its start-of-text position;
3354                                    if it is, just splice it into place and the line
3355                                    is shaped; If not, move on to a position further
3356                                    back that is clear of unsafe-to-concat and retry
3357                                    from there, and repeat.
3358                                    At the start of next line a similar algorithm can
3359                                    be implemented. That is: 1. Iterate forward from
3360                                    the line-break position untill the first cluster
3361                                    start position that is NOT unsafe-to-concat, 2.
3362                                    shape the segment from beginning of the line to
3363                                    that position, 3. check whether the resulting
3364                                    glyph-run also is clear of the unsafe-to-concat
3365                                    at its end-of-text position; if it is, just splice
3366                                    it into place and the beginning is shaped; If not,
3367                                    move on to a position further forward that is clear
3368                                    of unsafe-to-concat and retry up to there, and repeat.
3369                                    A slight complication will arise in the
3370                                    implementation of the algorithm above,
3371                                    because while our buffer API has a way to
3372                                    return flags for position corresponding to
3373                                    start-of-text, there is currently no position
3374                                    corresponding to end-of-text.  This limitation
3375                                    can be alleviated by shaping more text than needed
3376                                    and looking for unsafe-to-concat flag within text
3377                                    clusters.
3378                                    The <a class="link" href="harfbuzz-hb-buffer.html#HB-GLYPH-FLAG-UNSAFE-TO-BREAK:CAPS"><span class="type">HB_GLYPH_FLAG_UNSAFE_TO_BREAK</span></a> flag will
3379                                    always imply this flag.
3380                                    Since: 3.3.0</p>
3381 </td>
3382 <td class="enum_member_annotations"> </td>
3383 </tr>
3384 <tr>
3385 <td class="enum_member_name"><p><a name="HB-GLYPH-FLAG-DEFINED:CAPS"></a>HB_GLYPH_FLAG_DEFINED</p></td>
3386 <td class="enum_member_description">
3387 <p>All the currently defined flags.</p>
3388 </td>
3389 <td class="enum_member_annotations"> </td>
3390 </tr>
3391 </tbody>
3392 </table></div>
3393 </div>
3394 <p class="since">Since: <a class="link" href="api-index-1-5-0.html#api-index-1.5.0">1.5.0</a></p>
3395 </div>
3396 <hr>
3397 <div class="refsect2">
3398 <a name="hb-glyph-position-t"></a><h3>hb_glyph_position_t</h3>
3399 <pre class="programlisting">typedef struct {
3400   hb_position_t  x_advance;
3401   hb_position_t  y_advance;
3402   hb_position_t  x_offset;
3403   hb_position_t  y_offset;
3404 } hb_glyph_position_t;
3405 </pre>
3406 <p>The <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-position-t" title="hb_glyph_position_t"><span class="type">hb_glyph_position_t</span></a> is the structure that holds the positions of the
3407 glyph in both horizontal and vertical directions. All positions in
3408 <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-position-t" title="hb_glyph_position_t"><span class="type">hb_glyph_position_t</span></a> are relative to the current point.</p>
3409 <div class="refsect3">
3410 <a name="hb-glyph-position-t.members"></a><h4>Members</h4>
3411 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3412 <colgroup>
3413 <col width="300px" class="struct_members_name">
3414 <col class="struct_members_description">
3415 <col width="200px" class="struct_members_annotations">
3416 </colgroup>
3417 <tbody>
3418 <tr>
3419 <td class="struct_member_name"><p><a class="link" href="harfbuzz-hb-common.html#hb-position-t" title="hb_position_t"><span class="type">hb_position_t</span></a> <em class="structfield"><code><a name="hb-glyph-position-t.x-advance"></a>x_advance</code></em>;</p></td>
3420 <td class="struct_member_description"><p>how much the line advances after drawing this glyph when setting
3421 text in horizontal direction.</p></td>
3422 <td class="struct_member_annotations"> </td>
3423 </tr>
3424 <tr>
3425 <td class="struct_member_name"><p><a class="link" href="harfbuzz-hb-common.html#hb-position-t" title="hb_position_t"><span class="type">hb_position_t</span></a> <em class="structfield"><code><a name="hb-glyph-position-t.y-advance"></a>y_advance</code></em>;</p></td>
3426 <td class="struct_member_description"><p>how much the line advances after drawing this glyph when setting
3427 text in vertical direction.</p></td>
3428 <td class="struct_member_annotations"> </td>
3429 </tr>
3430 <tr>
3431 <td class="struct_member_name"><p><a class="link" href="harfbuzz-hb-common.html#hb-position-t" title="hb_position_t"><span class="type">hb_position_t</span></a> <em class="structfield"><code><a name="hb-glyph-position-t.x-offset"></a>x_offset</code></em>;</p></td>
3432 <td class="struct_member_description"><p>how much the glyph moves on the X-axis before drawing it, this
3433 should not affect how much the line advances.</p></td>
3434 <td class="struct_member_annotations"> </td>
3435 </tr>
3436 <tr>
3437 <td class="struct_member_name"><p><a class="link" href="harfbuzz-hb-common.html#hb-position-t" title="hb_position_t"><span class="type">hb_position_t</span></a> <em class="structfield"><code><a name="hb-glyph-position-t.y-offset"></a>y_offset</code></em>;</p></td>
3438 <td class="struct_member_description"><p>how much the glyph moves on the Y-axis before drawing it, this
3439 should not affect how much the line advances.</p></td>
3440 <td class="struct_member_annotations"> </td>
3441 </tr>
3442 </tbody>
3443 </table></div>
3444 </div>
3445 </div>
3446 <hr>
3447 <div class="refsect2">
3448 <a name="hb-buffer-content-type-t"></a><h3>enum hb_buffer_content_type_t</h3>
3449 <p>The type of <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a> contents.</p>
3450 <div class="refsect3">
3451 <a name="hb-buffer-content-type-t.members"></a><h4>Members</h4>
3452 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3453 <colgroup>
3454 <col width="300px" class="enum_members_name">
3455 <col class="enum_members_description">
3456 <col width="200px" class="enum_members_annotations">
3457 </colgroup>
3458 <tbody>
3459 <tr>
3460 <td class="enum_member_name"><p><a name="HB-BUFFER-CONTENT-TYPE-INVALID:CAPS"></a>HB_BUFFER_CONTENT_TYPE_INVALID</p></td>
3461 <td class="enum_member_description">
3462 <p>Initial value for new buffer.</p>
3463 </td>
3464 <td class="enum_member_annotations"> </td>
3465 </tr>
3466 <tr>
3467 <td class="enum_member_name"><p><a name="HB-BUFFER-CONTENT-TYPE-UNICODE:CAPS"></a>HB_BUFFER_CONTENT_TYPE_UNICODE</p></td>
3468 <td class="enum_member_description">
3469 <p>The buffer contains input characters (before shaping).</p>
3470 </td>
3471 <td class="enum_member_annotations"> </td>
3472 </tr>
3473 <tr>
3474 <td class="enum_member_name"><p><a name="HB-BUFFER-CONTENT-TYPE-GLYPHS:CAPS"></a>HB_BUFFER_CONTENT_TYPE_GLYPHS</p></td>
3475 <td class="enum_member_description">
3476 <p>The buffer contains output glyphs (after shaping).</p>
3477 </td>
3478 <td class="enum_member_annotations"> </td>
3479 </tr>
3480 </tbody>
3481 </table></div>
3482 </div>
3483 </div>
3484 <hr>
3485 <div class="refsect2">
3486 <a name="hb-buffer-flags-t"></a><h3>enum hb_buffer_flags_t</h3>
3487 <p>Flags for <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a>.</p>
3488 <div class="refsect3">
3489 <a name="hb-buffer-flags-t.members"></a><h4>Members</h4>
3490 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3491 <colgroup>
3492 <col width="300px" class="enum_members_name">
3493 <col class="enum_members_description">
3494 <col width="200px" class="enum_members_annotations">
3495 </colgroup>
3496 <tbody>
3497 <tr>
3498 <td class="enum_member_name"><p><a name="HB-BUFFER-FLAG-DEFAULT:CAPS"></a>HB_BUFFER_FLAG_DEFAULT</p></td>
3499 <td class="enum_member_description">
3500 <p>the default buffer flag.</p>
3501 </td>
3502 <td class="enum_member_annotations"> </td>
3503 </tr>
3504 <tr>
3505 <td class="enum_member_name"><p><a name="HB-BUFFER-FLAG-BOT:CAPS"></a>HB_BUFFER_FLAG_BOT</p></td>
3506 <td class="enum_member_description">
3507 <p>flag indicating that special handling of the beginning
3508 of text paragraph can be applied to this buffer. Should usually
3509 be set, unless you are passing to the buffer only part
3510 of the text without the full context.</p>
3511 </td>
3512 <td class="enum_member_annotations"> </td>
3513 </tr>
3514 <tr>
3515 <td class="enum_member_name"><p><a name="HB-BUFFER-FLAG-EOT:CAPS"></a>HB_BUFFER_FLAG_EOT</p></td>
3516 <td class="enum_member_description">
3517 <p>flag indicating that special handling of the end of text
3518 paragraph can be applied to this buffer, similar to
3519 <em class="parameter"><code>HB_BUFFER_FLAG_BOT</code></em>
3520 .</p>
3521 </td>
3522 <td class="enum_member_annotations"> </td>
3523 </tr>
3524 <tr>
3525 <td class="enum_member_name"><p><a name="HB-BUFFER-FLAG-PRESERVE-DEFAULT-IGNORABLES:CAPS"></a>HB_BUFFER_FLAG_PRESERVE_DEFAULT_IGNORABLES</p></td>
3526 <td class="enum_member_description">
3527 <p>flag indication that character with Default_Ignorable
3528 Unicode property should use the corresponding glyph
3529 from the font, instead of hiding them (done by
3530 replacing them with the space glyph and zeroing the
3531 advance width.)  This flag takes precedence over
3532 <em class="parameter"><code>HB_BUFFER_FLAG_REMOVE_DEFAULT_IGNORABLES</code></em>
3533 .</p>
3534 </td>
3535 <td class="enum_member_annotations"> </td>
3536 </tr>
3537 <tr>
3538 <td class="enum_member_name"><p><a name="HB-BUFFER-FLAG-REMOVE-DEFAULT-IGNORABLES:CAPS"></a>HB_BUFFER_FLAG_REMOVE_DEFAULT_IGNORABLES</p></td>
3539 <td class="enum_member_description">
3540 <p>flag indication that character with Default_Ignorable
3541 Unicode property should be removed from glyph string
3542 instead of hiding them (done by replacing them with the
3543 space glyph and zeroing the advance width.)
3544 <em class="parameter"><code>HB_BUFFER_FLAG_PRESERVE_DEFAULT_IGNORABLES</code></em>
3545  takes
3546 precedence over this flag. Since: 1.8.0</p>
3547 </td>
3548 <td class="enum_member_annotations"> </td>
3549 </tr>
3550 <tr>
3551 <td class="enum_member_name"><p><a name="HB-BUFFER-FLAG-DO-NOT-INSERT-DOTTED-CIRCLE:CAPS"></a>HB_BUFFER_FLAG_DO_NOT_INSERT_DOTTED_CIRCLE</p></td>
3552 <td class="enum_member_description">
3553 <p>flag indicating that a dotted circle should
3554 not be inserted in the rendering of incorrect
3555 character sequences (such at &lt;0905 093E&gt;). Since: 2.4.0</p>
3556 </td>
3557 <td class="enum_member_annotations"> </td>
3558 </tr>
3559 <tr>
3560 <td class="enum_member_name"><p><a name="HB-BUFFER-FLAG-VERIFY:CAPS"></a>HB_BUFFER_FLAG_VERIFY</p></td>
3561 <td class="enum_member_description">
3562 <p>flag indicating that the <a class="link" href="harfbuzz-hb-shape.html#hb-shape" title="hb_shape ()"><code class="function">hb_shape()</code></a> call and its variants
3563 should perform various verification processes on the results
3564 of the shaping operation on the buffer.  If the verification
3565 fails, then either a buffer message is sent, if a message
3566 handler is installed on the buffer, or a message is written
3567 to standard error.  In either case, the shaping result might
3568 be modified to show the failed output. Since: 3.4.0</p>
3569 </td>
3570 <td class="enum_member_annotations"> </td>
3571 </tr>
3572 </tbody>
3573 </table></div>
3574 </div>
3575 <p class="since">Since: <a class="link" href="api-index-0-9-20.html#api-index-0.9.20">0.9.20</a></p>
3576 </div>
3577 <hr>
3578 <div class="refsect2">
3579 <a name="hb-buffer-cluster-level-t"></a><h3>enum hb_buffer_cluster_level_t</h3>
3580 <p>Data type for holding HarfBuzz's clustering behavior options. The cluster level
3581 dictates one aspect of how HarfBuzz will treat non-base characters
3582
3583 during shaping.</p>
3584 <p>In <em class="parameter"><code>HB_BUFFER_CLUSTER_LEVEL_MONOTONE_GRAPHEMES</code></em>
3585 , non-base
3586 characters are merged into the cluster of the base character that precedes them.</p>
3587 <p>In <em class="parameter"><code>HB_BUFFER_CLUSTER_LEVEL_MONOTONE_CHARACTERS</code></em>
3588 , non-base characters are initially
3589 assigned their own cluster values, which are not merged into preceding base
3590 clusters. This allows HarfBuzz to perform additional operations like reorder
3591 sequences of adjacent marks.</p>
3592 <p><em class="parameter"><code>HB_BUFFER_CLUSTER_LEVEL_MONOTONE_GRAPHEMES</code></em>
3593  is the default, because it maintains
3594 backward compatibility with older versions of HarfBuzz. New client programs that
3595 do not need to maintain such backward compatibility are recommended to use
3596 <em class="parameter"><code>HB_BUFFER_CLUSTER_LEVEL_MONOTONE_CHARACTERS</code></em>
3597  instead of the default.</p>
3598 <div class="refsect3">
3599 <a name="hb-buffer-cluster-level-t.members"></a><h4>Members</h4>
3600 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3601 <colgroup>
3602 <col width="300px" class="enum_members_name">
3603 <col class="enum_members_description">
3604 <col width="200px" class="enum_members_annotations">
3605 </colgroup>
3606 <tbody>
3607 <tr>
3608 <td class="enum_member_name"><p><a name="HB-BUFFER-CLUSTER-LEVEL-MONOTONE-GRAPHEMES:CAPS"></a>HB_BUFFER_CLUSTER_LEVEL_MONOTONE_GRAPHEMES</p></td>
3609 <td class="enum_member_description">
3610 <p>Return cluster values grouped by graphemes into
3611 monotone order.</p>
3612 </td>
3613 <td class="enum_member_annotations"> </td>
3614 </tr>
3615 <tr>
3616 <td class="enum_member_name"><p><a name="HB-BUFFER-CLUSTER-LEVEL-MONOTONE-CHARACTERS:CAPS"></a>HB_BUFFER_CLUSTER_LEVEL_MONOTONE_CHARACTERS</p></td>
3617 <td class="enum_member_description">
3618 <p>Return cluster values grouped into monotone order.</p>
3619 </td>
3620 <td class="enum_member_annotations"> </td>
3621 </tr>
3622 <tr>
3623 <td class="enum_member_name"><p><a name="HB-BUFFER-CLUSTER-LEVEL-CHARACTERS:CAPS"></a>HB_BUFFER_CLUSTER_LEVEL_CHARACTERS</p></td>
3624 <td class="enum_member_description">
3625 <p>Don't group cluster values.</p>
3626 </td>
3627 <td class="enum_member_annotations"> </td>
3628 </tr>
3629 <tr>
3630 <td class="enum_member_name"><p><a name="HB-BUFFER-CLUSTER-LEVEL-DEFAULT:CAPS"></a>HB_BUFFER_CLUSTER_LEVEL_DEFAULT</p></td>
3631 <td class="enum_member_description">
3632 <p>Default cluster level,
3633 equal to <em class="parameter"><code>HB_BUFFER_CLUSTER_LEVEL_MONOTONE_GRAPHEMES</code></em>
3634 .</p>
3635 </td>
3636 <td class="enum_member_annotations"> </td>
3637 </tr>
3638 </tbody>
3639 </table></div>
3640 </div>
3641 <p class="since">Since: <a class="link" href="api-index-0-9-42.html#api-index-0.9.42">0.9.42</a></p>
3642 </div>
3643 <hr>
3644 <div class="refsect2">
3645 <a name="hb-segment-properties-t"></a><h3>hb_segment_properties_t</h3>
3646 <pre class="programlisting">typedef struct {
3647   hb_direction_t  direction;
3648   hb_script_t     script;
3649   hb_language_t   language;
3650 } hb_segment_properties_t;
3651 </pre>
3652 <p>The structure that holds various text properties of an <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a>. Can be
3653 set and retrieved using <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-segment-properties" title="hb_buffer_set_segment_properties ()"><code class="function">hb_buffer_set_segment_properties()</code></a> and
3654 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-get-segment-properties" title="hb_buffer_get_segment_properties ()"><code class="function">hb_buffer_get_segment_properties()</code></a>, respectively.</p>
3655 <div class="refsect3">
3656 <a name="hb-segment-properties-t.members"></a><h4>Members</h4>
3657 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3658 <colgroup>
3659 <col width="300px" class="struct_members_name">
3660 <col class="struct_members_description">
3661 <col width="200px" class="struct_members_annotations">
3662 </colgroup>
3663 <tbody>
3664 <tr>
3665 <td class="struct_member_name"><p><a class="link" href="harfbuzz-hb-common.html#hb-direction-t" title="enum hb_direction_t"><span class="type">hb_direction_t</span></a> <em class="structfield"><code><a name="hb-segment-properties-t.direction"></a>direction</code></em>;</p></td>
3666 <td class="struct_member_description"><p>the <a class="link" href="harfbuzz-hb-common.html#hb-direction-t" title="enum hb_direction_t"><span class="type">hb_direction_t</span></a> of the buffer, see <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-direction" title="hb_buffer_set_direction ()"><code class="function">hb_buffer_set_direction()</code></a>.</p></td>
3667 <td class="struct_member_annotations"> </td>
3668 </tr>
3669 <tr>
3670 <td class="struct_member_name"><p><a class="link" href="harfbuzz-hb-common.html#hb-script-t" title="enum hb_script_t"><span class="type">hb_script_t</span></a> <em class="structfield"><code><a name="hb-segment-properties-t.script"></a>script</code></em>;</p></td>
3671 <td class="struct_member_description"><p>the <a class="link" href="harfbuzz-hb-common.html#hb-script-t" title="enum hb_script_t"><span class="type">hb_script_t</span></a> of the buffer, see <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-script" title="hb_buffer_set_script ()"><code class="function">hb_buffer_set_script()</code></a>.</p></td>
3672 <td class="struct_member_annotations"> </td>
3673 </tr>
3674 <tr>
3675 <td class="struct_member_name"><p><a class="link" href="harfbuzz-hb-common.html#hb-language-t" title="hb_language_t"><span class="type">hb_language_t</span></a> <em class="structfield"><code><a name="hb-segment-properties-t.language"></a>language</code></em>;</p></td>
3676 <td class="struct_member_description"><p>the <a class="link" href="harfbuzz-hb-common.html#hb-language-t" title="hb_language_t"><span class="type">hb_language_t</span></a> of the buffer, see <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-set-language" title="hb_buffer_set_language ()"><code class="function">hb_buffer_set_language()</code></a>.</p></td>
3677 <td class="struct_member_annotations"> </td>
3678 </tr>
3679 </tbody>
3680 </table></div>
3681 </div>
3682 </div>
3683 <hr>
3684 <div class="refsect2">
3685 <a name="hb-buffer-serialize-format-t"></a><h3>enum hb_buffer_serialize_format_t</h3>
3686 <p>The buffer serialization and de-serialization format used in
3687 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-glyphs" title="hb_buffer_serialize_glyphs ()"><code class="function">hb_buffer_serialize_glyphs()</code></a> and <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-deserialize-glyphs" title="hb_buffer_deserialize_glyphs ()"><code class="function">hb_buffer_deserialize_glyphs()</code></a>.</p>
3688 <div class="refsect3">
3689 <a name="hb-buffer-serialize-format-t.members"></a><h4>Members</h4>
3690 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3691 <colgroup>
3692 <col width="300px" class="enum_members_name">
3693 <col class="enum_members_description">
3694 <col width="200px" class="enum_members_annotations">
3695 </colgroup>
3696 <tbody>
3697 <tr>
3698 <td class="enum_member_name"><p><a name="HB-BUFFER-SERIALIZE-FORMAT-TEXT:CAPS"></a>HB_BUFFER_SERIALIZE_FORMAT_TEXT</p></td>
3699 <td class="enum_member_description">
3700 <p>a human-readable, plain text format.</p>
3701 </td>
3702 <td class="enum_member_annotations"> </td>
3703 </tr>
3704 <tr>
3705 <td class="enum_member_name"><p><a name="HB-BUFFER-SERIALIZE-FORMAT-JSON:CAPS"></a>HB_BUFFER_SERIALIZE_FORMAT_JSON</p></td>
3706 <td class="enum_member_description">
3707 <p>a machine-readable JSON format.</p>
3708 </td>
3709 <td class="enum_member_annotations"> </td>
3710 </tr>
3711 <tr>
3712 <td class="enum_member_name"><p><a name="HB-BUFFER-SERIALIZE-FORMAT-INVALID:CAPS"></a>HB_BUFFER_SERIALIZE_FORMAT_INVALID</p></td>
3713 <td class="enum_member_description">
3714 <p>invalid format.</p>
3715 </td>
3716 <td class="enum_member_annotations"> </td>
3717 </tr>
3718 </tbody>
3719 </table></div>
3720 </div>
3721 <p class="since">Since: <a class="link" href="api-index-0-9-2.html#api-index-0.9.2">0.9.2</a></p>
3722 </div>
3723 <hr>
3724 <div class="refsect2">
3725 <a name="hb-buffer-serialize-flags-t"></a><h3>enum hb_buffer_serialize_flags_t</h3>
3726 <p>Flags that control what glyph information are serialized in <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-serialize-glyphs" title="hb_buffer_serialize_glyphs ()"><code class="function">hb_buffer_serialize_glyphs()</code></a>.</p>
3727 <div class="refsect3">
3728 <a name="hb-buffer-serialize-flags-t.members"></a><h4>Members</h4>
3729 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3730 <colgroup>
3731 <col width="300px" class="enum_members_name">
3732 <col class="enum_members_description">
3733 <col width="200px" class="enum_members_annotations">
3734 </colgroup>
3735 <tbody>
3736 <tr>
3737 <td class="enum_member_name"><p><a name="HB-BUFFER-SERIALIZE-FLAG-DEFAULT:CAPS"></a>HB_BUFFER_SERIALIZE_FLAG_DEFAULT</p></td>
3738 <td class="enum_member_description">
3739 <p>serialize glyph names, clusters and positions.</p>
3740 </td>
3741 <td class="enum_member_annotations"> </td>
3742 </tr>
3743 <tr>
3744 <td class="enum_member_name"><p><a name="HB-BUFFER-SERIALIZE-FLAG-NO-CLUSTERS:CAPS"></a>HB_BUFFER_SERIALIZE_FLAG_NO_CLUSTERS</p></td>
3745 <td class="enum_member_description">
3746 <p>do not serialize glyph cluster.</p>
3747 </td>
3748 <td class="enum_member_annotations"> </td>
3749 </tr>
3750 <tr>
3751 <td class="enum_member_name"><p><a name="HB-BUFFER-SERIALIZE-FLAG-NO-POSITIONS:CAPS"></a>HB_BUFFER_SERIALIZE_FLAG_NO_POSITIONS</p></td>
3752 <td class="enum_member_description">
3753 <p>do not serialize glyph position information.</p>
3754 </td>
3755 <td class="enum_member_annotations"> </td>
3756 </tr>
3757 <tr>
3758 <td class="enum_member_name"><p><a name="HB-BUFFER-SERIALIZE-FLAG-NO-GLYPH-NAMES:CAPS"></a>HB_BUFFER_SERIALIZE_FLAG_NO_GLYPH_NAMES</p></td>
3759 <td class="enum_member_description">
3760 <p>do no serialize glyph name.</p>
3761 </td>
3762 <td class="enum_member_annotations"> </td>
3763 </tr>
3764 <tr>
3765 <td class="enum_member_name"><p><a name="HB-BUFFER-SERIALIZE-FLAG-GLYPH-EXTENTS:CAPS"></a>HB_BUFFER_SERIALIZE_FLAG_GLYPH_EXTENTS</p></td>
3766 <td class="enum_member_description">
3767 <p>serialize glyph extents.</p>
3768 </td>
3769 <td class="enum_member_annotations"> </td>
3770 </tr>
3771 <tr>
3772 <td class="enum_member_name"><p><a name="HB-BUFFER-SERIALIZE-FLAG-GLYPH-FLAGS:CAPS"></a>HB_BUFFER_SERIALIZE_FLAG_GLYPH_FLAGS</p></td>
3773 <td class="enum_member_description">
3774 <p>serialize glyph flags. Since: 1.5.0</p>
3775 </td>
3776 <td class="enum_member_annotations"> </td>
3777 </tr>
3778 <tr>
3779 <td class="enum_member_name"><p><a name="HB-BUFFER-SERIALIZE-FLAG-NO-ADVANCES:CAPS"></a>HB_BUFFER_SERIALIZE_FLAG_NO_ADVANCES</p></td>
3780 <td class="enum_member_description">
3781 <p>do not serialize glyph advances,
3782 glyph offsets will reflect absolute glyph positions. Since: 1.8.0</p>
3783 </td>
3784 <td class="enum_member_annotations"> </td>
3785 </tr>
3786 </tbody>
3787 </table></div>
3788 </div>
3789 <p class="since">Since: <a class="link" href="api-index-0-9-20.html#api-index-0.9.20">0.9.20</a></p>
3790 </div>
3791 <hr>
3792 <div class="refsect2">
3793 <a name="hb-buffer-diff-flags-t"></a><h3>enum hb_buffer_diff_flags_t</h3>
3794 <p>Flags from comparing two <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-t" title="hb_buffer_t"><span class="type">hb_buffer_t</span></a>'s.</p>
3795 <p>Buffer with different <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-content-type-t" title="enum hb_buffer_content_type_t"><span class="type">hb_buffer_content_type_t</span></a> cannot be meaningfully
3796 compared in any further detail.</p>
3797 <p>For buffers with differing length, the per-glyph comparison is not
3798 attempted, though we do still scan reference buffer for dotted circle and
3799 <code class="literal">.notdef</code> glyphs.</p>
3800 <p>If the buffers have the same length, we compare them glyph-by-glyph and
3801 report which aspect(s) of the glyph info/position are different.</p>
3802 <div class="refsect3">
3803 <a name="hb-buffer-diff-flags-t.members"></a><h4>Members</h4>
3804 <div class="informaltable"><table class="informaltable" width="100%" border="0">
3805 <colgroup>
3806 <col width="300px" class="enum_members_name">
3807 <col class="enum_members_description">
3808 <col width="200px" class="enum_members_annotations">
3809 </colgroup>
3810 <tbody>
3811 <tr>
3812 <td class="enum_member_name"><p><a name="HB-BUFFER-DIFF-FLAG-EQUAL:CAPS"></a>HB_BUFFER_DIFF_FLAG_EQUAL</p></td>
3813 <td class="enum_member_description">
3814 <p>equal buffers.</p>
3815 </td>
3816 <td class="enum_member_annotations"> </td>
3817 </tr>
3818 <tr>
3819 <td class="enum_member_name"><p><a name="HB-BUFFER-DIFF-FLAG-CONTENT-TYPE-MISMATCH:CAPS"></a>HB_BUFFER_DIFF_FLAG_CONTENT_TYPE_MISMATCH</p></td>
3820 <td class="enum_member_description">
3821 <p>buffers with different
3822 <a class="link" href="harfbuzz-hb-buffer.html#hb-buffer-content-type-t" title="enum hb_buffer_content_type_t"><span class="type">hb_buffer_content_type_t</span></a>.</p>
3823 </td>
3824 <td class="enum_member_annotations"> </td>
3825 </tr>
3826 <tr>
3827 <td class="enum_member_name"><p><a name="HB-BUFFER-DIFF-FLAG-LENGTH-MISMATCH:CAPS"></a>HB_BUFFER_DIFF_FLAG_LENGTH_MISMATCH</p></td>
3828 <td class="enum_member_description">
3829 <p>buffers with differing length.</p>
3830 </td>
3831 <td class="enum_member_annotations"> </td>
3832 </tr>
3833 <tr>
3834 <td class="enum_member_name"><p><a name="HB-BUFFER-DIFF-FLAG-NOTDEF-PRESENT:CAPS"></a>HB_BUFFER_DIFF_FLAG_NOTDEF_PRESENT</p></td>
3835 <td class="enum_member_description">
3836 <p><code class="literal">.notdef</code> glyph is present in the
3837 reference buffer.</p>
3838 </td>
3839 <td class="enum_member_annotations"> </td>
3840 </tr>
3841 <tr>
3842 <td class="enum_member_name"><p><a name="HB-BUFFER-DIFF-FLAG-DOTTED-CIRCLE-PRESENT:CAPS"></a>HB_BUFFER_DIFF_FLAG_DOTTED_CIRCLE_PRESENT</p></td>
3843 <td class="enum_member_description">
3844 <p>dotted circle glyph is present
3845 in the reference buffer.</p>
3846 </td>
3847 <td class="enum_member_annotations"> </td>
3848 </tr>
3849 <tr>
3850 <td class="enum_member_name"><p><a name="HB-BUFFER-DIFF-FLAG-CODEPOINT-MISMATCH:CAPS"></a>HB_BUFFER_DIFF_FLAG_CODEPOINT_MISMATCH</p></td>
3851 <td class="enum_member_description">
3852 <p>difference in <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t.codepoint"><span class="type">hb_glyph_info_t.codepoint</span></a></p>
3853 </td>
3854 <td class="enum_member_annotations"> </td>
3855 </tr>
3856 <tr>
3857 <td class="enum_member_name"><p><a name="HB-BUFFER-DIFF-FLAG-CLUSTER-MISMATCH:CAPS"></a>HB_BUFFER_DIFF_FLAG_CLUSTER_MISMATCH</p></td>
3858 <td class="enum_member_description">
3859 <p>difference in <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-info-t.cluster"><span class="type">hb_glyph_info_t.cluster</span></a></p>
3860 </td>
3861 <td class="enum_member_annotations"> </td>
3862 </tr>
3863 <tr>
3864 <td class="enum_member_name"><p><a name="HB-BUFFER-DIFF-FLAG-GLYPH-FLAGS-MISMATCH:CAPS"></a>HB_BUFFER_DIFF_FLAG_GLYPH_FLAGS_MISMATCH</p></td>
3865 <td class="enum_member_description">
3866 <p>difference in <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-flags-t" title="enum hb_glyph_flags_t"><span class="type">hb_glyph_flags_t</span></a>.</p>
3867 </td>
3868 <td class="enum_member_annotations"> </td>
3869 </tr>
3870 <tr>
3871 <td class="enum_member_name"><p><a name="HB-BUFFER-DIFF-FLAG-POSITION-MISMATCH:CAPS"></a>HB_BUFFER_DIFF_FLAG_POSITION_MISMATCH</p></td>
3872 <td class="enum_member_description">
3873 <p>difference in <a class="link" href="harfbuzz-hb-buffer.html#hb-glyph-position-t" title="hb_glyph_position_t"><span class="type">hb_glyph_position_t</span></a>.</p>
3874 </td>
3875 <td class="enum_member_annotations"> </td>
3876 </tr>
3877 </tbody>
3878 </table></div>
3879 </div>
3880 <p class="since">Since: <a class="link" href="api-index-1-5-0.html#api-index-1.5.0">1.5.0</a></p>
3881 </div>
3882 </div>
3883 </div>
3884 <div class="footer">
3885 <hr>Generated by GTK-Doc V1.32</div>
3886 </body>
3887 </html>