Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(42)

Side by Side Diff: third_party/harfbuzz-ng/src/hb-unicode.h

Issue 70193010: Update harfbuzz-ng to 0.9.24 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « third_party/harfbuzz-ng/src/hb-ucdn.cc ('k') | third_party/harfbuzz-ng/src/hb-unicode.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright © 2009 Red Hat, Inc. 2 * Copyright © 2009 Red Hat, Inc.
3 * Copyright © 2011 Codethink Limited 3 * Copyright © 2011 Codethink Limited
4 * Copyright © 2011,2012 Google, Inc. 4 * Copyright © 2011,2012 Google, Inc.
5 * 5 *
6 * This is part of HarfBuzz, a text shaping library. 6 * This is part of HarfBuzz, a text shaping library.
7 * 7 *
8 * Permission is hereby granted, without written agreement and without 8 * Permission is hereby granted, without written agreement and without
9 * license or royalty fees, to use, copy, modify, and distribute this 9 * license or royalty fees, to use, copy, modify, and distribute this
10 * software and its documentation for any purpose, provided that the 10 * software and its documentation for any purpose, provided that the
(...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after
241 hb_codepoint_t *ab, 241 hb_codepoint_t *ab,
242 void *user_data); 242 void *user_data);
243 typedef hb_bool_t (*hb_unicode_decompose_func_t) (hb_unicode_funcs_t *ufuncs, 243 typedef hb_bool_t (*hb_unicode_decompose_func_t) (hb_unicode_funcs_t *ufuncs,
244 hb_codepoint_t ab, 244 hb_codepoint_t ab,
245 hb_codepoint_t *a, 245 hb_codepoint_t *a,
246 hb_codepoint_t *b, 246 hb_codepoint_t *b,
247 void *user_data); 247 void *user_data);
248 248
249 /** 249 /**
250 * hb_unicode_decompose_compatibility_func_t: 250 * hb_unicode_decompose_compatibility_func_t:
251 * @ufuncs: Unicode function structure 251 * @ufuncs: a Unicode function structure
252 * @u: codepoint to decompose 252 * @u: codepoint to decompose
253 * @decomposed: address of codepoint array (of length %HB_UNICODE_MAX_DECOMPOSIT ION_LEN) to write decomposition into 253 * @decomposed: address of codepoint array (of length %HB_UNICODE_MAX_DECOMPOSIT ION_LEN) to write decomposition into
254 * @user_data: user data pointer as passed to hb_unicode_funcs_set_decompose_com patibility_func() 254 * @user_data: user data pointer as passed to hb_unicode_funcs_set_decompose_com patibility_func()
255 * 255 *
256 * Fully decompose @u to its Unicode compatibility decomposition. The codepoints of the decomposition will be written to @decomposed. 256 * Fully decompose @u to its Unicode compatibility decomposition. The codepoints of the decomposition will be written to @decomposed.
257 * The complete length of the decomposition will be returned. 257 * The complete length of the decomposition will be returned.
258 * 258 *
259 * If @u has no compatibility decomposition, zero should be returned. 259 * If @u has no compatibility decomposition, zero should be returned.
260 * 260 *
261 * The Unicode standard guarantees that a buffer of length %HB_UNICODE_MAX_DECOM POSITION_LEN codepoints will always be sufficient for any 261 * The Unicode standard guarantees that a buffer of length %HB_UNICODE_MAX_DECOM POSITION_LEN codepoints will always be sufficient for any
262 * compatibility decomposition plus an terminating value of 0. Consequently, @d ecompose must be allocated by the caller to be at least this length. Implementa tions 262 * compatibility decomposition plus an terminating value of 0. Consequently, @d ecompose must be allocated by the caller to be at least this length. Implementa tions
263 * of this function type must ensure that they do not write past the provided ar ray. 263 * of this function type must ensure that they do not write past the provided ar ray.
264 * 264 *
265 * Return value: number of codepoints in the full compatibility decomposition of @u, or 0 if no decomposition available. 265 * Return value: number of codepoints in the full compatibility decomposition of @u, or 0 if no decomposition available.
266 */ 266 */
267 typedef unsigned int (*hb_unicode_decompose_compatibility_fun c_t) (hb_unicode_funcs_t *ufuncs, 267 typedef unsigned int (*hb_unicode_decompose_compatibility_fun c_t) (hb_unicode_funcs_t *ufuncs,
268 hb_codepoint_t u, 268 hb_codepoint_t u,
269 hb_codepoint_t *decomposed, 269 hb_codepoint_t *decomposed,
270 void *user_data); 270 void *user_data);
271 271
272 /* See Unicode 6.1 for details on the maximum decomposition length. */ 272 /* See Unicode 6.1 for details on the maximum decomposition length. */
273 #define HB_UNICODE_MAX_DECOMPOSITION_LEN (18+1) /* codepoints */ 273 #define HB_UNICODE_MAX_DECOMPOSITION_LEN (18+1) /* codepoints */
274 274
275 /* setters */ 275 /* setters */
276 276
277 /**
278 * hb_unicode_funcs_set_combining_class_func:
279 * @ufuncs: a Unicode function structure
280 * @func: (closure user_data) (destroy destroy) (scope notified):
281 * @user_data:
282 * @destroy:
283 *
284 *
285 *
286 * Since: 1.0
287 **/
277 void 288 void
278 hb_unicode_funcs_set_combining_class_func (hb_unicode_funcs_t *ufuncs, 289 hb_unicode_funcs_set_combining_class_func (hb_unicode_funcs_t *ufuncs,
279 » » » » » hb_unicode_combining_class_func_t com bining_class_func, 290 » » » » » hb_unicode_combining_class_func_t fun c,
280 void *user_data, hb_destroy_func_t de stroy); 291 void *user_data, hb_destroy_func_t de stroy);
281 292
293 /**
294 * hb_unicode_funcs_set_eastasian_width_func:
295 * @ufuncs: a Unicode function structure
296 * @func: (closure user_data) (destroy destroy) (scope notified):
297 * @user_data:
298 * @destroy:
299 *
300 *
301 *
302 * Since: 1.0
303 **/
282 void 304 void
283 hb_unicode_funcs_set_eastasian_width_func (hb_unicode_funcs_t *ufuncs, 305 hb_unicode_funcs_set_eastasian_width_func (hb_unicode_funcs_t *ufuncs,
284 » » » » » hb_unicode_eastasian_width_func_t eas tasian_width_func, 306 » » » » » hb_unicode_eastasian_width_func_t fun c,
285 void *user_data, hb_destroy_func_t de stroy); 307 void *user_data, hb_destroy_func_t de stroy);
286 308
309 /**
310 * hb_unicode_funcs_set_general_category_func:
311 * @ufuncs: a Unicode function structure
312 * @func: (closure user_data) (destroy destroy) (scope notified):
313 * @user_data:
314 * @destroy:
315 *
316 *
317 *
318 * Since: 1.0
319 **/
287 void 320 void
288 hb_unicode_funcs_set_general_category_func (hb_unicode_funcs_t *ufuncs, 321 hb_unicode_funcs_set_general_category_func (hb_unicode_funcs_t *ufuncs,
289 » » » » » hb_unicode_general_category_func_t g eneral_category_func, 322 » » » » » hb_unicode_general_category_func_t f unc,
290 void *user_data, hb_destroy_func_t d estroy); 323 void *user_data, hb_destroy_func_t d estroy);
291 324
325 /**
326 * hb_unicode_funcs_set_mirroring_func:
327 * @ufuncs: a Unicode function structure
328 * @func: (closure user_data) (destroy destroy) (scope notified):
329 * @user_data:
330 * @destroy:
331 *
332 *
333 *
334 * Since: 1.0
335 **/
292 void 336 void
293 hb_unicode_funcs_set_mirroring_func (hb_unicode_funcs_t *ufuncs, 337 hb_unicode_funcs_set_mirroring_func (hb_unicode_funcs_t *ufuncs,
294 » » » » hb_unicode_mirroring_func_t mirroring_func, 338 » » » » hb_unicode_mirroring_func_t func,
295 void *user_data, hb_destroy_func_t destroy) ; 339 void *user_data, hb_destroy_func_t destroy) ;
296 340
341 /**
342 * hb_unicode_funcs_set_script_func:
343 * @ufuncs: a Unicode function structure
344 * @func: (closure user_data) (destroy destroy) (scope notified):
345 * @user_data:
346 * @destroy:
347 *
348 *
349 *
350 * Since: 1.0
351 **/
297 void 352 void
298 hb_unicode_funcs_set_script_func (hb_unicode_funcs_t *ufuncs, 353 hb_unicode_funcs_set_script_func (hb_unicode_funcs_t *ufuncs,
299 » » » » hb_unicode_script_func_t script_func, 354 » » » » hb_unicode_script_func_t func,
300 void *user_data, hb_destroy_func_t destroy); 355 void *user_data, hb_destroy_func_t destroy);
301 356
357 /**
358 * hb_unicode_funcs_set_compose_func:
359 * @ufuncs: a Unicode function structure
360 * @func: (closure user_data) (destroy destroy) (scope notified):
361 * @user_data:
362 * @destroy:
363 *
364 *
365 *
366 * Since: 1.0
367 **/
302 void 368 void
303 hb_unicode_funcs_set_compose_func (hb_unicode_funcs_t *ufuncs, 369 hb_unicode_funcs_set_compose_func (hb_unicode_funcs_t *ufuncs,
304 » » » » hb_unicode_compose_func_t compose_func, 370 » » » » hb_unicode_compose_func_t func,
305 void *user_data, hb_destroy_func_t destroy); 371 void *user_data, hb_destroy_func_t destroy);
306 372
373 /**
374 * hb_unicode_funcs_set_decompose_func:
375 * @ufuncs: a Unicode function structure
376 * @func: (closure user_data) (destroy destroy) (scope notified):
377 * @user_data:
378 * @destroy:
379 *
380 *
381 *
382 * Since: 1.0
383 **/
307 void 384 void
308 hb_unicode_funcs_set_decompose_func (hb_unicode_funcs_t *ufuncs, 385 hb_unicode_funcs_set_decompose_func (hb_unicode_funcs_t *ufuncs,
309 » » » » hb_unicode_decompose_func_t decompose_func, 386 » » » » hb_unicode_decompose_func_t func,
310 void *user_data, hb_destroy_func_t destroy) ; 387 void *user_data, hb_destroy_func_t destroy) ;
311 388
389 /**
390 * hb_unicode_funcs_set_decompose_compatibility_func:
391 * @ufuncs: a Unicode function structure
392 * @func: (closure user_data) (destroy destroy) (scope notified):
393 * @user_data:
394 * @destroy:
395 *
396 *
397 *
398 * Since: 1.0
399 **/
312 void 400 void
313 hb_unicode_funcs_set_decompose_compatibility_func (hb_unicode_funcs_t *ufuncs, 401 hb_unicode_funcs_set_decompose_compatibility_func (hb_unicode_funcs_t *ufuncs,
314 » » » » » » hb_unicode_decompose_compatib ility_func_t decompose_compatibility_func, 402 » » » » » » hb_unicode_decompose_compatib ility_func_t func,
315 void *user_data, hb_destroy_f unc_t destroy); 403 void *user_data, hb_destroy_f unc_t destroy);
316 404
317 /* accessors */ 405 /* accessors */
318 406
319 hb_unicode_combining_class_t 407 hb_unicode_combining_class_t
320 hb_unicode_combining_class (hb_unicode_funcs_t *ufuncs, 408 hb_unicode_combining_class (hb_unicode_funcs_t *ufuncs,
321 hb_codepoint_t unicode); 409 hb_codepoint_t unicode);
322 410
323 unsigned int 411 unsigned int
324 hb_unicode_eastasian_width (hb_unicode_funcs_t *ufuncs, 412 hb_unicode_eastasian_width (hb_unicode_funcs_t *ufuncs,
(...skipping 23 matching lines...) Expand all
348 hb_codepoint_t *b); 436 hb_codepoint_t *b);
349 437
350 unsigned int 438 unsigned int
351 hb_unicode_decompose_compatibility (hb_unicode_funcs_t *ufuncs, 439 hb_unicode_decompose_compatibility (hb_unicode_funcs_t *ufuncs,
352 hb_codepoint_t u, 440 hb_codepoint_t u,
353 hb_codepoint_t *decomposed); 441 hb_codepoint_t *decomposed);
354 442
355 HB_END_DECLS 443 HB_END_DECLS
356 444
357 #endif /* HB_UNICODE_H */ 445 #endif /* HB_UNICODE_H */
OLDNEW
« no previous file with comments | « third_party/harfbuzz-ng/src/hb-ucdn.cc ('k') | third_party/harfbuzz-ng/src/hb-unicode.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698