hb-unicode.cc 14.1 KB
Newer Older
B
Behdad Esfahbod 已提交
1
/*
B
Behdad Esfahbod 已提交
2
 * Copyright © 2009  Red Hat, Inc.
3 4
 * Copyright © 2011  Codethink Limited
 * Copyright © 2010,2011,2012  Google, Inc.
B
Behdad Esfahbod 已提交
5
 *
B
Behdad Esfahbod 已提交
6
 *  This is part of HarfBuzz, a text shaping library.
B
Behdad Esfahbod 已提交
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
 *
 * Permission is hereby granted, without written agreement and without
 * license or royalty fees, to use, copy, modify, and distribute this
 * software and its documentation for any purpose, provided that the
 * above copyright notice and the following two paragraphs appear in
 * all copies of this software.
 *
 * IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE TO ANY PARTY FOR
 * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES
 * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN
 * IF THE COPYRIGHT HOLDER HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
 * DAMAGE.
 *
 * THE COPYRIGHT HOLDER SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING,
 * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
 * FITNESS FOR A PARTICULAR PURPOSE.  THE SOFTWARE PROVIDED HEREUNDER IS
 * ON AN "AS IS" BASIS, AND THE COPYRIGHT HOLDER HAS NO OBLIGATION TO
 * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
 *
 * Red Hat Author(s): Behdad Esfahbod
27
 * Codethink Author(s): Ryan Lortie
28
 * Google Author(s): Behdad Esfahbod
B
Behdad Esfahbod 已提交
29 30
 */

31
#include "hb.hh"
B
Behdad Esfahbod 已提交
32

33
#include "hb-unicode.hh"
B
Behdad Esfahbod 已提交
34

B
Behdad Esfahbod 已提交
35

B
Behdad Esfahbod 已提交
36 37
/**
 * SECTION: hb-unicode
38
 * @title: hb-unicode
B
Behdad Esfahbod 已提交
39 40 41 42 43 44 45 46 47 48 49
 * @short_description: Unicode character property access
 * @include: hb.h
 *
 * Unicode functions are used to access Unicode character properties.
 * Client can pass its own Unicode functions to HarfBuzz, or access
 * the built-in Unicode functions that come with HarfBuzz.
 *
 * With the Unicode functions, one can query variour Unicode character
 * properties, such as General Category, Script, Combining Class, etc.
 **/

B
Behdad Esfahbod 已提交
50

B
Behdad Esfahbod 已提交
51 52 53 54
/*
 * hb_unicode_funcs_t
 */

55
static hb_unicode_combining_class_t
56 57 58
hb_unicode_combining_class_nil (hb_unicode_funcs_t *ufuncs    HB_UNUSED,
				hb_codepoint_t      unicode   HB_UNUSED,
				void               *user_data HB_UNUSED)
B
Behdad Esfahbod 已提交
59
{
60
  return HB_UNICODE_COMBINING_CLASS_NOT_REORDERED;
61 62
}

63
#ifndef HB_DISABLE_DEPRECATED
B
Behdad Esfahbod 已提交
64
static unsigned int
65 66 67
hb_unicode_eastasian_width_nil (hb_unicode_funcs_t *ufuncs    HB_UNUSED,
				hb_codepoint_t      unicode   HB_UNUSED,
				void               *user_data HB_UNUSED)
B
Behdad Esfahbod 已提交
68 69 70
{
  return 1;
}
71
#endif
B
Behdad Esfahbod 已提交
72 73

static hb_unicode_general_category_t
74 75 76
hb_unicode_general_category_nil (hb_unicode_funcs_t *ufuncs    HB_UNUSED,
				 hb_codepoint_t      unicode   HB_UNUSED,
				 void               *user_data HB_UNUSED)
B
Behdad Esfahbod 已提交
77 78 79 80 81
{
  return HB_UNICODE_GENERAL_CATEGORY_OTHER_LETTER;
}

static hb_codepoint_t
82
hb_unicode_mirroring_nil (hb_unicode_funcs_t *ufuncs    HB_UNUSED,
83
			  hb_codepoint_t      unicode,
84
			  void               *user_data HB_UNUSED)
B
Behdad Esfahbod 已提交
85 86 87 88 89
{
  return unicode;
}

