/usr/include/icu-le-hb/layout/LETypes.h is in libicu-le-hb-dev 1.0.3+git161113-4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 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 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 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 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 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 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 | /*
*
* (C) Copyright IBM Corp. and others 1998-2013 - All Rights Reserved
*
*/
#ifndef __LETYPES_H
#define __LETYPES_H
#if !defined(LE_USE_CMEMORY) && (defined(U_LAYOUT_IMPLEMENTATION) || defined(U_LAYOUTEX_IMPLEMENTATION) || defined(U_STATIC_IMPLEMENTATION) || defined(U_COMBINED_IMPLEMENTATION))
#define LE_USE_CMEMORY
#endif
#include "unicode/utypes.h"
#ifdef __cplusplus
#include "unicode/uobject.h"
#endif
#ifdef LE_USE_CMEMORY
#include "cmemory.h"
#endif
/*!
* \file
* \brief C API: Basic definitions for the ICU LayoutEngine
*/
/**
* A type used for signed, 32-bit integers.
*
* @stable ICU 2.4
*/
typedef int32_t le_int32;
/**
* A type used for unsigned, 32-bit integers.
*
* @stable ICU 2.4
*/
typedef uint32_t le_uint32;
/**
* A type used for signed, 16-bit integers.
*
* @stable ICU 2.4
*/
typedef int16_t le_int16;
/**
* A type used for unsigned, 16-bit integers.
*
* @stable ICU 2.4
*/
typedef uint16_t le_uint16;
/**
* A type used for signed, 8-bit integers.
*
* @stable ICU 2.4
*/
typedef int8_t le_int8;
/**
* A type used for unsigned, 8-bit integers.
*
* @stable ICU 2.4
*/
typedef uint8_t le_uint8;
/**
* A type used for boolean values.
*
* @stable ICU 2.4
*/
typedef UBool le_bool;
#ifndef NULL
/**
* Used to represent empty pointers.
*
* @stable ICU 2.4
*/
#define NULL 0
#endif
/**
* Used for four character tags.
*
* @stable ICU 2.4
*/
typedef le_uint32 LETag;
/**
* Used for 16-bit glyph indices as they're represented
* in TrueType font tables.
*
* @stable ICU 3.2
*/
typedef le_uint16 TTGlyphID;
/**
* Used for glyph indices. The low-order 16 bits are
* the glyph ID within the font. The next 8 bits are
* the sub-font ID within a compound font. The high-
* order 8 bits are client defined. The LayoutEngine
* will never change or look at the client defined bits.
*
* @stable ICU 3.2
*/
typedef le_uint32 LEGlyphID;
/**
* Used to mask off the glyph ID part of an LEGlyphID.
*
* @see LEGlyphID
* @stable ICU 3.2
*/
#define LE_GLYPH_MASK 0x0000FFFF
/**
* Used to shift the glyph ID part of an LEGlyphID
* into the low-order bits.
*
* @see LEGlyphID
* @stable ICU 3.2
*/
#define LE_GLYPH_SHIFT 0
/**
* Used to mask off the sub-font ID part of an LEGlyphID.
*
* @see LEGlyphID
* @stable ICU 3.2
*/
#define LE_SUB_FONT_MASK 0x00FF0000
/**
* Used to shift the sub-font ID part of an LEGlyphID
* into the low-order bits.
*
* @see LEGlyphID
* @stable ICU 3.2
*/
#define LE_SUB_FONT_SHIFT 16
/**
* Used to mask off the client-defined part of an LEGlyphID.
*
* @see LEGlyphID
* @stable ICU 3.2
*/
#define LE_CLIENT_MASK 0xFF000000
/**
* Used to shift the sub-font ID part of an LEGlyphID
* into the low-order bits.
*
* @see LEGlyphID
* @stable ICU 3.2
*/
#define LE_CLIENT_SHIFT 24
/**
* A convenience macro to get the Glyph ID part of an LEGlyphID.
*
* @see LEGlyphID
* @stable ICU 3.2
*/
#define LE_GET_GLYPH(gid) ((gid & LE_GLYPH_MASK) >> LE_GLYPH_SHIFT)
/**
* A convenience macro to get the sub-font ID part of an LEGlyphID.
*
* @see LEGlyphID
* @stable ICU 3.2
*/
#define LE_GET_SUB_FONT(gid) ((gid & LE_SUB_FONT_MASK) >> LE_SUB_FONT_SHIFT)
/**
* A convenience macro to get the client-defined part of an LEGlyphID.
*
* @see LEGlyphID
* @stable ICU 3.2
*/
#define LE_GET_CLIENT(gid) ((gid & LE_CLIENT_MASK) >> LE_CLIENT_SHIFT)
/**
* A convenience macro to set the Glyph ID part of an LEGlyphID.
*
* @see LEGlyphID
* @stable ICU 3.2
*/
#define LE_SET_GLYPH(gid, glyph) ((gid & ~LE_GLYPH_MASK) | ((glyph << LE_GLYPH_SHIFT) & LE_GLYPH_MASK))
/**
* A convenience macro to set the sub-font ID part of an LEGlyphID.
*
* @see LEGlyphID
* @stable ICU 3.2
*/
#define LE_SET_SUB_FONT(gid, font) ((gid & ~LE_SUB_FONT_MASK) | ((font << LE_SUB_FONT_SHIFT) & LE_SUB_FONT_MASK))
/**
* A convenience macro to set the client-defined part of an LEGlyphID.
*
* @see LEGlyphID
* @stable ICU 3.2
*/
#define LE_SET_CLIENT(gid, client) ((gid & ~LE_CLIENT_MASK) | ((client << LE_CLIENT_SHIFT) & LE_CLIENT_MASK))
/**
* Used to represent 16-bit Unicode code points.
*
* @stable ICU 2.4
*/
typedef UChar LEUnicode16;
/**
* Used to represent 32-bit Unicode code points.
*
* @stable ICU 2.4
*/
typedef UChar32 LEUnicode32;
#ifndef U_HIDE_DEPRECATED_API
/**
* Used to represent 16-bit Unicode code points.
*
* @deprecated since ICU 2.4. Use LEUnicode16 instead
*/
typedef UChar LEUnicode;
#endif /* U_HIDE_DEPRECATED_API */
/**
* Used to hold a pair of (x, y) values which represent a point.
*
* @stable ICU 2.4
*/
struct LEPoint
{
/**
* The x coordinate of the point.
*
* @stable ICU 2.4
*/
float fX;
/**
* The y coordinate of the point.
*
* @stable ICU 2.4
*/
float fY;
};
#ifndef __cplusplus
/**
* Used to hold a pair of (x, y) values which represent a point.
*
* @stable ICU 2.4
*/
typedef struct LEPoint LEPoint;
#endif
#ifndef U_HIDE_INTERNAL_API
#ifndef LE_ASSERT_BAD_FONT
#define LE_ASSERT_BAD_FONT 0
#endif
#if LE_ASSERT_BAD_FONT
#include <stdio.h>
#define LE_DEBUG_BAD_FONT(x) fprintf(stderr,"%s:%d: BAD FONT: %s\n", __FILE__, __LINE__, (x));
#else
#define LE_DEBUG_BAD_FONT(x)
#endif
/**
* Max value representable by a uintptr
*/
#ifndef UINT32_MAX
#define LE_UINT32_MAX 0xFFFFFFFFU
#else
#define LE_UINT32_MAX UINT32_MAX
#endif
#ifndef UINTPTR_MAX
#define LE_UINTPTR_MAX LE_UINT32_MAX
#else
#define LE_UINTPTR_MAX UINTPTR_MAX
#endif
/**
* Range check for overflow
*/
#define LE_RANGE_CHECK(type, count, ptrfn) (( (LE_UINTPTR_MAX / sizeof(type)) < (count) ) ? NULL : (ptrfn))
/**
* A convenience macro to get the length of an array.
*
* @internal
*/
#define LE_ARRAY_SIZE(array) (sizeof array / sizeof array[0])
#ifdef LE_USE_CMEMORY
/**
* A convenience macro for copying an array.
*
* @internal
*/
#define LE_ARRAY_COPY(dst, src, count) uprv_memcpy((void *) (dst), (void *) (src), (count) * sizeof (src)[0])
/**
* Allocate an array of basic types. This is used to isolate the rest of
* the LayoutEngine code from cmemory.h.
*
* @internal
*/
#define LE_NEW_ARRAY(type, count) (type *) LE_RANGE_CHECK(type,count,uprv_malloc((count) * sizeof(type)))
/**
* Re-allocate an array of basic types. This is used to isolate the rest of
* the LayoutEngine code from cmemory.h.
*
* @internal
*/
#define LE_GROW_ARRAY(array, newSize) uprv_realloc((void *) (array), (newSize) * sizeof (array)[0])
/**
* Free an array of basic types. This is used to isolate the rest of
* the LayoutEngine code from cmemory.h.
*
* @internal
*/
#define LE_DELETE_ARRAY(array) uprv_free((void *) (array))
#else
/* Not using ICU memory - use C std lib versions */
#include <stdlib.h>
#include <string.h>
/**
* A convenience macro to get the length of an array.
*
* @internal
*/
#define LE_ARRAY_SIZE(array) (sizeof array / sizeof array[0])
/**
* A convenience macro for copying an array.
*
* @internal
*/
#define LE_ARRAY_COPY(dst, src, count) memcpy((void *) (dst), (void *) (src), (count) * sizeof (src)[0])
/**
* Allocate an array of basic types. This is used to isolate the rest of
* the LayoutEngine code from cmemory.h.
*
* @internal
*/
#define LE_NEW_ARRAY(type, count) LE_RANGE_CHECK(type,count,(type *) malloc((count) * sizeof(type)))
/**
* Re-allocate an array of basic types. This is used to isolate the rest of
* the LayoutEngine code from cmemory.h.
*
* @internal
*/
#define LE_GROW_ARRAY(array, newSize) realloc((void *) (array), (newSize) * sizeof (array)[0])
/**
* Free an array of basic types. This is used to isolate the rest of
* the LayoutEngine code from cmemory.h.
*
* @internal
*/
#define LE_DELETE_ARRAY(array) free((void *) (array))
#endif
#endif /* U_HIDE_INTERNAL_API */
/**
* A macro to construct the four-letter tags used to
* label TrueType tables, and for script, language and
* feature tags in OpenType tables.
*
* WARNING: THIS MACRO WILL ONLY WORK CORRECTLY IF
* THE ARGUMENT CHARACTERS ARE ASCII.
*
* @stable ICU 3.2
*/
#define LE_MAKE_TAG(a, b, c, d) \
(((le_uint32)(a) << 24) | \
((le_uint32)(b) << 16) | \
((le_uint32)(c) << 8) | \
(le_uint32)(d))
/**
* This enumeration defines constants for the standard
* TrueType, OpenType and AAT table tags.
*
* @stable ICU 3.2
*/
enum LETableTags {
LE_ACNT_TABLE_TAG = 0x61636E74UL, /**< 'acnt' */
LE_AVAR_TABLE_TAG = 0x61766172UL, /**< 'avar' */
LE_BASE_TABLE_TAG = 0x42415345UL, /**< 'BASE' */
LE_BDAT_TABLE_TAG = 0x62646174UL, /**< 'bdat' */
LE_BHED_TABLE_TAG = 0x62686564UL, /**< 'bhed' */
LE_BLOC_TABLE_TAG = 0x626C6F63UL, /**< 'bloc' */
LE_BSLN_TABLE_TAG = 0x62736C6EUL, /**< 'bsln' */
LE_CFF__TABLE_TAG = 0x43464620UL, /**< 'CFF ' */
LE_CMAP_TABLE_TAG = 0x636D6170UL, /**< 'cmap' */
LE_CVAR_TABLE_TAG = 0x63766172UL, /**< 'cvar' */
LE_CVT__TABLE_TAG = 0x63767420UL, /**< 'cvt ' */
LE_DSIG_TABLE_TAG = 0x44534947UL, /**< 'DSIG' */
LE_EBDT_TABLE_TAG = 0x45424454UL, /**< 'EBDT' */
LE_EBLC_TABLE_TAG = 0x45424C43UL, /**< 'EBLC' */
LE_EBSC_TABLE_TAG = 0x45425343UL, /**< 'EBSC' */
LE_FDSC_TABLE_TAG = 0x66647363UL, /**< 'fdsc' */
LE_FEAT_TABLE_TAG = 0x66656174UL, /**< 'feat' */
LE_FMTX_TABLE_TAG = 0x666D7478UL, /**< 'fmtx' */
LE_FPGM_TABLE_TAG = 0x6670676DUL, /**< 'fpgm' */
LE_FVAR_TABLE_TAG = 0x66766172UL, /**< 'fvar' */
LE_GASP_TABLE_TAG = 0x67617370UL, /**< 'gasp' */
LE_GDEF_TABLE_TAG = 0x47444546UL, /**< 'GDEF' */
LE_GLYF_TABLE_TAG = 0x676C7966UL, /**< 'glyf' */
LE_GPOS_TABLE_TAG = 0x47504F53UL, /**< 'GPOS' */
LE_GSUB_TABLE_TAG = 0x47535542UL, /**< 'GSUB' */
LE_GVAR_TABLE_TAG = 0x67766172UL, /**< 'gvar' */
LE_HDMX_TABLE_TAG = 0x68646D78UL, /**< 'hdmx' */
LE_HEAD_TABLE_TAG = 0x68656164UL, /**< 'head' */
LE_HHEA_TABLE_TAG = 0x68686561UL, /**< 'hhea' */
LE_HMTX_TABLE_TAG = 0x686D7478UL, /**< 'hmtx' */
LE_HSTY_TABLE_TAG = 0x68737479UL, /**< 'hsty' */
LE_JUST_TABLE_TAG = 0x6A757374UL, /**< 'just' */
LE_JSTF_TABLE_TAG = 0x4A535446UL, /**< 'JSTF' */
LE_KERN_TABLE_TAG = 0x6B65726EUL, /**< 'kern' */
LE_LCAR_TABLE_TAG = 0x6C636172UL, /**< 'lcar' */
LE_LOCA_TABLE_TAG = 0x6C6F6361UL, /**< 'loca' */
LE_LTSH_TABLE_TAG = 0x4C545348UL, /**< 'LTSH' */
LE_MAXP_TABLE_TAG = 0x6D617870UL, /**< 'maxp' */
LE_MORT_TABLE_TAG = 0x6D6F7274UL, /**< 'mort' */
LE_MORX_TABLE_TAG = 0x6D6F7278UL, /**< 'morx' */
LE_NAME_TABLE_TAG = 0x6E616D65UL, /**< 'name' */
LE_OPBD_TABLE_TAG = 0x6F706264UL, /**< 'opbd' */
LE_OS_2_TABLE_TAG = 0x4F532F32UL, /**< 'OS/2' */
LE_PCLT_TABLE_TAG = 0x50434C54UL, /**< 'PCLT' */
LE_POST_TABLE_TAG = 0x706F7374UL, /**< 'post' */
LE_PREP_TABLE_TAG = 0x70726570UL, /**< 'prep' */
LE_PROP_TABLE_TAG = 0x70726F70UL, /**< 'prop' */
LE_TRAK_TABLE_TAG = 0x7472616BUL, /**< 'trak' */
LE_VDMX_TABLE_TAG = 0x56444D58UL, /**< 'VDMX' */
LE_VHEA_TABLE_TAG = 0x76686561UL, /**< 'vhea' */
LE_VMTX_TABLE_TAG = 0x766D7478UL, /**< 'vmtx' */
LE_VORG_TABLE_TAG = 0x564F5247UL, /**< 'VORG' */
LE_ZAPF_TABLE_TAG = 0x5A617066UL /**< 'Zapf' */
};
/**
* This enumeration defines constants for all
* the common OpenType feature tags.
*
* @stable ICU 3.2
*/
enum LEFeatureTags {
LE_AALT_FEATURE_TAG = 0x61616C74UL, /**< 'aalt' */
LE_ABVF_FEATURE_TAG = 0x61627666UL, /**< 'abvf' */
LE_ABVM_FEATURE_TAG = 0x6162766DUL, /**< 'abvm' */
LE_ABVS_FEATURE_TAG = 0x61627673UL, /**< 'abvs' */
LE_AFRC_FEATURE_TAG = 0x61667263UL, /**< 'afrc' */
LE_AKHN_FEATURE_TAG = 0x616B686EUL, /**< 'akhn' */
LE_BLWF_FEATURE_TAG = 0x626C7766UL, /**< 'blwf' */
LE_BLWM_FEATURE_TAG = 0x626C776DUL, /**< 'blwm' */
LE_BLWS_FEATURE_TAG = 0x626C7773UL, /**< 'blws' */
LE_CALT_FEATURE_TAG = 0x63616C74UL, /**< 'calt' */
LE_CASE_FEATURE_TAG = 0x63617365UL, /**< 'case' */
LE_CCMP_FEATURE_TAG = 0x63636D70UL, /**< 'ccmp' */
LE_CJCT_FEATURE_TAG = 0x636A6374UL, /**< 'cjct' */
LE_CLIG_FEATURE_TAG = 0x636C6967UL, /**< 'clig' */
LE_CPSP_FEATURE_TAG = 0x63707370UL, /**< 'cpsp' */
LE_CSWH_FEATURE_TAG = 0x63737768UL, /**< 'cswh' */
LE_CURS_FEATURE_TAG = 0x63757273UL, /**< 'curs' */
LE_C2SC_FEATURE_TAG = 0x63327363UL, /**< 'c2sc' */
LE_C2PC_FEATURE_TAG = 0x63327063UL, /**< 'c2pc' */
LE_DIST_FEATURE_TAG = 0x64697374UL, /**< 'dist' */
LE_DLIG_FEATURE_TAG = 0x646C6967UL, /**< 'dlig' */
LE_DNOM_FEATURE_TAG = 0x646E6F6DUL, /**< 'dnom' */
LE_EXPT_FEATURE_TAG = 0x65787074UL, /**< 'expt' */
LE_FALT_FEATURE_TAG = 0x66616C74UL, /**< 'falt' */
LE_FIN2_FEATURE_TAG = 0x66696E32UL, /**< 'fin2' */
LE_FIN3_FEATURE_TAG = 0x66696E33UL, /**< 'fin3' */
LE_FINA_FEATURE_TAG = 0x66696E61UL, /**< 'fina' */
LE_FRAC_FEATURE_TAG = 0x66726163UL, /**< 'frac' */
LE_FWID_FEATURE_TAG = 0x66776964UL, /**< 'fwid' */
LE_HALF_FEATURE_TAG = 0x68616C66UL, /**< 'half' */
LE_HALN_FEATURE_TAG = 0x68616C6EUL, /**< 'haln' */
LE_HALT_FEATURE_TAG = 0x68616C74UL, /**< 'halt' */
LE_HIST_FEATURE_TAG = 0x68697374UL, /**< 'hist' */
LE_HKNA_FEATURE_TAG = 0x686B6E61UL, /**< 'hkna' */
LE_HLIG_FEATURE_TAG = 0x686C6967UL, /**< 'hlig' */
LE_HNGL_FEATURE_TAG = 0x686E676CUL, /**< 'hngl' */
LE_HWID_FEATURE_TAG = 0x68776964UL, /**< 'hwid' */
LE_INIT_FEATURE_TAG = 0x696E6974UL, /**< 'init' */
LE_ISOL_FEATURE_TAG = 0x69736F6CUL, /**< 'isol' */
LE_ITAL_FEATURE_TAG = 0x6974616CUL, /**< 'ital' */
LE_JALT_FEATURE_TAG = 0x6A616C74UL, /**< 'jalt' */
LE_JP78_FEATURE_TAG = 0x6A703738UL, /**< 'jp78' */
LE_JP83_FEATURE_TAG = 0x6A703833UL, /**< 'jp83' */
LE_JP90_FEATURE_TAG = 0x6A703930UL, /**< 'jp90' */
LE_KERN_FEATURE_TAG = 0x6B65726EUL, /**< 'kern' */
LE_LFBD_FEATURE_TAG = 0x6C666264UL, /**< 'lfbd' */
LE_LIGA_FEATURE_TAG = 0x6C696761UL, /**< 'liga' */
LE_LJMO_FEATURE_TAG = 0x6C6A6D6FUL, /**< 'ljmo' */
LE_LNUM_FEATURE_TAG = 0x6C6E756DUL, /**< 'lnum' */
LE_LOCL_FEATURE_TAG = 0x6C6F636CUL, /**< 'locl' */
LE_MARK_FEATURE_TAG = 0x6D61726BUL, /**< 'mark' */
LE_MED2_FEATURE_TAG = 0x6D656432UL, /**< 'med2' */
LE_MEDI_FEATURE_TAG = 0x6D656469UL, /**< 'medi' */
LE_MGRK_FEATURE_TAG = 0x6D67726BUL, /**< 'mgrk' */
LE_MKMK_FEATURE_TAG = 0x6D6B6D6BUL, /**< 'mkmk' */
LE_MSET_FEATURE_TAG = 0x6D736574UL, /**< 'mset' */
LE_NALT_FEATURE_TAG = 0x6E616C74UL, /**< 'nalt' */
LE_NLCK_FEATURE_TAG = 0x6E6C636BUL, /**< 'nlck' */
LE_NUKT_FEATURE_TAG = 0x6E756B74UL, /**< 'nukt' */
LE_NUMR_FEATURE_TAG = 0x6E756D72UL, /**< 'numr' */
LE_ONUM_FEATURE_TAG = 0x6F6E756DUL, /**< 'onum' */
LE_OPBD_FEATURE_TAG = 0x6F706264UL, /**< 'opbd' */
LE_ORDN_FEATURE_TAG = 0x6F72646EUL, /**< 'ordn' */
LE_ORNM_FEATURE_TAG = 0x6F726E6DUL, /**< 'ornm' */
LE_PALT_FEATURE_TAG = 0x70616C74UL, /**< 'palt' */
LE_PCAP_FEATURE_TAG = 0x70636170UL, /**< 'pcap' */
LE_PNUM_FEATURE_TAG = 0x706E756DUL, /**< 'pnum' */
LE_PREF_FEATURE_TAG = 0x70726566UL, /**< 'pref' */
LE_PRES_FEATURE_TAG = 0x70726573UL, /**< 'pres' */
LE_PSTF_FEATURE_TAG = 0x70737466UL, /**< 'pstf' */
LE_PSTS_FEATURE_TAG = 0x70737473UL, /**< 'psts' */
LE_PWID_FEATURE_TAG = 0x70776964UL, /**< 'pwid' */
LE_QWID_FEATURE_TAG = 0x71776964UL, /**< 'qwid' */
LE_RAND_FEATURE_TAG = 0x72616E64UL, /**< 'rand' */
LE_RLIG_FEATURE_TAG = 0x726C6967UL, /**< 'rlig' */
LE_RPHF_FEATURE_TAG = 0x72706866UL, /**< 'rphf' */
LE_RKRF_FEATURE_TAG = 0x726B7266UL, /**< 'rkrf' */
LE_RTBD_FEATURE_TAG = 0x72746264UL, /**< 'rtbd' */
LE_RTLA_FEATURE_TAG = 0x72746C61UL, /**< 'rtla' */
LE_RUBY_FEATURE_TAG = 0x72756279UL, /**< 'ruby' */
LE_SALT_FEATURE_TAG = 0x73616C74UL, /**< 'salt' */
LE_SINF_FEATURE_TAG = 0x73696E66UL, /**< 'sinf' */
LE_SIZE_FEATURE_TAG = 0x73697A65UL, /**< 'size' */
LE_SMCP_FEATURE_TAG = 0x736D6370UL, /**< 'smcp' */
LE_SMPL_FEATURE_TAG = 0x736D706CUL, /**< 'smpl' */
LE_SS01_FEATURE_TAG = 0x73733031UL, /**< 'ss01' */
LE_SS02_FEATURE_TAG = 0x73733032UL, /**< 'ss02' */
LE_SS03_FEATURE_TAG = 0x73733033UL, /**< 'ss03' */
LE_SS04_FEATURE_TAG = 0x73733034UL, /**< 'ss04' */
LE_SS05_FEATURE_TAG = 0x73733035UL, /**< 'ss05' */
LE_SS06_FEATURE_TAG = 0x73733036UL, /**< 'ss06' */
LE_SS07_FEATURE_TAG = 0x73733037UL, /**< 'ss07' */
LE_SS08_FEATURE_TAG = 0x73733038UL, /**< 'ss08' */
LE_SS09_FEATURE_TAG = 0x73733039UL, /**< 'ss09' */
LE_SS10_FEATURE_TAG = 0x73733130UL, /**< 'ss10' */
LE_SS11_FEATURE_TAG = 0x73733131UL, /**< 'ss11' */
LE_SS12_FEATURE_TAG = 0x73733132UL, /**< 'ss12' */
LE_SS13_FEATURE_TAG = 0x73733133UL, /**< 'ss13' */
LE_SS14_FEATURE_TAG = 0x73733134UL, /**< 'ss14' */
LE_SS15_FEATURE_TAG = 0x73733135UL, /**< 'ss15' */
LE_SS16_FEATURE_TAG = 0x73733136UL, /**< 'ss16' */
LE_SS17_FEATURE_TAG = 0x73733137UL, /**< 'ss17' */
LE_SS18_FEATURE_TAG = 0x73733138UL, /**< 'ss18' */
LE_SS19_FEATURE_TAG = 0x73733139UL, /**< 'ss19' */
LE_SS20_FEATURE_TAG = 0x73733230UL, /**< 'ss20' */
LE_SUBS_FEATURE_TAG = 0x73756273UL, /**< 'subs' */
LE_SUPS_FEATURE_TAG = 0x73757073UL, /**< 'sups' */
LE_SWSH_FEATURE_TAG = 0x73777368UL, /**< 'swsh' */
LE_TITL_FEATURE_TAG = 0x7469746CUL, /**< 'titl' */
LE_TJMO_FEATURE_TAG = 0x746A6D6FUL, /**< 'tjmo' */
LE_TNAM_FEATURE_TAG = 0x746E616DUL, /**< 'tnam' */
LE_TNUM_FEATURE_TAG = 0x746E756DUL, /**< 'tnum' */
LE_TRAD_FEATURE_TAG = 0x74726164UL, /**< 'trad' */
LE_TWID_FEATURE_TAG = 0x74776964UL, /**< 'twid' */
LE_UNIC_FEATURE_TAG = 0x756E6963UL, /**< 'unic' */
LE_VALT_FEATURE_TAG = 0x76616C74UL, /**< 'valt' */
LE_VATU_FEATURE_TAG = 0x76617475UL, /**< 'vatu' */
LE_VERT_FEATURE_TAG = 0x76657274UL, /**< 'vert' */
LE_VHAL_FEATURE_TAG = 0x7668616CUL, /**< 'vhal' */
LE_VJMO_FEATURE_TAG = 0x766A6D6FUL, /**< 'vjmo' */
LE_VKNA_FEATURE_TAG = 0x766B6E61UL, /**< 'vkna' */
LE_VKRN_FEATURE_TAG = 0x766B726EUL, /**< 'vkrn' */
LE_VPAL_FEATURE_TAG = 0x7670616CUL, /**< 'vpal' */
LE_VRT2_FEATURE_TAG = 0x76727432UL, /**< 'vrt2' */
LE_ZERO_FEATURE_TAG = 0x7A65726FUL /**< 'zero' */
};
/**
* @internal
*/
enum LEFeatureENUMs {
LE_Kerning_FEATURE_ENUM = 0, /**< Requests Kerning. Formerly LayoutEngine::kTypoFlagKern */
LE_Ligatures_FEATURE_ENUM = 1, /**< Requests Ligatures. Formerly LayoutEngine::kTypoFlagLiga */
LE_CLIG_FEATURE_ENUM, /**< Feature specific enum */
LE_DLIG_FEATURE_ENUM, /**< Feature specific enum */
LE_HLIG_FEATURE_ENUM, /**< Feature specific enum */
LE_LIGA_FEATURE_ENUM, /**< Feature specific enum */
LE_RLIG_FEATURE_ENUM, /**< Feature specific enum */
LE_SMCP_FEATURE_ENUM, /**< Feature specific enum */
LE_FRAC_FEATURE_ENUM, /**< Feature specific enum */
LE_AFRC_FEATURE_ENUM, /**< Feature specific enum */
LE_ZERO_FEATURE_ENUM, /**< Feature specific enum */
LE_SWSH_FEATURE_ENUM, /**< Feature specific enum */
LE_CSWH_FEATURE_ENUM, /**< Feature specific enum */
LE_SALT_FEATURE_ENUM, /**< Feature specific enum */
LE_NALT_FEATURE_ENUM, /**< Feature specific enum */
LE_RUBY_FEATURE_ENUM, /**< Feature specific enum */
LE_SS01_FEATURE_ENUM, /**< Feature specific enum */
LE_SS02_FEATURE_ENUM, /**< Feature specific enum */
LE_SS03_FEATURE_ENUM, /**< Feature specific enum */
LE_SS04_FEATURE_ENUM, /**< Feature specific enum */
LE_SS05_FEATURE_ENUM, /**< Feature specific enum */
LE_SS06_FEATURE_ENUM, /**< Feature specific enum */
LE_SS07_FEATURE_ENUM, /**< Feature specific enum */
LE_CHAR_FILTER_FEATURE_ENUM = 31, /**< Apply CharSubstitutionFilter */
LE_FEATURE_ENUM_MAX = LE_CHAR_FILTER_FEATURE_ENUM
};
/**
* Flags for typographic features.
* @internal
* @{
*/
#define LE_Kerning_FEATURE_FLAG (1 << LE_Kerning_FEATURE_ENUM)
#define LE_Ligatures_FEATURE_FLAG (1 << LE_Ligatures_FEATURE_ENUM)
#define LE_CLIG_FEATURE_FLAG (1 << LE_CLIG_FEATURE_ENUM)
#define LE_DLIG_FEATURE_FLAG (1 << LE_DLIG_FEATURE_ENUM)
#define LE_HLIG_FEATURE_FLAG (1 << LE_HLIG_FEATURE_ENUM)
#define LE_LIGA_FEATURE_FLAG (1 << LE_LIGA_FEATURE_ENUM)
#define LE_RLIG_FEATURE_FLAG (1 << LE_RLIG_FEATURE_ENUM)
#define LE_SMCP_FEATURE_FLAG (1 << LE_SMCP_FEATURE_ENUM)
#define LE_FRAC_FEATURE_FLAG (1 << LE_FRAC_FEATURE_ENUM)
#define LE_AFRC_FEATURE_FLAG (1 << LE_AFRC_FEATURE_ENUM)
#define LE_ZERO_FEATURE_FLAG (1 << LE_ZERO_FEATURE_ENUM)
#define LE_SWSH_FEATURE_FLAG (1 << LE_SWSH_FEATURE_ENUM)
#define LE_CSWH_FEATURE_FLAG (1 << LE_CSWH_FEATURE_ENUM)
#define LE_SALT_FEATURE_FLAG (1 << LE_SALT_FEATURE_ENUM)
#define LE_NALT_FEATURE_FLAG (1 << LE_NALT_FEATURE_ENUM)
#define LE_RUBY_FEATURE_FLAG (1 << LE_RUBY_FEATURE_ENUM)
#define LE_SS01_FEATURE_FLAG (1 << LE_SS01_FEATURE_ENUM)
#define LE_SS02_FEATURE_FLAG (1 << LE_SS02_FEATURE_ENUM)
#define LE_SS03_FEATURE_FLAG (1 << LE_SS03_FEATURE_ENUM)
#define LE_SS04_FEATURE_FLAG (1 << LE_SS04_FEATURE_ENUM)
#define LE_SS05_FEATURE_FLAG (1 << LE_SS05_FEATURE_ENUM)
#define LE_SS06_FEATURE_FLAG (1 << LE_SS06_FEATURE_ENUM)
#define LE_SS07_FEATURE_FLAG (1 << LE_SS07_FEATURE_ENUM)
#define LE_CHAR_FILTER_FEATURE_FLAG (1 << LE_CHAR_FILTER_FEATURE_ENUM)
/**
* @}
*/
#define LE_DEFAULT_FEATURE_FLAG (LE_Kerning_FEATURE_FLAG | LE_Ligatures_FEATURE_FLAG) /**< default features */
/**
* Error codes returned by the LayoutEngine.
*
* @stable ICU 2.4
*/
enum LEErrorCode {
/* informational */
LE_NO_SUBFONT_WARNING = U_USING_DEFAULT_WARNING, /**< The font does not contain subfonts. */
/* success */
LE_NO_ERROR = U_ZERO_ERROR, /**< No error, no warning. */
/* failures */
LE_ILLEGAL_ARGUMENT_ERROR = U_ILLEGAL_ARGUMENT_ERROR, /**< An illegal argument was detected. */
LE_MEMORY_ALLOCATION_ERROR = U_MEMORY_ALLOCATION_ERROR, /**< Memory allocation error. */
LE_INDEX_OUT_OF_BOUNDS_ERROR = U_INDEX_OUTOFBOUNDS_ERROR, /**< Trying to access an index that is out of bounds. */
LE_NO_LAYOUT_ERROR = U_UNSUPPORTED_ERROR, /**< You must call layoutChars() first. */
LE_INTERNAL_ERROR = U_INTERNAL_PROGRAM_ERROR, /**< An internal error was encountered. */
LE_FONT_FILE_NOT_FOUND_ERROR = U_FILE_ACCESS_ERROR, /**< The requested font file cannot be opened. */
LE_MISSING_FONT_TABLE_ERROR = U_MISSING_RESOURCE_ERROR /**< The requested font table does not exist. */
};
#ifndef __cplusplus
/**
* Error codes returned by the LayoutEngine.
*
* @stable ICU 2.4
*/
typedef enum LEErrorCode LEErrorCode;
#endif
/**
* A convenience macro to test for the success of a LayoutEngine call.
*
* @stable ICU 2.4
*/
#define LE_SUCCESS(code) (U_SUCCESS((UErrorCode)code))
/**
* A convenience macro to test for the failure of a LayoutEngine call.
*
* @stable ICU 2.4
*/
#define LE_FAILURE(code) (U_FAILURE((UErrorCode)code))
#endif
|