t1tables.h (21529B)
1 /**************************************************************************** 2 * 3 * t1tables.h 4 * 5 * Basic Type 1/Type 2 tables definitions and interface (specification 6 * only). 7 * 8 * Copyright (C) 1996-2025 by 9 * David Turner, Robert Wilhelm, and Werner Lemberg. 10 * 11 * This file is part of the FreeType project, and may only be used, 12 * modified, and distributed under the terms of the FreeType project 13 * license, LICENSE.TXT. By continuing to use, modify, or distribute 14 * this file you indicate that you have read the license and 15 * understand and accept it fully. 16 * 17 */ 18 19 20 #ifndef T1TABLES_H_ 21 #define T1TABLES_H_ 22 23 24 #include <freetype/freetype.h> 25 26 #ifdef FREETYPE_H 27 #error "freetype.h of FreeType 1 has been loaded!" 28 #error "Please fix the directory search order for header files" 29 #error "so that freetype.h of FreeType 2 is found first." 30 #endif 31 32 33 FT_BEGIN_HEADER 34 35 36 /************************************************************************** 37 * 38 * @section: 39 * type1_tables 40 * 41 * @title: 42 * Type 1 Tables 43 * 44 * @abstract: 45 * Type~1-specific font tables. 46 * 47 * @description: 48 * This section contains the definition of Type~1-specific tables, 49 * including structures related to other PostScript font formats. 50 * 51 * @order: 52 * PS_FontInfoRec 53 * PS_FontInfo 54 * PS_PrivateRec 55 * PS_Private 56 * 57 * CID_FaceDictRec 58 * CID_FaceDict 59 * CID_FaceInfoRec 60 * CID_FaceInfo 61 * 62 * FT_Has_PS_Glyph_Names 63 * FT_Get_PS_Font_Info 64 * FT_Get_PS_Font_Private 65 * FT_Get_PS_Font_Value 66 * 67 * T1_Blend_Flags 68 * T1_EncodingType 69 * PS_Dict_Keys 70 * 71 */ 72 73 74 /* Note that we separate font data in PS_FontInfoRec and PS_PrivateRec */ 75 /* structures in order to support Multiple Master fonts. */ 76 77 78 /************************************************************************** 79 * 80 * @struct: 81 * PS_FontInfoRec 82 * 83 * @description: 84 * A structure used to model a Type~1 or Type~2 FontInfo dictionary. 85 * Note that for Multiple Master fonts, each instance has its own 86 * FontInfo dictionary. 87 */ 88 typedef struct PS_FontInfoRec_ 89 { 90 FT_String* version; 91 FT_String* notice; 92 FT_String* full_name; 93 FT_String* family_name; 94 FT_String* weight; 95 FT_Long italic_angle; 96 FT_Bool is_fixed_pitch; 97 FT_Short underline_position; 98 FT_UShort underline_thickness; 99 100 } PS_FontInfoRec; 101 102 103 /************************************************************************** 104 * 105 * @struct: 106 * PS_FontInfo 107 * 108 * @description: 109 * A handle to a @PS_FontInfoRec structure. 110 */ 111 typedef struct PS_FontInfoRec_* PS_FontInfo; 112 113 114 /************************************************************************** 115 * 116 * @struct: 117 * T1_FontInfo 118 * 119 * @description: 120 * This type is equivalent to @PS_FontInfoRec. It is deprecated but kept 121 * to maintain source compatibility between various versions of FreeType. 122 */ 123 typedef PS_FontInfoRec T1_FontInfo; 124 125 126 /************************************************************************** 127 * 128 * @struct: 129 * PS_PrivateRec 130 * 131 * @description: 132 * A structure used to model a Type~1 or Type~2 private dictionary. Note 133 * that for Multiple Master fonts, each instance has its own Private 134 * dictionary. 135 */ 136 typedef struct PS_PrivateRec_ 137 { 138 FT_Int unique_id; 139 FT_Int lenIV; 140 141 FT_Byte num_blue_values; 142 FT_Byte num_other_blues; 143 FT_Byte num_family_blues; 144 FT_Byte num_family_other_blues; 145 146 FT_Short blue_values[14]; 147 FT_Short other_blues[10]; 148 149 FT_Short family_blues [14]; 150 FT_Short family_other_blues[10]; 151 152 FT_Fixed blue_scale; 153 FT_Int blue_shift; 154 FT_Int blue_fuzz; 155 156 FT_UShort standard_width[1]; 157 FT_UShort standard_height[1]; 158 159 FT_Byte num_snap_widths; 160 FT_Byte num_snap_heights; 161 FT_Bool force_bold; 162 FT_Bool round_stem_up; 163 164 FT_Short snap_widths [13]; /* including std width */ 165 FT_Short snap_heights[13]; /* including std height */ 166 167 FT_Fixed expansion_factor; 168 169 FT_Long language_group; 170 FT_Long password; 171 172 FT_Short min_feature[2]; 173 174 } PS_PrivateRec; 175 176 177 /************************************************************************** 178 * 179 * @struct: 180 * PS_Private 181 * 182 * @description: 183 * A handle to a @PS_PrivateRec structure. 184 */ 185 typedef struct PS_PrivateRec_* PS_Private; 186 187 188 /************************************************************************** 189 * 190 * @struct: 191 * T1_Private 192 * 193 * @description: 194 * This type is equivalent to @PS_PrivateRec. It is deprecated but kept 195 * to maintain source compatibility between various versions of FreeType. 196 */ 197 typedef PS_PrivateRec T1_Private; 198 199 200 /************************************************************************** 201 * 202 * @enum: 203 * T1_Blend_Flags 204 * 205 * @description: 206 * A set of flags used to indicate which fields are present in a given 207 * blend dictionary (font info or private). Used to support Multiple 208 * Masters fonts. 209 * 210 * @values: 211 * T1_BLEND_UNDERLINE_POSITION :: 212 * T1_BLEND_UNDERLINE_THICKNESS :: 213 * T1_BLEND_ITALIC_ANGLE :: 214 * T1_BLEND_BLUE_VALUES :: 215 * T1_BLEND_OTHER_BLUES :: 216 * T1_BLEND_STANDARD_WIDTH :: 217 * T1_BLEND_STANDARD_HEIGHT :: 218 * T1_BLEND_STEM_SNAP_WIDTHS :: 219 * T1_BLEND_STEM_SNAP_HEIGHTS :: 220 * T1_BLEND_BLUE_SCALE :: 221 * T1_BLEND_BLUE_SHIFT :: 222 * T1_BLEND_FAMILY_BLUES :: 223 * T1_BLEND_FAMILY_OTHER_BLUES :: 224 * T1_BLEND_FORCE_BOLD :: 225 */ 226 typedef enum T1_Blend_Flags_ 227 { 228 /* required fields in a FontInfo blend dictionary */ 229 T1_BLEND_UNDERLINE_POSITION = 0, 230 T1_BLEND_UNDERLINE_THICKNESS, 231 T1_BLEND_ITALIC_ANGLE, 232 233 /* required fields in a Private blend dictionary */ 234 T1_BLEND_BLUE_VALUES, 235 T1_BLEND_OTHER_BLUES, 236 T1_BLEND_STANDARD_WIDTH, 237 T1_BLEND_STANDARD_HEIGHT, 238 T1_BLEND_STEM_SNAP_WIDTHS, 239 T1_BLEND_STEM_SNAP_HEIGHTS, 240 T1_BLEND_BLUE_SCALE, 241 T1_BLEND_BLUE_SHIFT, 242 T1_BLEND_FAMILY_BLUES, 243 T1_BLEND_FAMILY_OTHER_BLUES, 244 T1_BLEND_FORCE_BOLD, 245 246 T1_BLEND_MAX /* do not remove */ 247 248 } T1_Blend_Flags; 249 250 251 /* these constants are deprecated; use the corresponding */ 252 /* `T1_Blend_Flags` values instead */ 253 #define t1_blend_underline_position T1_BLEND_UNDERLINE_POSITION 254 #define t1_blend_underline_thickness T1_BLEND_UNDERLINE_THICKNESS 255 #define t1_blend_italic_angle T1_BLEND_ITALIC_ANGLE 256 #define t1_blend_blue_values T1_BLEND_BLUE_VALUES 257 #define t1_blend_other_blues T1_BLEND_OTHER_BLUES 258 #define t1_blend_standard_widths T1_BLEND_STANDARD_WIDTH 259 #define t1_blend_standard_height T1_BLEND_STANDARD_HEIGHT 260 #define t1_blend_stem_snap_widths T1_BLEND_STEM_SNAP_WIDTHS 261 #define t1_blend_stem_snap_heights T1_BLEND_STEM_SNAP_HEIGHTS 262 #define t1_blend_blue_scale T1_BLEND_BLUE_SCALE 263 #define t1_blend_blue_shift T1_BLEND_BLUE_SHIFT 264 #define t1_blend_family_blues T1_BLEND_FAMILY_BLUES 265 #define t1_blend_family_other_blues T1_BLEND_FAMILY_OTHER_BLUES 266 #define t1_blend_force_bold T1_BLEND_FORCE_BOLD 267 #define t1_blend_max T1_BLEND_MAX 268 269 /* */ 270 271 272 /************************************************************************** 273 * 274 * @struct: 275 * CID_FaceDictRec 276 * 277 * @description: 278 * A structure used to represent data in a CID top-level dictionary. In 279 * most cases, they are part of the font's '/FDArray' array. Within a 280 * CID font file, such (internal) subfont dictionaries are enclosed by 281 * '%ADOBeginFontDict' and '%ADOEndFontDict' comments. 282 * 283 * Note that `CID_FaceDictRec` misses a field for the '/FontName' 284 * keyword, specifying the subfont's name (the top-level font name is 285 * given by the '/CIDFontName' keyword). This is an oversight, but it 286 * doesn't limit the 'cid' font module's functionality because FreeType 287 * neither needs this entry nor gives access to CID subfonts. 288 */ 289 typedef struct CID_FaceDictRec_ 290 { 291 PS_PrivateRec private_dict; 292 293 FT_UInt len_buildchar; 294 FT_Fixed forcebold_threshold; 295 FT_Pos stroke_width; 296 FT_Fixed expansion_factor; /* this is a duplicate of */ 297 /* `private_dict->expansion_factor' */ 298 FT_Byte paint_type; 299 FT_Byte font_type; 300 FT_Matrix font_matrix; 301 FT_Vector font_offset; 302 303 FT_UInt num_subrs; 304 FT_ULong subrmap_offset; 305 FT_UInt sd_bytes; 306 307 } CID_FaceDictRec; 308 309 310 /************************************************************************** 311 * 312 * @struct: 313 * CID_FaceDict 314 * 315 * @description: 316 * A handle to a @CID_FaceDictRec structure. 317 */ 318 typedef struct CID_FaceDictRec_* CID_FaceDict; 319 320 321 /************************************************************************** 322 * 323 * @struct: 324 * CID_FontDict 325 * 326 * @description: 327 * This type is equivalent to @CID_FaceDictRec. It is deprecated but 328 * kept to maintain source compatibility between various versions of 329 * FreeType. 330 */ 331 typedef CID_FaceDictRec CID_FontDict; 332 333 334 /************************************************************************** 335 * 336 * @struct: 337 * CID_FaceInfoRec 338 * 339 * @description: 340 * A structure used to represent CID Face information. 341 */ 342 typedef struct CID_FaceInfoRec_ 343 { 344 FT_String* cid_font_name; 345 FT_Fixed cid_version; 346 FT_Int cid_font_type; 347 348 FT_String* registry; 349 FT_String* ordering; 350 FT_Int supplement; 351 352 PS_FontInfoRec font_info; 353 FT_BBox font_bbox; 354 FT_ULong uid_base; 355 356 FT_Int num_xuid; 357 FT_ULong xuid[16]; 358 359 FT_ULong cidmap_offset; 360 FT_UInt fd_bytes; 361 FT_UInt gd_bytes; 362 FT_ULong cid_count; 363 364 FT_UInt num_dicts; 365 CID_FaceDict font_dicts; 366 367 FT_ULong data_offset; 368 369 } CID_FaceInfoRec; 370 371 372 /************************************************************************** 373 * 374 * @struct: 375 * CID_FaceInfo 376 * 377 * @description: 378 * A handle to a @CID_FaceInfoRec structure. 379 */ 380 typedef struct CID_FaceInfoRec_* CID_FaceInfo; 381 382 383 /************************************************************************** 384 * 385 * @struct: 386 * CID_Info 387 * 388 * @description: 389 * This type is equivalent to @CID_FaceInfoRec. It is deprecated but kept 390 * to maintain source compatibility between various versions of FreeType. 391 */ 392 typedef CID_FaceInfoRec CID_Info; 393 394 395 /************************************************************************** 396 * 397 * @function: 398 * FT_Has_PS_Glyph_Names 399 * 400 * @description: 401 * Return true if a given face provides reliable PostScript glyph names. 402 * This is similar to using the @FT_HAS_GLYPH_NAMES macro, except that 403 * certain fonts (mostly TrueType) contain incorrect glyph name tables. 404 * 405 * When this function returns true, the caller is sure that the glyph 406 * names returned by @FT_Get_Glyph_Name are reliable. 407 * 408 * @input: 409 * face :: 410 * face handle 411 * 412 * @return: 413 * Boolean. True if glyph names are reliable. 414 * 415 */ 416 FT_EXPORT( FT_Int ) 417 FT_Has_PS_Glyph_Names( FT_Face face ); 418 419 420 /************************************************************************** 421 * 422 * @function: 423 * FT_Get_PS_Font_Info 424 * 425 * @description: 426 * Retrieve the @PS_FontInfoRec structure corresponding to a given 427 * PostScript font. 428 * 429 * @input: 430 * face :: 431 * PostScript face handle. 432 * 433 * @output: 434 * afont_info :: 435 * A pointer to a @PS_FontInfoRec object. 436 * 437 * @return: 438 * FreeType error code. 0~means success. 439 * 440 * @note: 441 * String pointers within the @PS_FontInfoRec structure are owned by the 442 * face and don't need to be freed by the caller. Missing entries in the 443 * font's FontInfo dictionary are represented by `NULL` pointers. 444 * 445 * The following font formats support this feature: 'Type~1', 'Type~42', 446 * 'CFF', 'CID~Type~1'. For other font formats this function returns the 447 * `FT_Err_Invalid_Argument` error code. 448 * 449 * @example: 450 * ``` 451 * PS_FontInfoRec font_info; 452 * 453 * 454 * error = FT_Get_PS_Font_Info( face, &font_info ); 455 * ... 456 * ``` 457 * 458 */ 459 FT_EXPORT( FT_Error ) 460 FT_Get_PS_Font_Info( FT_Face face, 461 PS_FontInfo afont_info ); 462 463 464 /************************************************************************** 465 * 466 * @function: 467 * FT_Get_PS_Font_Private 468 * 469 * @description: 470 * Retrieve the @PS_PrivateRec structure corresponding to a given 471 * PostScript font. 472 * 473 * @input: 474 * face :: 475 * PostScript face handle. 476 * 477 * @output: 478 * afont_private :: 479 * A pointer to a @PS_PrivateRec object. 480 * 481 * @return: 482 * FreeType error code. 0~means success. 483 * 484 * @note: 485 * The string pointers within the @PS_PrivateRec structure are owned by 486 * the face and don't need to be freed by the caller. 487 * 488 * Only the 'Type~1' font format supports this feature. For other font 489 * formats this function returns the `FT_Err_Invalid_Argument` error 490 * code. 491 * 492 * @example: 493 * ``` 494 * PS_PrivateRec font_private; 495 * 496 * 497 * error = FT_Get_PS_Font_Private( face, &font_private ); 498 * ... 499 * ``` 500 * 501 */ 502 FT_EXPORT( FT_Error ) 503 FT_Get_PS_Font_Private( FT_Face face, 504 PS_Private afont_private ); 505 506 507 /************************************************************************** 508 * 509 * @enum: 510 * T1_EncodingType 511 * 512 * @description: 513 * An enumeration describing the 'Encoding' entry in a Type 1 dictionary. 514 * 515 * @values: 516 * T1_ENCODING_TYPE_NONE :: 517 * T1_ENCODING_TYPE_ARRAY :: 518 * T1_ENCODING_TYPE_STANDARD :: 519 * T1_ENCODING_TYPE_ISOLATIN1 :: 520 * T1_ENCODING_TYPE_EXPERT :: 521 * 522 * @since: 523 * 2.4.8 524 */ 525 typedef enum T1_EncodingType_ 526 { 527 T1_ENCODING_TYPE_NONE = 0, 528 T1_ENCODING_TYPE_ARRAY, 529 T1_ENCODING_TYPE_STANDARD, 530 T1_ENCODING_TYPE_ISOLATIN1, 531 T1_ENCODING_TYPE_EXPERT 532 533 } T1_EncodingType; 534 535 536 /************************************************************************** 537 * 538 * @enum: 539 * PS_Dict_Keys 540 * 541 * @description: 542 * An enumeration used in calls to @FT_Get_PS_Font_Value to identify the 543 * Type~1 dictionary entry to retrieve. 544 * 545 * @values: 546 * PS_DICT_FONT_TYPE :: 547 * PS_DICT_FONT_MATRIX :: 548 * PS_DICT_FONT_BBOX :: 549 * PS_DICT_PAINT_TYPE :: 550 * PS_DICT_FONT_NAME :: 551 * PS_DICT_UNIQUE_ID :: 552 * PS_DICT_NUM_CHAR_STRINGS :: 553 * PS_DICT_CHAR_STRING_KEY :: 554 * PS_DICT_CHAR_STRING :: 555 * PS_DICT_ENCODING_TYPE :: 556 * PS_DICT_ENCODING_ENTRY :: 557 * PS_DICT_NUM_SUBRS :: 558 * PS_DICT_SUBR :: 559 * PS_DICT_STD_HW :: 560 * PS_DICT_STD_VW :: 561 * PS_DICT_NUM_BLUE_VALUES :: 562 * PS_DICT_BLUE_VALUE :: 563 * PS_DICT_BLUE_FUZZ :: 564 * PS_DICT_NUM_OTHER_BLUES :: 565 * PS_DICT_OTHER_BLUE :: 566 * PS_DICT_NUM_FAMILY_BLUES :: 567 * PS_DICT_FAMILY_BLUE :: 568 * PS_DICT_NUM_FAMILY_OTHER_BLUES :: 569 * PS_DICT_FAMILY_OTHER_BLUE :: 570 * PS_DICT_BLUE_SCALE :: 571 * PS_DICT_BLUE_SHIFT :: 572 * PS_DICT_NUM_STEM_SNAP_H :: 573 * PS_DICT_STEM_SNAP_H :: 574 * PS_DICT_NUM_STEM_SNAP_V :: 575 * PS_DICT_STEM_SNAP_V :: 576 * PS_DICT_FORCE_BOLD :: 577 * PS_DICT_RND_STEM_UP :: 578 * PS_DICT_MIN_FEATURE :: 579 * PS_DICT_LEN_IV :: 580 * PS_DICT_PASSWORD :: 581 * PS_DICT_LANGUAGE_GROUP :: 582 * PS_DICT_VERSION :: 583 * PS_DICT_NOTICE :: 584 * PS_DICT_FULL_NAME :: 585 * PS_DICT_FAMILY_NAME :: 586 * PS_DICT_WEIGHT :: 587 * PS_DICT_IS_FIXED_PITCH :: 588 * PS_DICT_UNDERLINE_POSITION :: 589 * PS_DICT_UNDERLINE_THICKNESS :: 590 * PS_DICT_FS_TYPE :: 591 * PS_DICT_ITALIC_ANGLE :: 592 * 593 * @since: 594 * 2.4.8 595 */ 596 typedef enum PS_Dict_Keys_ 597 { 598 /* conventionally in the font dictionary */ 599 PS_DICT_FONT_TYPE, /* FT_Byte */ 600 PS_DICT_FONT_MATRIX, /* FT_Fixed */ 601 PS_DICT_FONT_BBOX, /* FT_Fixed */ 602 PS_DICT_PAINT_TYPE, /* FT_Byte */ 603 PS_DICT_FONT_NAME, /* FT_String* */ 604 PS_DICT_UNIQUE_ID, /* FT_Int */ 605 PS_DICT_NUM_CHAR_STRINGS, /* FT_Int */ 606 PS_DICT_CHAR_STRING_KEY, /* FT_String* */ 607 PS_DICT_CHAR_STRING, /* FT_String* */ 608 PS_DICT_ENCODING_TYPE, /* T1_EncodingType */ 609 PS_DICT_ENCODING_ENTRY, /* FT_String* */ 610 611 /* conventionally in the font Private dictionary */ 612 PS_DICT_NUM_SUBRS, /* FT_Int */ 613 PS_DICT_SUBR, /* FT_String* */ 614 PS_DICT_STD_HW, /* FT_UShort */ 615 PS_DICT_STD_VW, /* FT_UShort */ 616 PS_DICT_NUM_BLUE_VALUES, /* FT_Byte */ 617 PS_DICT_BLUE_VALUE, /* FT_Short */ 618 PS_DICT_BLUE_FUZZ, /* FT_Int */ 619 PS_DICT_NUM_OTHER_BLUES, /* FT_Byte */ 620 PS_DICT_OTHER_BLUE, /* FT_Short */ 621 PS_DICT_NUM_FAMILY_BLUES, /* FT_Byte */ 622 PS_DICT_FAMILY_BLUE, /* FT_Short */ 623 PS_DICT_NUM_FAMILY_OTHER_BLUES, /* FT_Byte */ 624 PS_DICT_FAMILY_OTHER_BLUE, /* FT_Short */ 625 PS_DICT_BLUE_SCALE, /* FT_Fixed */ 626 PS_DICT_BLUE_SHIFT, /* FT_Int */ 627 PS_DICT_NUM_STEM_SNAP_H, /* FT_Byte */ 628 PS_DICT_STEM_SNAP_H, /* FT_Short */ 629 PS_DICT_NUM_STEM_SNAP_V, /* FT_Byte */ 630 PS_DICT_STEM_SNAP_V, /* FT_Short */ 631 PS_DICT_FORCE_BOLD, /* FT_Bool */ 632 PS_DICT_RND_STEM_UP, /* FT_Bool */ 633 PS_DICT_MIN_FEATURE, /* FT_Short */ 634 PS_DICT_LEN_IV, /* FT_Int */ 635 PS_DICT_PASSWORD, /* FT_Long */ 636 PS_DICT_LANGUAGE_GROUP, /* FT_Long */ 637 638 /* conventionally in the font FontInfo dictionary */ 639 PS_DICT_VERSION, /* FT_String* */ 640 PS_DICT_NOTICE, /* FT_String* */ 641 PS_DICT_FULL_NAME, /* FT_String* */ 642 PS_DICT_FAMILY_NAME, /* FT_String* */ 643 PS_DICT_WEIGHT, /* FT_String* */ 644 PS_DICT_IS_FIXED_PITCH, /* FT_Bool */ 645 PS_DICT_UNDERLINE_POSITION, /* FT_Short */ 646 PS_DICT_UNDERLINE_THICKNESS, /* FT_UShort */ 647 PS_DICT_FS_TYPE, /* FT_UShort */ 648 PS_DICT_ITALIC_ANGLE, /* FT_Long */ 649 650 PS_DICT_MAX = PS_DICT_ITALIC_ANGLE 651 652 } PS_Dict_Keys; 653 654 655 /************************************************************************** 656 * 657 * @function: 658 * FT_Get_PS_Font_Value 659 * 660 * @description: 661 * Retrieve the value for the supplied key from a PostScript font. 662 * 663 * @input: 664 * face :: 665 * PostScript face handle. 666 * 667 * key :: 668 * An enumeration value representing the dictionary key to retrieve. 669 * 670 * idx :: 671 * For array values, this specifies the index to be returned. 672 * 673 * value :: 674 * A pointer to memory into which to write the value. 675 * 676 * valen_len :: 677 * The size, in bytes, of the memory supplied for the value. 678 * 679 * @output: 680 * value :: 681 * The value matching the above key, if it exists. 682 * 683 * @return: 684 * The amount of memory (in bytes) required to hold the requested value 685 * (if it exists, -1 otherwise). 686 * 687 * @note: 688 * The values returned are not pointers into the internal structures of 689 * the face, but are 'fresh' copies, so that the memory containing them 690 * belongs to the calling application. This also enforces the 691 * 'read-only' nature of these values, i.e., this function cannot be 692 * used to manipulate the face. 693 * 694 * `value` is a void pointer because the values returned can be of 695 * various types. 696 * 697 * If either `value` is `NULL` or `value_len` is too small, just the 698 * required memory size for the requested entry is returned. 699 * 700 * The `idx` parameter is used, not only to retrieve elements of, for 701 * example, the FontMatrix or FontBBox, but also to retrieve name keys 702 * from the CharStrings dictionary, and the charstrings themselves. It 703 * is ignored for atomic values. 704 * 705 * `PS_DICT_BLUE_SCALE` returns a value that is scaled up by 1000. To 706 * get the value as in the font stream, you need to divide by 65536000.0 707 * (to remove the FT_Fixed scale, and the x1000 scale). 708 * 709 * IMPORTANT: Only key/value pairs read by the FreeType interpreter can 710 * be retrieved. So, for example, PostScript procedures such as NP, ND, 711 * and RD are not available. Arbitrary keys are, obviously, not be 712 * available either. 713 * 714 * If the font's format is not PostScript-based, this function returns 715 * the `FT_Err_Invalid_Argument` error code. 716 * 717 * @since: 718 * 2.4.8 719 * 720 */ 721 FT_EXPORT( FT_Long ) 722 FT_Get_PS_Font_Value( FT_Face face, 723 PS_Dict_Keys key, 724 FT_UInt idx, 725 void *value, 726 FT_Long value_len ); 727 728 /* */ 729 730 FT_END_HEADER 731 732 #endif /* T1TABLES_H_ */ 733 734 735 /* END */