static hb_script_t
90 91 92
hb_unicode_script_nil (hb_unicode_funcs_t *ufuncs    HB_UNUSED,
		       hb_codepoint_t      unicode   HB_UNUSED,
		       void               *user_data HB_UNUSED)
B
Behdad Esfahbod 已提交
93 94 95
{
  return HB_SCRIPT_UNKNOWN;
}
96

97
static hb_bool_t
98
hb_unicode_compose_nil (hb_unicode_funcs_t *ufuncs    HB_UNUSED,
99 100 101 102 103
			hb_codepoint_t      a         HB_UNUSED,
			hb_codepoint_t      b         HB_UNUSED,
			hb_codepoint_t     *ab        HB_UNUSED,
			void               *user_data HB_UNUSED)
{
104
  return false;
105 106 107
}

static hb_bool_t
108
hb_unicode_decompose_nil (hb_unicode_funcs_t *ufuncs    HB_UNUSED,
109 110 111 112 113
			  hb_codepoint_t      ab        HB_UNUSED,
			  hb_codepoint_t     *a         HB_UNUSED,
			  hb_codepoint_t     *b         HB_UNUSED,
			  void               *user_data HB_UNUSED)
{
114
  return false;
115 116
}

117

118
#ifndef HB_DISABLE_DEPRECATED
119 120 121 122 123 124 125 126
static unsigned int
hb_unicode_decompose_compatibility_nil (hb_unicode_funcs_t *ufuncs     HB_UNUSED,
					hb_codepoint_t      u          HB_UNUSED,
					hb_codepoint_t     *decomposed HB_UNUSED,
					void               *user_data  HB_UNUSED)
{
  return 0;
}
127
#endif
128

129

130
extern "C" hb_unicode_funcs_t *hb_ucd_get_unicode_funcs ();
131 132
extern "C" hb_unicode_funcs_t *hb_glib_get_unicode_funcs ();
extern "C" hb_unicode_funcs_t *hb_icu_get_unicode_funcs ();
133

134
hb_unicode_funcs_t *
135
hb_unicode_funcs_get_default ()
136
{
137 138
#if !defined(HB_NO_UNICODE_FUNCS) && !defined(HB_NO_UCD)
  return hb_ucd_get_unicode_funcs ();
139
#elif !defined(HB_NO_UNICODE_FUNCS) && defined(HAVE_GLIB)
140
  return hb_glib_get_unicode_funcs ();
141
#elif !defined(HB_NO_UNICODE_FUNCS) && defined(HAVE_ICU) && defined(HAVE_ICU_BUILTIN)
142
  return hb_icu_get_unicode_funcs ();
143 144
#else
#define HB_UNICODE_FUNCS_NIL 1
145
  return hb_unicode_funcs_get_empty ();
146
#endif
147 148
}

149
#if !defined(HB_NO_UNICODE_FUNCS) && defined(HB_UNICODE_FUNCS_NIL)
150
#error "Could not find any Unicode functions implementation, you have to provide your own"
151
#error "Consider building hb-ucd.cc.  If you absolutely want to build without any, check the code."
B
Behdad Esfahbod 已提交
152
#endif
153

154
/**
155
 * hb_unicode_funcs_create: (Xconstructor)
156
 * @parent: (nullable):
157
 *
158
 *
159 160 161
 *
 * Return value: (transfer full):
 *
B
Behdad Esfahbod 已提交
162
 * Since: 0.9.2
163
 **/
B
Behdad Esfahbod 已提交
164
hb_unicode_funcs_t *
165
hb_unicode_funcs_create (hb_unicode_funcs_t *parent)
B
Behdad Esfahbod 已提交
166 167 168
{
  hb_unicode_funcs_t *ufuncs;

169
  if (!(ufuncs = hb_object_create<hb_unicode_funcs_t> ()))
170
    return hb_unicode_funcs_get_empty ();
B
Behdad Esfahbod 已提交
171

172
  if (!parent)
173
    parent = hb_unicode_funcs_get_empty ();
174

175 176
  hb_unicode_funcs_make_immutable (parent);
  ufuncs->parent = hb_unicode_funcs_reference (parent);
177

178
  ufuncs->func = parent->func;
179 180 181 182 183

  /* We can safely copy user_data from parent since we hold a reference
   * onto it and it's immutable.  We should not copy the destroy notifiers
   * though. */
  ufuncs->user_data = parent->user_data;
184

B
Behdad Esfahbod 已提交
185 186 187
  return ufuncs;
}

188

189 190
DEFINE_NULL_INSTANCE (hb_unicode_funcs_t) =
{
191 192
  HB_OBJECT_HEADER_STATIC,

B
Behdad Esfahbod 已提交
193
  nullptr, /* parent */
194
  {
195
#define HB_UNICODE_FUNC_IMPLEMENT(name) hb_unicode_##name##_nil,
196
    HB_UNICODE_FUNCS_IMPLEMENT_CALLBACKS
197
#undef HB_UNICODE_FUNC_IMPLEMENT
198 199
  }
};
200

201 202 203
/**
 * hb_unicode_funcs_get_empty:
 *
204
 *
205 206 207
 *
 * Return value: (transfer full):
 *
B
Behdad Esfahbod 已提交
208
 * Since: 0.9.2
209
 **/
210
hb_unicode_funcs_t *
211
hb_unicode_funcs_get_empty ()
212
{
213
  return const_cast<hb_unicode_funcs_t *> (&Null(hb_unicode_funcs_t));
214 215
}

216 217 218 219
/**
 * hb_unicode_funcs_reference: (skip)
 * @ufuncs: Unicode functions.
 *
220
 *
221 222 223
 *
 * Return value: (transfer full):
 *
B
Behdad Esfahbod 已提交
224
 * Since: 0.9.2
225
 **/
B
Behdad Esfahbod 已提交
226 227 228
hb_unicode_funcs_t *
hb_unicode_funcs_reference (hb_unicode_funcs_t *ufuncs)
{
229
  return hb_object_reference (ufuncs);
B
Behdad Esfahbod 已提交
230 231
}

232 233 234 235
/**
 * hb_unicode_funcs_destroy: (skip)
 * @ufuncs: Unicode functions.
 *
236
 *
237
 *
B
Behdad Esfahbod 已提交
238
 * Since: 0.9.2
239
 **/
B
Behdad Esfahbod 已提交
240 241 242
void
hb_unicode_funcs_destroy (hb_unicode_funcs_t *ufuncs)
{
243
  if (!hb_object_destroy (ufuncs)) return;
B
Behdad Esfahbod 已提交
244

B
Behdad Esfahbod 已提交
245
#define HB_UNICODE_FUNC_IMPLEMENT(name) \
B
Behdad Esfahbod 已提交
246 247 248
  if (ufuncs->destroy.name) ufuncs->destroy.name (ufuncs->user_data.name);
    HB_UNICODE_FUNCS_IMPLEMENT_CALLBACKS
#undef HB_UNICODE_FUNC_IMPLEMENT
249

250
  hb_unicode_funcs_destroy (ufuncs->parent);
251

B
Behdad Esfahbod 已提交
252 253 254
  free (ufuncs);
}

255 256 257
/**
 * hb_unicode_funcs_set_user_data: (skip)
 * @ufuncs: Unicode functions.
258 259 260 261 262
 * @key:
 * @data:
 * @destroy:
 * @replace:
 *
263 264
 *
 *
265
 * Return value:
266
 *
B
Behdad Esfahbod 已提交
267
 * Since: 0.9.2
268
 **/
269 270 271 272
hb_bool_t
hb_unicode_funcs_set_user_data (hb_unicode_funcs_t *ufuncs,
			        hb_user_data_key_t *key,
			        void *              data,
273 274
			        hb_destroy_func_t   destroy,
				hb_bool_t           replace)
275
{
276
  return hb_object_set_user_data (ufuncs, key, data, destroy, replace);
277 278
}

279 280 281
/**
 * hb_unicode_funcs_get_user_data: (skip)
 * @ufuncs: Unicode functions.
282 283
 * @key:
 *
284 285 286 287
 *
 *
 * Return value: (transfer none):
 *
B
Behdad Esfahbod 已提交
288
 * Since: 0.9.2
289
 **/
290 291 292 293 294 295 296 297
void *
hb_unicode_funcs_get_user_data (hb_unicode_funcs_t *ufuncs,
			        hb_user_data_key_t *key)
{
  return hb_object_get_user_data (ufuncs, key);
}


298 299 300 301
/**
 * hb_unicode_funcs_make_immutable:
 * @ufuncs: Unicode functions.
 *
302
 *
303
 *
B
Behdad Esfahbod 已提交
304
 * Since: 0.9.2
305
 **/
306 307 308
void
hb_unicode_funcs_make_immutable (hb_unicode_funcs_t *ufuncs)
{
309
  if (hb_object_is_immutable (ufuncs))
310
    return;
311

312
  hb_object_make_immutable (ufuncs);
313 314
}

315 316 317 318 319
/**
 * hb_unicode_funcs_is_immutable:
 * @ufuncs: Unicode functions.
 *
 *
320 321
 *
 * Return value:
322
 *
B
Behdad Esfahbod 已提交
323
 * Since: 0.9.2
324
 **/
B
Behdad Esfahbod 已提交
325 326 327
hb_bool_t
hb_unicode_funcs_is_immutable (hb_unicode_funcs_t *ufuncs)
{
328
  return hb_object_is_immutable (ufuncs);
B
Behdad Esfahbod 已提交
329 330
}

331 332 333 334 335
/**
 * hb_unicode_funcs_get_parent:
 * @ufuncs: Unicode functions.
 *
 *
336 337
 *
 * Return value:
338
 *
B
Behdad Esfahbod 已提交
339
 * Since: 0.9.2
340
 **/
341 342 343
hb_unicode_funcs_t *
hb_unicode_funcs_get_parent (hb_unicode_funcs_t *ufuncs)
{
344
  return ufuncs->parent ? ufuncs->parent : hb_unicode_funcs_get_empty ();
345 346
}

B
Behdad Esfahbod 已提交
347

B
Behdad Esfahbod 已提交
348
#define HB_UNICODE_FUNC_IMPLEMENT(name)						\
B
Behdad Esfahbod 已提交
349 350 351
										\
void										\
hb_unicode_funcs_set_##name##_func (hb_unicode_funcs_t		   *ufuncs,	\
352
				    hb_unicode_##name##_func_t	    func,	\
B
Behdad Esfahbod 已提交
353 354 355
				    void			   *user_data,	\
				    hb_destroy_func_t		    destroy)	\
{										\
356
  if (hb_object_is_immutable (ufuncs))						\
B
Behdad Esfahbod 已提交
357 358 359 360 361 362
    return;									\
										\
  if (ufuncs->destroy.name)							\
    ufuncs->destroy.name (ufuncs->user_data.name);				\
										\
  if (func) {									\
363
    ufuncs->func.name = func;							\
B
Behdad Esfahbod 已提交
364 365 366
    ufuncs->user_data.name = user_data;						\
    ufuncs->destroy.name = destroy;						\
  } else {									\
367
    ufuncs->func.name = ufuncs->parent->func.name;				\
B
Behdad Esfahbod 已提交
368
    ufuncs->user_data.name = ufuncs->parent->user_data.name;			\
B
Behdad Esfahbod 已提交
369
    ufuncs->destroy.name = nullptr;						\
B
Behdad Esfahbod 已提交
370
  }										\
B
Behdad Esfahbod 已提交
371 372
}

B
Behdad Esfahbod 已提交
373
HB_UNICODE_FUNCS_IMPLEMENT_CALLBACKS
B
Behdad Esfahbod 已提交
374 375 376 377
#undef HB_UNICODE_FUNC_IMPLEMENT


#define HB_UNICODE_FUNC_IMPLEMENT(return_type, name)				\
B
Behdad Esfahbod 已提交
378 379
										\
return_type									\
380 381
hb_unicode_##name (hb_unicode_funcs_t *ufuncs,					\
		   hb_codepoint_t      unicode)					\
B
Behdad Esfahbod 已提交
382
{										\
B
Behdad Esfahbod 已提交
383
  return ufuncs->name (unicode);						\
B
Behdad Esfahbod 已提交
384
}
B
Behdad Esfahbod 已提交
385
HB_UNICODE_FUNCS_IMPLEMENT_CALLBACKS_SIMPLE
B
Behdad Esfahbod 已提交
386
#undef HB_UNICODE_FUNC_IMPLEMENT
B
Behdad Esfahbod 已提交
387

388 389 390
/**
 * hb_unicode_compose:
 * @ufuncs: Unicode functions.
391 392
 * @a:
 * @b:
393 394 395
 * @ab: (out):
 *
 *
396 397
 *
 * Return value:
398
 *
S
Sascha Brawer 已提交
399
 * Since: 0.9.2
400
 **/
401 402 403 404 405 406
hb_bool_t
hb_unicode_compose (hb_unicode_funcs_t *ufuncs,
		    hb_codepoint_t      a,
		    hb_codepoint_t      b,
		    hb_codepoint_t     *ab)
{
B
Behdad Esfahbod 已提交
407
  return ufuncs->compose (a, b, ab);
408 409
}

410 411 412
/**
 * hb_unicode_decompose:
 * @ufuncs: Unicode functions.
413
 * @ab:
414 415 416 417
 * @a: (out):
 * @b: (out):
 *
 *
418 419
 *
 * Return value:
420
 *
S
Sascha Brawer 已提交
421
 * Since: 0.9.2
422
 **/
423 424 425 426 427 428
hb_bool_t
hb_unicode_decompose (hb_unicode_funcs_t *ufuncs,
		      hb_codepoint_t      ab,
		      hb_codepoint_t     *a,
		      hb_codepoint_t     *b)
{
B
Behdad Esfahbod 已提交
429
  return ufuncs->decompose (ab, a, b);
430
}
B
Behdad Esfahbod 已提交
431

432
#ifndef HB_DISABLE_DEPRECATED
433 434 435
/**
 * hb_unicode_decompose_compatibility:
 * @ufuncs: Unicode functions.
436
 * @u:
437 438 439
 * @decomposed: (out):
 *
 *
440 441
 *
 * Return value:
442
 *
S
Sascha Brawer 已提交
443
 * Since: 0.9.2
B
Behdad Esfahbod 已提交
444
 * Deprecated: 2.0.0
445
 **/
446 447 448 449 450
unsigned int
hb_unicode_decompose_compatibility (hb_unicode_funcs_t *ufuncs,
				    hb_codepoint_t      u,
				    hb_codepoint_t     *decomposed)
{
B
Behdad Esfahbod 已提交
451
  return ufuncs->decompose_compatibility (u, decomposed);
452
}
453
#endif
B
Behdad Esfahbod 已提交
454 455


456
#ifndef HB_NO_OT_SHAPE
457
/* See hb-unicode.hh for details. */
458 459
const uint8_t
_hb_modified_combining_class[256] =
B
Behdad Esfahbod 已提交
460
{
461 462 463 464 465 466 467 468
  0, /* HB_UNICODE_COMBINING_CLASS_NOT_REORDERED */
  1, /* HB_UNICODE_COMBINING_CLASS_OVERLAY */
  2, 3, 4, 5, 6,
  7, /* HB_UNICODE_COMBINING_CLASS_NUKTA */
  8, /* HB_UNICODE_COMBINING_CLASS_KANA_VOICING */
  9, /* HB_UNICODE_COMBINING_CLASS_VIRAMA */

  /* Hebrew */
469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485
  HB_MODIFIED_COMBINING_CLASS_CCC10,
  HB_MODIFIED_COMBINING_CLASS_CCC11,
  HB_MODIFIED_COMBINING_CLASS_CCC12,
  HB_MODIFIED_COMBINING_CLASS_CCC13,
  HB_MODIFIED_COMBINING_CLASS_CCC14,
  HB_MODIFIED_COMBINING_CLASS_CCC15,
  HB_MODIFIED_COMBINING_CLASS_CCC16,
  HB_MODIFIED_COMBINING_CLASS_CCC17,
  HB_MODIFIED_COMBINING_CLASS_CCC18,
  HB_MODIFIED_COMBINING_CLASS_CCC19,
  HB_MODIFIED_COMBINING_CLASS_CCC20,
  HB_MODIFIED_COMBINING_CLASS_CCC21,
  HB_MODIFIED_COMBINING_CLASS_CCC22,
  HB_MODIFIED_COMBINING_CLASS_CCC23,
  HB_MODIFIED_COMBINING_CLASS_CCC24,
  HB_MODIFIED_COMBINING_CLASS_CCC25,
  HB_MODIFIED_COMBINING_CLASS_CCC26,
486 487

  /* Arabic */
488 489 490 491 492 493 494 495 496
  HB_MODIFIED_COMBINING_CLASS_CCC27,
  HB_MODIFIED_COMBINING_CLASS_CCC28,
  HB_MODIFIED_COMBINING_CLASS_CCC29,
  HB_MODIFIED_COMBINING_CLASS_CCC30,
  HB_MODIFIED_COMBINING_CLASS_CCC31,
  HB_MODIFIED_COMBINING_CLASS_CCC32,
  HB_MODIFIED_COMBINING_CLASS_CCC33,
  HB_MODIFIED_COMBINING_CLASS_CCC34,
  HB_MODIFIED_COMBINING_CLASS_CCC35,
497 498

  /* Syriac */
499
  HB_MODIFIED_COMBINING_CLASS_CCC36,
500 501 502 503 504 505 506

  37, 38, 39,
  40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59,
  60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
  80, 81, 82, 83,

  /* Telugu */
507
  HB_MODIFIED_COMBINING_CLASS_CCC84,
508
  85, 86, 87, 88, 89, 90,
509
  HB_MODIFIED_COMBINING_CLASS_CCC91,
510 511 512
  92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102,

  /* Thai */
513
  HB_MODIFIED_COMBINING_CLASS_CCC103,
514
  104, 105, 106,
515
  HB_MODIFIED_COMBINING_CLASS_CCC107,
516 517 518
  108, 109, 110, 111, 112, 113, 114, 115, 116, 117,

  /* Lao */
519
  HB_MODIFIED_COMBINING_CLASS_CCC118,
520
  119, 120, 121,
521
  HB_MODIFIED_COMBINING_CLASS_CCC122,
522 523 524
  123, 124, 125, 126, 127, 128,

  /* Tibetan */
525 526
  HB_MODIFIED_COMBINING_CLASS_CCC129,
  HB_MODIFIED_COMBINING_CLASS_CCC130,
527
  131,
528
  HB_MODIFIED_COMBINING_CLASS_CCC132,
529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568
  133, 134, 135, 136, 137, 138, 139,


  140, 141, 142, 143, 144, 145, 146, 147, 148, 149,
  150, 151, 152, 153, 154, 155, 156, 157, 158, 159,
  160, 161, 162, 163, 164, 165, 166, 167, 168, 169,
  170, 171, 172, 173, 174, 175, 176, 177, 178, 179,
  180, 181, 182, 183, 184, 185, 186, 187, 188, 189,
  190, 191, 192, 193, 194, 195, 196, 197, 198, 199,

  200, /* HB_UNICODE_COMBINING_CLASS_ATTACHED_BELOW_LEFT */
  201,
  202, /* HB_UNICODE_COMBINING_CLASS_ATTACHED_BELOW */
  203, 204, 205, 206, 207, 208, 209, 210, 211, 212, 213,
  214, /* HB_UNICODE_COMBINING_CLASS_ATTACHED_ABOVE */
  215,
  216, /* HB_UNICODE_COMBINING_CLASS_ATTACHED_ABOVE_RIGHT */
  217,
  218, /* HB_UNICODE_COMBINING_CLASS_BELOW_LEFT */
  219,
  220, /* HB_UNICODE_COMBINING_CLASS_BELOW */
  221,
  222, /* HB_UNICODE_COMBINING_CLASS_BELOW_RIGHT */
  223,
  224, /* HB_UNICODE_COMBINING_CLASS_LEFT */
  225,
  226, /* HB_UNICODE_COMBINING_CLASS_RIGHT */
  227,
  228, /* HB_UNICODE_COMBINING_CLASS_ABOVE_LEFT */
  229,
  230, /* HB_UNICODE_COMBINING_CLASS_ABOVE */
  231,
  232, /* HB_UNICODE_COMBINING_CLASS_ABOVE_RIGHT */
  233, /* HB_UNICODE_COMBINING_CLASS_DOUBLE_BELOW */
  234, /* HB_UNICODE_COMBINING_CLASS_DOUBLE_ABOVE */
  235, 236, 237, 238, 239,
  240, /* HB_UNICODE_COMBINING_CLASS_IOTA_SUBSCRIPT */
  241, 242, 243, 244, 245, 246, 247, 248, 249, 250, 251, 252, 253, 254,
  255, /* HB_UNICODE_COMBINING_CLASS_INVALID */
};
569
#endif
570 571 572 573 574


/*
 * Emoji
 */
B
Behdad Esfahbod 已提交
575
#ifndef HB_NO_EMOJI
576 577 578 579 580 581

#include "hb-unicode-emoji-table.hh"

bool
_hb_unicode_is_emoji_Extended_Pictographic (hb_codepoint_t cp)
{
582
  return _hb_emoji_is_Extended_Pictographic (cp);
583
}
B
Behdad Esfahbod 已提交
584
#endif