ReactOS 0.4.16-dev-1020-gf135cab
psaux.h
Go to the documentation of this file.
1/****************************************************************************
2 *
3 * psaux.h
4 *
5 * Auxiliary functions and data structures related to PostScript fonts
6 * (specification).
7 *
8 * Copyright (C) 1996-2019 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 PSAUX_H_
21#define PSAUX_H_
22
23
24#include <ft2build.h>
25#include FT_INTERNAL_OBJECTS_H
26#include FT_INTERNAL_TYPE1_TYPES_H
27#include FT_INTERNAL_HASH_H
28#include FT_INTERNAL_TRUETYPE_TYPES_H
29#include FT_SERVICE_POSTSCRIPT_CMAPS_H
30#include FT_INTERNAL_CFF_TYPES_H
31#include FT_INTERNAL_CFF_OBJECTS_TYPES_H
32
33
34
36
37
38 /**************************************************************************
39 *
40 * PostScript modules driver class.
41 */
42 typedef struct PS_DriverRec_
43 {
45
49 FT_Int32 random_seed;
50
52
53
54 /*************************************************************************/
55 /*************************************************************************/
56 /***** *****/
57 /***** T1_TABLE *****/
58 /***** *****/
59 /*************************************************************************/
60 /*************************************************************************/
61
62
63 typedef struct PS_TableRec_* PS_Table;
64 typedef const struct PS_Table_FuncsRec_* PS_Table_Funcs;
65
66
67 /**************************************************************************
68 *
69 * @struct:
70 * PS_Table_FuncsRec
71 *
72 * @description:
73 * A set of function pointers to manage PS_Table objects.
74 *
75 * @fields:
76 * table_init ::
77 * Used to initialize a table.
78 *
79 * table_done ::
80 * Finalizes resp. destroy a given table.
81 *
82 * table_add ::
83 * Adds a new object to a table.
84 *
85 * table_release ::
86 * Releases table data, then finalizes it.
87 */
88 typedef struct PS_Table_FuncsRec_
89 {
94
96 (*done)( PS_Table table );
97
99 (*add)( PS_Table table,
100 FT_Int idx,
101 void* object,
102 FT_UInt length );
103
105 (*release)( PS_Table table );
106
108
109
110 /**************************************************************************
111 *
112 * @struct:
113 * PS_TableRec
114 *
115 * @description:
116 * A PS_Table is a simple object used to store an array of objects in a
117 * single memory block.
118 *
119 * @fields:
120 * block ::
121 * The address in memory of the growheap's block. This can change
122 * between two object adds, due to reallocation.
123 *
124 * cursor ::
125 * The current top of the grow heap within its block.
126 *
127 * capacity ::
128 * The current size of the heap block. Increments by 1kByte chunks.
129 *
130 * init ::
131 * Set to 0xDEADBEEF if 'elements' and 'lengths' have been allocated.
132 *
133 * max_elems ::
134 * The maximum number of elements in table.
135 *
136 * num_elems ::
137 * The current number of elements in table.
138 *
139 * elements ::
140 * A table of element addresses within the block.
141 *
142 * lengths ::
143 * A table of element sizes within the block.
144 *
145 * memory ::
146 * The object used for memory operations (alloc/realloc).
147 *
148 * funcs ::
149 * A table of method pointers for this object.
150 */
151 typedef struct PS_TableRec_
152 {
153 FT_Byte* block; /* current memory block */
154 FT_Offset cursor; /* current cursor in memory block */
155 FT_Offset capacity; /* current size of memory block */
157
160 FT_Byte** elements; /* addresses of table elements */
161 FT_UInt* lengths; /* lengths of table elements */
162
165
167
168
169 /*************************************************************************/
170 /*************************************************************************/
171 /***** *****/
172 /***** T1 FIELDS & TOKENS *****/
173 /***** *****/
174 /*************************************************************************/
175 /*************************************************************************/
176
177 typedef struct PS_ParserRec_* PS_Parser;
178
179 typedef struct T1_TokenRec_* T1_Token;
180
181 typedef struct T1_FieldRec_* T1_Field;
182
183
184 /* simple enumeration type used to identify token types */
185 typedef enum T1_TokenType_
186 {
191 T1_TOKEN_TYPE_KEY, /* aka `name' */
192
193 /* do not remove */
195
197
198
199 /* a simple structure used to identify tokens */
200 typedef struct T1_TokenRec_
201 {
202 FT_Byte* start; /* first character of token in input stream */
203 FT_Byte* limit; /* first character after the token */
204 T1_TokenType type; /* type of token */
205
207
208
209 /* enumeration type used to identify object fields */
210 typedef enum T1_FieldType_
211 {
224
225 /* do not remove */
227
229
230
231 typedef enum T1_FieldLocation_
232 {
242
243 /* do not remove */
245
247
248
249 typedef void
252
253
254 /* structure type used to model object fields */
255 typedef struct T1_FieldRec_
256 {
257 const char* ident; /* field identifier */
259 T1_FieldType type; /* type of field */
261 FT_UInt offset; /* offset of field in object */
262 FT_Byte size; /* size of field in bytes */
263 FT_UInt array_max; /* maximum number of elements for */
264 /* array */
265 FT_UInt count_offset; /* offset of element count for */
266 /* arrays; must not be zero if in */
267 /* use -- in other words, a */
268 /* `num_FOO' element must not */
269 /* start the used structure if we */
270 /* parse a `FOO' array */
271 FT_UInt dict; /* where we expect it */
273
274#define T1_FIELD_DICT_FONTDICT ( 1 << 0 ) /* also FontInfo and FDArray */
275#define T1_FIELD_DICT_PRIVATE ( 1 << 1 )
276
277
278
279#define T1_NEW_SIMPLE_FIELD( _ident, _type, _fname, _dict ) \
280 { \
281 _ident, T1CODE, _type, \
282 0, \
283 FT_FIELD_OFFSET( _fname ), \
284 FT_FIELD_SIZE( _fname ), \
285 0, 0, \
286 _dict \
287 },
288
289#define T1_NEW_CALLBACK_FIELD( _ident, _reader, _dict ) \
290 { \
291 _ident, T1CODE, T1_FIELD_TYPE_CALLBACK, \
292 (T1_Field_ParseFunc)_reader, \
293 0, 0, \
294 0, 0, \
295 _dict \
296 },
297
298#define T1_NEW_TABLE_FIELD( _ident, _type, _fname, _max, _dict ) \
299 { \
300 _ident, T1CODE, _type, \
301 0, \
302 FT_FIELD_OFFSET( _fname ), \
303 FT_FIELD_SIZE_DELTA( _fname ), \
304 _max, \
305 FT_FIELD_OFFSET( num_ ## _fname ), \
306 _dict \
307 },
308
309#define T1_NEW_TABLE_FIELD2( _ident, _type, _fname, _max, _dict ) \
310 { \
311 _ident, T1CODE, _type, \
312 0, \
313 FT_FIELD_OFFSET( _fname ), \
314 FT_FIELD_SIZE_DELTA( _fname ), \
315 _max, 0, \
316 _dict \
317 },
318
319
320#define T1_FIELD_BOOL( _ident, _fname, _dict ) \
321 T1_NEW_SIMPLE_FIELD( _ident, T1_FIELD_TYPE_BOOL, _fname, _dict )
322
323#define T1_FIELD_NUM( _ident, _fname, _dict ) \
324 T1_NEW_SIMPLE_FIELD( _ident, T1_FIELD_TYPE_INTEGER, _fname, _dict )
325
326#define T1_FIELD_FIXED( _ident, _fname, _dict ) \
327 T1_NEW_SIMPLE_FIELD( _ident, T1_FIELD_TYPE_FIXED, _fname, _dict )
328
329#define T1_FIELD_FIXED_1000( _ident, _fname, _dict ) \
330 T1_NEW_SIMPLE_FIELD( _ident, T1_FIELD_TYPE_FIXED_1000, _fname, \
331 _dict )
332
333#define T1_FIELD_STRING( _ident, _fname, _dict ) \
334 T1_NEW_SIMPLE_FIELD( _ident, T1_FIELD_TYPE_STRING, _fname, _dict )
335
336#define T1_FIELD_KEY( _ident, _fname, _dict ) \
337 T1_NEW_SIMPLE_FIELD( _ident, T1_FIELD_TYPE_KEY, _fname, _dict )
338
339#define T1_FIELD_BBOX( _ident, _fname, _dict ) \
340 T1_NEW_SIMPLE_FIELD( _ident, T1_FIELD_TYPE_BBOX, _fname, _dict )
341
342
343#define T1_FIELD_NUM_TABLE( _ident, _fname, _fmax, _dict ) \
344 T1_NEW_TABLE_FIELD( _ident, T1_FIELD_TYPE_INTEGER_ARRAY, \
345 _fname, _fmax, _dict )
346
347#define T1_FIELD_FIXED_TABLE( _ident, _fname, _fmax, _dict ) \
348 T1_NEW_TABLE_FIELD( _ident, T1_FIELD_TYPE_FIXED_ARRAY, \
349 _fname, _fmax, _dict )
350
351#define T1_FIELD_NUM_TABLE2( _ident, _fname, _fmax, _dict ) \
352 T1_NEW_TABLE_FIELD2( _ident, T1_FIELD_TYPE_INTEGER_ARRAY, \
353 _fname, _fmax, _dict )
354
355#define T1_FIELD_FIXED_TABLE2( _ident, _fname, _fmax, _dict ) \
356 T1_NEW_TABLE_FIELD2( _ident, T1_FIELD_TYPE_FIXED_ARRAY, \
357 _fname, _fmax, _dict )
358
359#define T1_FIELD_CALLBACK( _ident, _name, _dict ) \
360 T1_NEW_CALLBACK_FIELD( _ident, _name, _dict )
361
362
363 /*************************************************************************/
364 /*************************************************************************/
365 /***** *****/
366 /***** T1 PARSER *****/
367 /***** *****/
368 /*************************************************************************/
369 /*************************************************************************/
370
372
373 typedef struct PS_Parser_FuncsRec_
374 {
377 FT_Byte* base,
378 FT_Byte* limit,
380
382 (*done)( PS_Parser parser );
383
388
390 (*to_int)( PS_Parser parser );
393 FT_Int power_ten );
394
397 FT_Byte* bytes,
398 FT_Offset max_bytes,
399 FT_ULong* pnum_bytes,
400 FT_Bool delimiters );
401
404 FT_Int max_coords,
405 FT_Short* coords );
408 FT_Int max_values,
410 FT_Int power_ten );
411
414 T1_Token token );
417 T1_Token tokens,
418 FT_UInt max_tokens,
419 FT_Int* pnum_tokens );
420
423 const T1_Field field,
424 void** objects,
425 FT_UInt max_objects,
426 FT_ULong* pflags );
427
430 const T1_Field field,
431 void** objects,
432 FT_UInt max_objects,
433 FT_ULong* pflags );
434
436
437
438 /**************************************************************************
439 *
440 * @struct:
441 * PS_ParserRec
442 *
443 * @description:
444 * A PS_Parser is an object used to parse a Type 1 font very quickly.
445 *
446 * @fields:
447 * cursor ::
448 * The current position in the text.
449 *
450 * base ::
451 * Start of the processed text.
452 *
453 * limit ::
454 * End of the processed text.
455 *
456 * error ::
457 * The last error returned.
458 *
459 * memory ::
460 * The object used for memory operations (alloc/realloc).
461 *
462 * funcs ::
463 * A table of functions for the parser.
464 */
465 typedef struct PS_ParserRec_
466 {
472
474
476
477
478 /*************************************************************************/
479 /*************************************************************************/
480 /***** *****/
481 /***** PS BUILDER *****/
482 /***** *****/
483 /*************************************************************************/
484 /*************************************************************************/
485
486
487 typedef struct PS_Builder_ PS_Builder;
489
490 typedef struct PS_Builder_FuncsRec_
491 {
493 (*init)( PS_Builder* ps_builder,
494 void* builder,
495 FT_Bool is_t1 );
496
498 (*done)( PS_Builder* builder );
499
501
502
503 /**************************************************************************
504 *
505 * @struct:
506 * PS_Builder
507 *
508 * @description:
509 * A structure used during glyph loading to store its outline.
510 *
511 * @fields:
512 * memory ::
513 * The current memory object.
514 *
515 * face ::
516 * The current face object.
517 *
518 * glyph ::
519 * The current glyph slot.
520 *
521 * loader ::
522 * XXX
523 *
524 * base ::
525 * The base glyph outline.
526 *
527 * current ::
528 * The current glyph outline.
529 *
530 * pos_x ::
531 * The horizontal translation (if composite glyph).
532 *
533 * pos_y ::
534 * The vertical translation (if composite glyph).
535 *
536 * left_bearing ::
537 * The left side bearing point.
538 *
539 * advance ::
540 * The horizontal advance vector.
541 *
542 * bbox ::
543 * Unused.
544 *
545 * path_begun ::
546 * A flag which indicates that a new path has begun.
547 *
548 * load_points ::
549 * If this flag is not set, no points are loaded.
550 *
551 * no_recurse ::
552 * Set but not used.
553 *
554 * metrics_only ::
555 * A boolean indicating that we only want to compute the metrics of a
556 * given glyph, not load all of its points.
557 *
558 * is_t1 ::
559 * Set if current font type is Type 1.
560 *
561 * funcs ::
562 * An array of function pointers for the builder.
563 */
565 {
572
575
578
579 FT_BBox* bbox; /* bounding box */
583
586
588
589 };
590
591
592 /*************************************************************************/
593 /*************************************************************************/
594 /***** *****/
595 /***** PS DECODER *****/
596 /***** *****/
597 /*************************************************************************/
598 /*************************************************************************/
599
600#define PS_MAX_OPERANDS 48
601#define PS_MAX_SUBRS_CALLS 16 /* maximum subroutine nesting; */
602 /* only 10 are allowed but there exist */
603 /* fonts like `HiraKakuProN-W3.ttf' */
604 /* (Hiragino Kaku Gothic ProN W3; */
605 /* 8.2d6e1; 2014-12-19) that exceed */
606 /* this limit */
607
608 /* execution context charstring zone */
609
610 typedef struct PS_Decoder_Zone_
611 {
615
617
618
619 typedef FT_Error
621 FT_UInt glyph_index,
623 FT_ULong* length );
624
625 typedef void
629
630
631 typedef struct PS_Decoder_
632 {
634
637
640
644
646 CFF_SubFont current_subfont; /* for current glyph_index */
648
652
655
658
661
662 FT_Byte** glyph_names; /* for pure CFF fonts only */
663 FT_UInt num_glyphs; /* number of glyphs in font */
664
666
668
671
672 /* Type 1 stuff */
673 FT_Service_PsCMaps psnames; /* for seac */
674
675 FT_Int lenIV; /* internal for sub routine calls */
676 FT_UInt* locals_len; /* array of subrs length (optional) */
677 FT_Hash locals_hash; /* used if `num_subrs' was massaged */
678
681
682 PS_Blend blend; /* for multiple master support */
683
686
688
689
690 /*************************************************************************/
691 /*************************************************************************/
692 /***** *****/
693 /***** T1 BUILDER *****/
694 /***** *****/
695 /*************************************************************************/
696 /*************************************************************************/
697
698
699 typedef struct T1_BuilderRec_* T1_Builder;
700
701
702 typedef FT_Error
704 FT_Int count );
705
706 typedef void
708 FT_Pos x,
709 FT_Pos y,
710 FT_Byte flag );
711
712 typedef FT_Error
714 FT_Pos x,
715 FT_Pos y );
716
717 typedef FT_Error
719
720 typedef FT_Error
722 FT_Pos x,
723 FT_Pos y );
724
725 typedef void
727
728
730
731 typedef struct T1_Builder_FuncsRec_
732 {
734 (*init)( T1_Builder builder,
738 FT_Bool hinting );
739
741 (*done)( T1_Builder builder );
742
749
751
752
753 /* an enumeration type to handle charstring parsing states */
754 typedef enum T1_ParseState_
755 {
760
762
763
764 /**************************************************************************
765 *
766 * @struct:
767 * T1_BuilderRec
768 *
769 * @description:
770 * A structure used during glyph loading to store its outline.
771 *
772 * @fields:
773 * memory ::
774 * The current memory object.
775 *
776 * face ::
777 * The current face object.
778 *
779 * glyph ::
780 * The current glyph slot.
781 *
782 * loader ::
783 * XXX
784 *
785 * base ::
786 * The base glyph outline.
787 *
788 * current ::
789 * The current glyph outline.
790 *
791 * max_points ::
792 * maximum points in builder outline
793 *
794 * max_contours ::
795 * Maximum number of contours in builder outline.
796 *
797 * pos_x ::
798 * The horizontal translation (if composite glyph).
799 *
800 * pos_y ::
801 * The vertical translation (if composite glyph).
802 *
803 * left_bearing ::
804 * The left side bearing point.
805 *
806 * advance ::
807 * The horizontal advance vector.
808 *
809 * bbox ::
810 * Unused.
811 *
812 * parse_state ::
813 * An enumeration which controls the charstring parsing state.
814 *
815 * load_points ::
816 * If this flag is not set, no points are loaded.
817 *
818 * no_recurse ::
819 * Set but not used.
820 *
821 * metrics_only ::
822 * A boolean indicating that we only want to compute the metrics of a
823 * given glyph, not load all of its points.
824 *
825 * funcs ::
826 * An array of function pointers for the builder.
827 */
828 typedef struct T1_BuilderRec_
829 {
836
839
842
843 FT_BBox bbox; /* bounding box */
847
849
850 void* hints_funcs; /* hinter-specific */
851 void* hints_globals; /* hinter-specific */
852
854
856
857
858 /*************************************************************************/
859 /*************************************************************************/
860 /***** *****/
861 /***** T1 DECODER *****/
862 /***** *****/
863 /*************************************************************************/
864 /*************************************************************************/
865
866#if 0
867
868 /**************************************************************************
869 *
870 * T1_MAX_SUBRS_CALLS details the maximum number of nested sub-routine
871 * calls during glyph loading.
872 */
873#define T1_MAX_SUBRS_CALLS 8
874
875
876 /**************************************************************************
877 *
878 * T1_MAX_CHARSTRING_OPERANDS is the charstring stack's capacity. A
879 * minimum of 16 is required.
880 */
881#define T1_MAX_CHARSTRINGS_OPERANDS 32
882
883#endif /* 0 */
884
885
886 typedef struct T1_Decoder_ZoneRec_
887 {
891
893
894
895 typedef struct T1_DecoderRec_* T1_Decoder;
897
898
899 typedef FT_Error
901 FT_UInt glyph_index );
902
903
904 typedef struct T1_Decoder_FuncsRec_
905 {
911 FT_Byte** glyph_names,
912 PS_Blend blend,
913 FT_Bool hinting,
914 FT_Render_Mode hint_mode,
916
918 (*done)( T1_Decoder decoder );
919
920#ifdef T1_CONFIG_OPTION_OLD_ENGINE
922 (*parse_charstrings_old)( T1_Decoder decoder,
923 FT_Byte* base,
924 FT_UInt len );
925#else
928 FT_Byte* base,
929 FT_UInt len );
930#endif
931
934 FT_Byte* charstring_base,
935 FT_ULong charstring_len );
936
937
939
940
941 typedef struct T1_DecoderRec_
942 {
944
947
950
951 FT_Service_PsCMaps psnames; /* for seac */
954
955 FT_Int lenIV; /* internal for sub routine calls */
958 FT_UInt* subrs_len; /* array of subrs length (optional) */
959 FT_Hash subrs_hash; /* used if `num_subrs' was massaged */
960
963
967
968 PS_Blend blend; /* for multiple master support */
969
971
974
977
979
981
983
984
985 /*************************************************************************/
986 /*************************************************************************/
987 /***** *****/
988 /***** CFF BUILDER *****/
989 /***** *****/
990 /*************************************************************************/
991 /*************************************************************************/
992
993
994 typedef struct CFF_Builder_ CFF_Builder;
995
996
997 typedef FT_Error
999 FT_Int count );
1000
1001 typedef void
1003 FT_Pos x,
1004 FT_Pos y,
1005 FT_Byte flag );
1006 typedef FT_Error
1008 FT_Pos x,
1009 FT_Pos y );
1010 typedef FT_Error
1012 FT_Pos x,
1013 FT_Pos y );
1014 typedef void
1016
1017 typedef FT_Error
1019
1021
1023 {
1025 (*init)( CFF_Builder* builder,
1026 TT_Face face,
1027 CFF_Size size,
1028 CFF_GlyphSlot glyph,
1029 FT_Bool hinting );
1030
1032 (*done)( CFF_Builder* builder );
1033
1040
1042
1043
1044 /**************************************************************************
1045 *
1046 * @struct:
1047 * CFF_Builder
1048 *
1049 * @description:
1050 * A structure used during glyph loading to store its outline.
1051 *
1052 * @fields:
1053 * memory ::
1054 * The current memory object.
1055 *
1056 * face ::
1057 * The current face object.
1058 *
1059 * glyph ::
1060 * The current glyph slot.
1061 *
1062 * loader ::
1063 * The current glyph loader.
1064 *
1065 * base ::
1066 * The base glyph outline.
1067 *
1068 * current ::
1069 * The current glyph outline.
1070 *
1071 * pos_x ::
1072 * The horizontal translation (if composite glyph).
1073 *
1074 * pos_y ::
1075 * The vertical translation (if composite glyph).
1076 *
1077 * left_bearing ::
1078 * The left side bearing point.
1079 *
1080 * advance ::
1081 * The horizontal advance vector.
1082 *
1083 * bbox ::
1084 * Unused.
1085 *
1086 * path_begun ::
1087 * A flag which indicates that a new path has begun.
1088 *
1089 * load_points ::
1090 * If this flag is not set, no points are loaded.
1091 *
1092 * no_recurse ::
1093 * Set but not used.
1094 *
1095 * metrics_only ::
1096 * A boolean indicating that we only want to compute the metrics of a
1097 * given glyph, not load all of its points.
1098 *
1099 * hints_funcs ::
1100 * Auxiliary pointer for hinting.
1101 *
1102 * hints_globals ::
1103 * Auxiliary pointer for hinting.
1104 *
1105 * funcs ::
1106 * A table of method pointers for this object.
1107 */
1109 {
1116
1119
1122
1123 FT_BBox bbox; /* bounding box */
1124
1128
1130
1131 void* hints_funcs; /* hinter-specific */
1132 void* hints_globals; /* hinter-specific */
1133
1135 };
1136
1137
1138 /*************************************************************************/
1139 /*************************************************************************/
1140 /***** *****/
1141 /***** CFF DECODER *****/
1142 /***** *****/
1143 /*************************************************************************/
1144 /*************************************************************************/
1145
1146
1147#define CFF_MAX_OPERANDS 48
1148#define CFF_MAX_SUBRS_CALLS 16 /* maximum subroutine nesting; */
1149 /* only 10 are allowed but there exist */
1150 /* fonts like `HiraKakuProN-W3.ttf' */
1151 /* (Hiragino Kaku Gothic ProN W3; */
1152 /* 8.2d6e1; 2014-12-19) that exceed */
1153 /* this limit */
1154#define CFF_MAX_TRANS_ELEMENTS 32
1155
1156 /* execution context charstring zone */
1157
1158 typedef struct CFF_Decoder_Zone_
1159 {
1163
1165
1166
1167 typedef struct CFF_Decoder_
1168 {
1171
1174
1177
1181
1184
1189
1192
1195
1198
1199 FT_Byte** glyph_names; /* for pure CFF fonts only */
1200 FT_UInt num_glyphs; /* number of glyphs in font */
1201
1203
1205
1206 CFF_SubFont current_subfont; /* for current glyph_index */
1207
1210
1212
1213
1215
1217 {
1220 TT_Face face,
1221 CFF_Size size,
1223 FT_Bool hinting,
1224 FT_Render_Mode hint_mode,
1226 CFF_Decoder_Free_Glyph_Callback free_callback );
1227
1230 CFF_Size size,
1231 FT_UInt glyph_index );
1232
1233#ifdef CFF_CONFIG_OPTION_OLD_ENGINE
1234 FT_Error
1235 (*parse_charstrings_old)( CFF_Decoder* decoder,
1236 FT_Byte* charstring_base,
1237 FT_ULong charstring_len,
1238 FT_Bool in_dict );
1239#endif
1240
1243 FT_Byte* charstring_base,
1244 FT_ULong charstring_len );
1245
1247
1248
1249 /*************************************************************************/
1250 /*************************************************************************/
1251 /***** *****/
1252 /***** AFM PARSER *****/
1253 /***** *****/
1254 /*************************************************************************/
1255 /*************************************************************************/
1256
1258
1260 {
1264 FT_Byte* base,
1265 FT_Byte* limit );
1266
1268 (*done)( AFM_Parser parser );
1269
1271 (*parse)( AFM_Parser parser );
1272
1274
1275
1277
1278
1279 /**************************************************************************
1280 *
1281 * @struct:
1282 * AFM_ParserRec
1283 *
1284 * @description:
1285 * An AFM_Parser is a parser for the AFM files.
1286 *
1287 * @fields:
1288 * memory ::
1289 * The object used for memory operations (alloc and realloc).
1290 *
1291 * stream ::
1292 * This is an opaque object.
1293 *
1294 * FontInfo ::
1295 * The result will be stored here.
1296 *
1297 * get_index ::
1298 * A user provided function to get a glyph index by its name.
1299 */
1300 typedef struct AFM_ParserRec_
1301 {
1304
1306
1308 (*get_index)( const char* name,
1309 FT_Offset len,
1310 void* user_data );
1311
1313
1315
1316
1317 /*************************************************************************/
1318 /*************************************************************************/
1319 /***** *****/
1320 /***** TYPE1 CHARMAPS *****/
1321 /***** *****/
1322 /*************************************************************************/
1323 /*************************************************************************/
1324
1326
1327 typedef struct T1_CMap_ClassesRec_
1328 {
1333
1335
1336
1337 /*************************************************************************/
1338 /*************************************************************************/
1339 /***** *****/
1340 /***** PSAux Module Interface *****/
1341 /***** *****/
1342 /*************************************************************************/
1343 /*************************************************************************/
1344
1345 typedef struct PSAux_ServiceRec_
1346 {
1347 /* don't use `PS_Table_Funcs' and friends to avoid compiler warnings */
1352
1356 FT_UShort seed );
1357
1358 FT_UInt32
1359 (*cff_random)( FT_UInt32 r );
1360
1362 (*ps_decoder_init)( PS_Decoder* ps_decoder,
1363 void* decoder,
1364 FT_Bool is_t1 );
1365
1368 PS_Private priv,
1369 CFF_SubFont subfont );
1370
1372
1373 /* fields after this comment line were added after version 2.1.10 */
1375
1377
1379
1380 /* backward compatible type definition */
1382
1383
1384 /*************************************************************************/
1385 /*************************************************************************/
1386 /***** *****/
1387 /***** Some convenience functions *****/
1388 /***** *****/
1389 /*************************************************************************/
1390 /*************************************************************************/
1391
1392#define IS_PS_NEWLINE( ch ) \
1393 ( (ch) == '\r' || \
1394 (ch) == '\n' )
1395
1396#define IS_PS_SPACE( ch ) \
1397 ( (ch) == ' ' || \
1398 IS_PS_NEWLINE( ch ) || \
1399 (ch) == '\t' || \
1400 (ch) == '\f' || \
1401 (ch) == '\0' )
1402
1403#define IS_PS_SPECIAL( ch ) \
1404 ( (ch) == '/' || \
1405 (ch) == '(' || (ch) == ')' || \
1406 (ch) == '<' || (ch) == '>' || \
1407 (ch) == '[' || (ch) == ']' || \
1408 (ch) == '{' || (ch) == '}' || \
1409 (ch) == '%' )
1410
1411#define IS_PS_DELIM( ch ) \
1412 ( IS_PS_SPACE( ch ) || \
1413 IS_PS_SPECIAL( ch ) )
1414
1415#define IS_PS_DIGIT( ch ) \
1416 ( (ch) >= '0' && (ch) <= '9' )
1417
1418#define IS_PS_XDIGIT( ch ) \
1419 ( IS_PS_DIGIT( ch ) || \
1420 ( (ch) >= 'A' && (ch) <= 'F' ) || \
1421 ( (ch) >= 'a' && (ch) <= 'f' ) )
1422
1423#define IS_PS_BASE85( ch ) \
1424 ( (ch) >= '!' && (ch) <= 'u' )
1425
1426#define IS_PS_TOKEN( cur, limit, token ) \
1427 ( (char)(cur)[0] == (token)[0] && \
1428 ( (cur) + sizeof ( (token) ) == (limit) || \
1429 ( (cur) + sizeof( (token) ) < (limit) && \
1430 IS_PS_DELIM( (cur)[sizeof ( (token) ) - 1] ) ) ) && \
1431 ft_strncmp( (char*)(cur), (token), sizeof ( (token) ) - 1 ) == 0 )
1432
1433
1435
1436#endif /* PSAUX_H_ */
1437
1438
1439/* END */
static unsigned char bytes[4]
Definition: adnsresfilter.c:74
static HRESULT get_callback(IBindCtx *pbc, IBindStatusCallback **callback)
Definition: binding.c:1411
WORD face[3]
Definition: mesh.c:4747
unsigned int idx
Definition: utils.c:41
enum FT_Render_Mode_ FT_Render_Mode
#define FT_END_HEADER
Definition: ftheader.h:54
#define FT_BEGIN_HEADER
Definition: ftheader.h:36
FT_BEGIN_HEADER typedef signed long FT_Pos
Definition: ftimage.h:58
#define T1_MAX_CHARSTRINGS_OPERANDS
Definition: ftoption.h:763
#define T1_MAX_SUBRS_CALLS
Definition: ftoption.h:752
typedefFT_BEGIN_HEADER struct FT_MemoryRec_ * FT_Memory
Definition: ftsystem.h:65
FT_BEGIN_HEADER typedef unsigned char FT_Bool
Definition: fttypes.h:108
unsigned long FT_ULong
Definition: fttypes.h:253
unsigned char FT_Byte
Definition: fttypes.h:154
signed long FT_Fixed
Definition: fttypes.h:287
int FT_Error
Definition: fttypes.h:299
signed long FT_Long
Definition: fttypes.h:242
unsigned short FT_UShort
Definition: fttypes.h:209
signed short FT_Short
Definition: fttypes.h:198
unsigned int FT_UInt
Definition: fttypes.h:231
size_t FT_Offset
Definition: fttypes.h:323
signed int FT_Int
Definition: fttypes.h:220
GLint GLint GLint GLint GLint x
Definition: gl.h:1548
GLuint GLuint GLsizei count
Definition: gl.h:1545
GLint GLint GLint GLint GLint GLint y
Definition: gl.h:1548
GLdouble GLdouble GLdouble r
Definition: gl.h:2055
GLuint buffer
Definition: glext.h:5915
GLsizeiptr size
Definition: glext.h:5919
GLuint coords
Definition: glext.h:7368
GLsizei const GLvoid * pointer
Definition: glext.h:5848
GLint limit
Definition: glext.h:10326
GLboolean GLenum GLenum GLvoid * values
Definition: glext.h:5666
GLuint GLsizei GLsizei * length
Definition: glext.h:6040
GLenum GLsizei len
Definition: glext.h:6722
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean flag
Definition: glfuncs.h:52
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat token
Definition: glfuncs.h:210
static const CLSID * objects[]
Definition: apphelp.c:112
static IPrintDialogCallback callback
Definition: printdlg.c:326
static char memory[1024 *256]
Definition: process.c:116
FT_Error(* CFF_Builder_Start_Point_Func)(CFF_Builder *builder, FT_Pos x, FT_Pos y)
Definition: psaux.h:1011
FT_Error(* CFF_Builder_Check_Points_Func)(CFF_Builder *builder, FT_Int count)
Definition: psaux.h:998
struct T1_Decoder_ZoneRec_ T1_Decoder_ZoneRec
FT_Error(* T1_Decoder_Callback)(T1_Decoder decoder, FT_UInt glyph_index)
Definition: psaux.h:900
struct CFF_Decoder_FuncsRec_ CFF_Decoder_FuncsRec
T1_TokenType_
Definition: psaux.h:186
@ T1_TOKEN_TYPE_STRING
Definition: psaux.h:189
@ T1_TOKEN_TYPE_MAX
Definition: psaux.h:194
@ T1_TOKEN_TYPE_ARRAY
Definition: psaux.h:190
@ T1_TOKEN_TYPE_KEY
Definition: psaux.h:191
@ T1_TOKEN_TYPE_ANY
Definition: psaux.h:188
@ T1_TOKEN_TYPE_NONE
Definition: psaux.h:187
const struct CFF_Builder_FuncsRec_ * CFF_Builder_Funcs
Definition: psaux.h:1020
struct PSAux_ServiceRec_ PSAux_ServiceRec
#define CFF_MAX_OPERANDS
Definition: psaux.h:1147
FT_BEGIN_HEADER struct PS_DriverRec_ * PS_Driver
void(* CFF_Builder_Close_Contour_Func)(CFF_Builder *builder)
Definition: psaux.h:1015
struct T1_DecoderRec_ * T1_Decoder
Definition: psaux.h:895
struct T1_TokenRec_ T1_TokenRec
struct PS_Builder_FuncsRec_ PS_Builder_FuncsRec
struct T1_FieldRec_ T1_FieldRec
const struct PS_Builder_FuncsRec_ * PS_Builder_Funcs
Definition: psaux.h:488
PSAux_ServiceRec PSAux_Interface
Definition: psaux.h:1381
const struct T1_Builder_FuncsRec_ * T1_Builder_Funcs
Definition: psaux.h:729
struct T1_Decoder_ZoneRec_ * T1_Decoder_Zone
#define CFF_MAX_SUBRS_CALLS
Definition: psaux.h:1148
struct PS_Parser_FuncsRec_ PS_Parser_FuncsRec
struct T1_BuilderRec_ * T1_Builder
Definition: psaux.h:699
const struct T1_CMap_ClassesRec_ * T1_CMap_Classes
Definition: psaux.h:1325
enum T1_FieldType_ T1_FieldType
void(* T1_Builder_Close_Contour_Func)(T1_Builder builder)
Definition: psaux.h:726
struct PS_Decoder_ PS_Decoder
FT_BEGIN_HEADER struct PS_DriverRec_ PS_DriverRec
FT_Error(* T1_Builder_Check_Points_Func)(T1_Builder builder, FT_Int count)
Definition: psaux.h:703
T1_ParseState_
Definition: psaux.h:755
@ T1_Parse_Have_Width
Definition: psaux.h:757
@ T1_Parse_Have_Path
Definition: psaux.h:759
@ T1_Parse_Start
Definition: psaux.h:756
@ T1_Parse_Have_Moveto
Definition: psaux.h:758
struct T1_BuilderRec_ T1_BuilderRec
void(* CFF_Builder_Add_Point_Func)(CFF_Builder *builder, FT_Pos x, FT_Pos y, FT_Byte flag)
Definition: psaux.h:1002
FT_Error(* CFF_Builder_Add_Contour_Func)(CFF_Builder *builder)
Definition: psaux.h:1018
struct AFM_ParserRec_ * AFM_Parser
Definition: psaux.h:1257
struct CFF_Builder_FuncsRec_ CFF_Builder_FuncsRec
#define PS_MAX_OPERANDS
Definition: psaux.h:600
FT_Error(* CFF_Decoder_Get_Glyph_Callback)(TT_Face face, FT_UInt glyph_index, FT_Byte **pointer, FT_ULong *length)
Definition: psaux.h:620
void(* T1_Field_ParseFunc)(FT_Face face, FT_Pointer parser)
Definition: psaux.h:250
FT_Error(* CFF_Builder_Add_Point1_Func)(CFF_Builder *builder, FT_Pos x, FT_Pos y)
Definition: psaux.h:1007
struct PSAux_ServiceRec_ * PSAux_Service
enum T1_FieldLocation_ T1_FieldLocation
T1_FieldType_
Definition: psaux.h:211
@ T1_FIELD_TYPE_KEY
Definition: psaux.h:218
@ T1_FIELD_TYPE_INTEGER_ARRAY
Definition: psaux.h:221
@ T1_FIELD_TYPE_BBOX
Definition: psaux.h:219
@ T1_FIELD_TYPE_FIXED_1000
Definition: psaux.h:216
@ T1_FIELD_TYPE_STRING
Definition: psaux.h:217
@ T1_FIELD_TYPE_FIXED
Definition: psaux.h:215
@ T1_FIELD_TYPE_NONE
Definition: psaux.h:212
@ T1_FIELD_TYPE_MAX
Definition: psaux.h:226
@ T1_FIELD_TYPE_CALLBACK
Definition: psaux.h:223
@ T1_FIELD_TYPE_INTEGER
Definition: psaux.h:214
@ T1_FIELD_TYPE_FIXED_ARRAY
Definition: psaux.h:222
@ T1_FIELD_TYPE_MM_BBOX
Definition: psaux.h:220
@ T1_FIELD_TYPE_BOOL
Definition: psaux.h:213
struct PS_Decoder_Zone_ PS_Decoder_Zone
enum T1_ParseState_ T1_ParseState
struct T1_CMap_ClassesRec_ T1_CMap_ClassesRec
void(* CFF_Decoder_Free_Glyph_Callback)(TT_Face face, FT_Byte **pointer, FT_ULong length)
Definition: psaux.h:626
struct CFF_Decoder_Zone_ CFF_Decoder_Zone
struct AFM_Parser_FuncsRec_ AFM_Parser_FuncsRec
struct T1_TokenRec_ * T1_Token
Definition: psaux.h:179
struct T1_Decoder_FuncsRec_ T1_Decoder_FuncsRec
struct T1_DecoderRec_ T1_DecoderRec
void(* T1_Builder_Add_Point_Func)(T1_Builder builder, FT_Pos x, FT_Pos y, FT_Byte flag)
Definition: psaux.h:707
FT_Error(* T1_Builder_Add_Contour_Func)(T1_Builder builder)
Definition: psaux.h:718
#define CFF_MAX_TRANS_ELEMENTS
Definition: psaux.h:1154
struct PS_ParserRec_ * PS_Parser
Definition: psaux.h:177
struct PS_TableRec_ * PS_Table
Definition: psaux.h:63
const struct PS_Parser_FuncsRec_ * PS_Parser_Funcs
Definition: psaux.h:371
const struct CFF_Decoder_FuncsRec_ * CFF_Decoder_Funcs
Definition: psaux.h:1214
#define PS_MAX_SUBRS_CALLS
Definition: psaux.h:601
struct CFF_Decoder_ CFF_Decoder
struct PS_ParserRec_ PS_ParserRec
FT_Error(* T1_Builder_Start_Point_Func)(T1_Builder builder, FT_Pos x, FT_Pos y)
Definition: psaux.h:721
struct AFM_ParserRec_ AFM_ParserRec
const struct T1_Decoder_FuncsRec_ * T1_Decoder_Funcs
Definition: psaux.h:896
const struct PS_Table_FuncsRec_ * PS_Table_Funcs
Definition: psaux.h:64
struct PS_Table_FuncsRec_ PS_Table_FuncsRec
enum T1_TokenType_ T1_TokenType
struct T1_Builder_FuncsRec_ T1_Builder_FuncsRec
FT_Error(* T1_Builder_Add_Point1_Func)(T1_Builder builder, FT_Pos x, FT_Pos y)
Definition: psaux.h:713
struct AFM_StreamRec_ * AFM_Stream
Definition: psaux.h:1276
struct PS_TableRec_ PS_TableRec
T1_FieldLocation_
Definition: psaux.h:232
@ T1_FIELD_LOCATION_FONT_EXTRA
Definition: psaux.h:235
@ T1_FIELD_LOCATION_BLEND
Definition: psaux.h:241
@ T1_FIELD_LOCATION_CID_INFO
Definition: psaux.h:233
@ T1_FIELD_LOCATION_BBOX
Definition: psaux.h:238
@ T1_FIELD_LOCATION_PRIVATE
Definition: psaux.h:237
@ T1_FIELD_LOCATION_LOADER
Definition: psaux.h:239
@ T1_FIELD_LOCATION_FONT_INFO
Definition: psaux.h:236
@ T1_FIELD_LOCATION_FACE
Definition: psaux.h:240
@ T1_FIELD_LOCATION_MAX
Definition: psaux.h:244
@ T1_FIELD_LOCATION_FONT_DICT
Definition: psaux.h:234
struct T1_FieldRec_ * T1_Field
Definition: psaux.h:181
FT_Memory memory
Definition: psaux.h:1302
FT_Int(* get_index)(const char *name, FT_Offset len, void *user_data)
Definition: psaux.h:1308
void * user_data
Definition: psaux.h:1312
AFM_Stream stream
Definition: psaux.h:1303
AFM_FontInfo FontInfo
Definition: psaux.h:1305
FT_Error(* init)(AFM_Parser parser, FT_Memory memory, FT_Byte *base, FT_Byte *limit)
Definition: psaux.h:1262
FT_Error(* parse)(AFM_Parser parser)
Definition: psaux.h:1271
void(* done)(AFM_Parser parser)
Definition: psaux.h:1268
CFF_Builder_Check_Points_Func check_points
Definition: psaux.h:1034
CFF_Builder_Add_Point_Func add_point
Definition: psaux.h:1035
CFF_Builder_Add_Contour_Func add_contour
Definition: psaux.h:1037
void(* init)(CFF_Builder *builder, TT_Face face, CFF_Size size, CFF_GlyphSlot glyph, FT_Bool hinting)
Definition: psaux.h:1025
CFF_Builder_Close_Contour_Func close_contour
Definition: psaux.h:1039
CFF_Builder_Add_Point1_Func add_point1
Definition: psaux.h:1036
CFF_Builder_Start_Point_Func start_point
Definition: psaux.h:1038
void(* done)(CFF_Builder *builder)
Definition: psaux.h:1032
FT_Pos pos_x
Definition: psaux.h:1117
FT_Vector left_bearing
Definition: psaux.h:1120
FT_GlyphLoader loader
Definition: psaux.h:1113
TT_Face face
Definition: psaux.h:1111
FT_Memory memory
Definition: psaux.h:1110
FT_Pos pos_y
Definition: psaux.h:1118
CFF_GlyphSlot glyph
Definition: psaux.h:1112
FT_Bool metrics_only
Definition: psaux.h:1129
void * hints_globals
Definition: psaux.h:1132
FT_BBox bbox
Definition: psaux.h:1123
FT_Outline * base
Definition: psaux.h:1114
void * hints_funcs
Definition: psaux.h:1131
FT_Vector advance
Definition: psaux.h:1121
CFF_Builder_FuncsRec funcs
Definition: psaux.h:1134
FT_Bool load_points
Definition: psaux.h:1126
FT_Bool path_begun
Definition: psaux.h:1125
FT_Outline * current
Definition: psaux.h:1115
FT_Bool no_recurse
Definition: psaux.h:1127
FT_Error(* prepare)(CFF_Decoder *decoder, CFF_Size size, FT_UInt glyph_index)
Definition: psaux.h:1229
FT_Error(* parse_charstrings)(PS_Decoder *decoder, FT_Byte *charstring_base, FT_ULong charstring_len)
Definition: psaux.h:1242
void(* init)(CFF_Decoder *decoder, TT_Face face, CFF_Size size, CFF_GlyphSlot slot, FT_Bool hinting, FT_Render_Mode hint_mode, CFF_Decoder_Get_Glyph_Callback get_callback, CFF_Decoder_Free_Glyph_Callback free_callback)
Definition: psaux.h:1219
FT_Byte * cursor
Definition: psaux.h:1162
FT_Byte * limit
Definition: psaux.h:1161
FT_Byte * base
Definition: psaux.h:1160
FT_Vector flex_vectors[7]
Definition: psaux.h:1180
FT_Byte ** glyph_names
Definition: psaux.h:1199
FT_Pos glyph_width
Definition: psaux.h:1182
FT_Bool width_only
Definition: psaux.h:1186
CFF_Builder builder
Definition: psaux.h:1169
FT_Bool read_width
Definition: psaux.h:1185
FT_Int flex_state
Definition: psaux.h:1178
FT_Fixed * top
Definition: psaux.h:1173
FT_Int num_hints
Definition: psaux.h:1187
CFF_Decoder_Get_Glyph_Callback get_glyph_callback
Definition: psaux.h:1208
FT_Int locals_bias
Definition: psaux.h:1193
FT_UInt num_globals
Definition: psaux.h:1191
FT_Pos nominal_width
Definition: psaux.h:1183
FT_Bool seac
Definition: psaux.h:1204
CFF_Font cff
Definition: psaux.h:1170
FT_Fixed buildchar[CFF_MAX_TRANS_ELEMENTS]
Definition: psaux.h:1188
FT_Render_Mode hint_mode
Definition: psaux.h:1202
FT_Byte ** locals
Definition: psaux.h:1196
CFF_Decoder_Zone * zone
Definition: psaux.h:1176
FT_UInt num_glyphs
Definition: psaux.h:1200
CFF_Decoder_Zone zones[CFF_MAX_SUBRS_CALLS+1]
Definition: psaux.h:1175
FT_Int globals_bias
Definition: psaux.h:1194
FT_Byte ** globals
Definition: psaux.h:1197
CFF_Decoder_Free_Glyph_Callback free_glyph_callback
Definition: psaux.h:1209
CFF_SubFont current_subfont
Definition: psaux.h:1206
FT_UInt num_locals
Definition: psaux.h:1190
FT_Int num_flex_vectors
Definition: psaux.h:1179
void(* ps_decoder_init)(PS_Decoder *ps_decoder, void *decoder, FT_Bool is_t1)
Definition: psaux.h:1362
FT_UInt32(* cff_random)(FT_UInt32 r)
Definition: psaux.h:1359
const T1_Builder_FuncsRec * t1_builder_funcs
Definition: psaux.h:1350
T1_CMap_Classes t1_cmap_classes
Definition: psaux.h:1371
void(* t1_make_subfont)(FT_Face face, PS_Private priv, CFF_SubFont subfont)
Definition: psaux.h:1367
const T1_Decoder_FuncsRec * t1_decoder_funcs
Definition: psaux.h:1351
void(* t1_decrypt)(FT_Byte *buffer, FT_Offset length, FT_UShort seed)
Definition: psaux.h:1354
const AFM_Parser_FuncsRec * afm_parser_funcs
Definition: psaux.h:1374
const PS_Parser_FuncsRec * ps_parser_funcs
Definition: psaux.h:1349
const CFF_Decoder_FuncsRec * cff_decoder_funcs
Definition: psaux.h:1376
const PS_Table_FuncsRec * ps_table_funcs
Definition: psaux.h:1348
void(* init)(PS_Builder *ps_builder, void *builder, FT_Bool is_t1)
Definition: psaux.h:493
void(* done)(PS_Builder *builder)
Definition: psaux.h:498
FT_Bool load_points
Definition: psaux.h:581
FT_Vector * advance
Definition: psaux.h:577
FT_Vector * left_bearing
Definition: psaux.h:576
CFF_GlyphSlot glyph
Definition: psaux.h:568
FT_Pos * pos_y
Definition: psaux.h:574
FT_Bool no_recurse
Definition: psaux.h:582
FT_Memory memory
Definition: psaux.h:566
FT_GlyphLoader loader
Definition: psaux.h:569
FT_Pos * pos_x
Definition: psaux.h:573
PS_Builder_FuncsRec funcs
Definition: psaux.h:587
FT_Bool path_begun
Definition: psaux.h:580
FT_Bool is_t1
Definition: psaux.h:585
FT_BBox * bbox
Definition: psaux.h:579
FT_Outline * base
Definition: psaux.h:570
FT_Face face
Definition: psaux.h:567
FT_Outline * current
Definition: psaux.h:571
FT_Bool metrics_only
Definition: psaux.h:584
FT_Byte * limit
Definition: psaux.h:613
FT_Byte * cursor
Definition: psaux.h:614
FT_Byte * base
Definition: psaux.h:612
FT_Generic * cf2_instance
Definition: psaux.h:647
FT_Matrix font_matrix
Definition: psaux.h:679
FT_Byte ** globals
Definition: psaux.h:660
FT_Byte ** glyph_names
Definition: psaux.h:662
FT_UInt num_globals
Definition: psaux.h:654
FT_Int num_flex_vectors
Definition: psaux.h:642
PS_Decoder_Zone * zone
Definition: psaux.h:639
FT_Render_Mode hint_mode
Definition: psaux.h:665
FT_Hash locals_hash
Definition: psaux.h:677
CFF_SubFont current_subfont
Definition: psaux.h:646
FT_UInt num_glyphs
Definition: psaux.h:663
FT_Long * buildchar
Definition: psaux.h:684
CFF_Font cff
Definition: psaux.h:645
FT_Bool seac
Definition: psaux.h:667
FT_Byte ** locals
Definition: psaux.h:659
FT_Vector font_offset
Definition: psaux.h:680
CFF_Decoder_Get_Glyph_Callback get_glyph_callback
Definition: psaux.h:669
FT_UInt len_buildchar
Definition: psaux.h:685
PS_Decoder_Zone zones[PS_MAX_SUBRS_CALLS+1]
Definition: psaux.h:638
FT_Fixed * top
Definition: psaux.h:636
FT_Int flex_state
Definition: psaux.h:641
FT_Vector flex_vectors[7]
Definition: psaux.h:643
FT_Int lenIV
Definition: psaux.h:675
FT_UInt num_locals
Definition: psaux.h:653
FT_Int num_hints
Definition: psaux.h:651
FT_UInt * locals_len
Definition: psaux.h:676
CFF_Decoder_Free_Glyph_Callback free_glyph_callback
Definition: psaux.h:670
FT_Int globals_bias
Definition: psaux.h:657
FT_Bool width_only
Definition: psaux.h:650
PS_Builder builder
Definition: psaux.h:633
FT_Service_PsCMaps psnames
Definition: psaux.h:673
PS_Blend blend
Definition: psaux.h:682
FT_Pos * glyph_width
Definition: psaux.h:649
FT_Int locals_bias
Definition: psaux.h:656
FT_Int darken_params[8]
Definition: psaux.h:48
FT_UInt hinting_engine
Definition: psaux.h:46
FT_DriverRec root
Definition: psaux.h:44
FT_Bool no_stem_darkening
Definition: psaux.h:47
FT_Int32 random_seed
Definition: psaux.h:49
FT_Byte * base
Definition: psaux.h:468
FT_Memory memory
Definition: psaux.h:471
PS_Parser_FuncsRec funcs
Definition: psaux.h:473
FT_Byte * cursor
Definition: psaux.h:467
FT_Error error
Definition: psaux.h:470
FT_Byte * limit
Definition: psaux.h:469
void(* to_token)(PS_Parser parser, T1_Token token)
Definition: psaux.h:413
FT_Error(* load_field_table)(PS_Parser parser, const T1_Field field, void **objects, FT_UInt max_objects, FT_ULong *pflags)
Definition: psaux.h:429
FT_Long(* to_int)(PS_Parser parser)
Definition: psaux.h:390
FT_Error(* to_bytes)(PS_Parser parser, FT_Byte *bytes, FT_Offset max_bytes, FT_ULong *pnum_bytes, FT_Bool delimiters)
Definition: psaux.h:396
void(* skip_spaces)(PS_Parser parser)
Definition: psaux.h:385
FT_Error(* load_field)(PS_Parser parser, const T1_Field field, void **objects, FT_UInt max_objects, FT_ULong *pflags)
Definition: psaux.h:422
void(* skip_PS_token)(PS_Parser parser)
Definition: psaux.h:387
void(* done)(PS_Parser parser)
Definition: psaux.h:382
FT_Int(* to_fixed_array)(PS_Parser parser, FT_Int max_values, FT_Fixed *values, FT_Int power_ten)
Definition: psaux.h:407
void(* init)(PS_Parser parser, FT_Byte *base, FT_Byte *limit, FT_Memory memory)
Definition: psaux.h:376
FT_Int(* to_coord_array)(PS_Parser parser, FT_Int max_coords, FT_Short *coords)
Definition: psaux.h:403
FT_Fixed(* to_fixed)(PS_Parser parser, FT_Int power_ten)
Definition: psaux.h:392
void(* to_token_array)(PS_Parser parser, T1_Token tokens, FT_UInt max_tokens, FT_Int *pnum_tokens)
Definition: psaux.h:416
FT_Memory memory
Definition: psaux.h:163
FT_Byte ** elements
Definition: psaux.h:160
FT_Int num_elems
Definition: psaux.h:159
FT_ULong init
Definition: psaux.h:156
FT_Byte * block
Definition: psaux.h:153
FT_Int max_elems
Definition: psaux.h:158
FT_Offset cursor
Definition: psaux.h:154
FT_Offset capacity
Definition: psaux.h:155
PS_Table_FuncsRec funcs
Definition: psaux.h:164
FT_UInt * lengths
Definition: psaux.h:161
FT_Error(* add)(PS_Table table, FT_Int idx, void *object, FT_UInt length)
Definition: psaux.h:99
FT_Error(* init)(PS_Table table, FT_Int count, FT_Memory memory)
Definition: psaux.h:91
void(* release)(PS_Table table)
Definition: psaux.h:105
void(* done)(PS_Table table)
Definition: psaux.h:96
FT_Bool no_recurse
Definition: psaux.h:846
FT_GlyphSlot glyph
Definition: psaux.h:832
FT_Vector advance
Definition: psaux.h:841
FT_BBox bbox
Definition: psaux.h:843
FT_Outline * base
Definition: psaux.h:834
FT_Face face
Definition: psaux.h:831
FT_Outline * current
Definition: psaux.h:835
FT_Vector left_bearing
Definition: psaux.h:840
FT_Bool metrics_only
Definition: psaux.h:848
FT_Memory memory
Definition: psaux.h:830
FT_Bool load_points
Definition: psaux.h:845
T1_Builder_FuncsRec funcs
Definition: psaux.h:853
FT_Pos pos_y
Definition: psaux.h:838
FT_Pos pos_x
Definition: psaux.h:837
FT_GlyphLoader loader
Definition: psaux.h:833
void * hints_globals
Definition: psaux.h:851
void * hints_funcs
Definition: psaux.h:850
T1_ParseState parse_state
Definition: psaux.h:844
T1_Builder_Check_Points_Func check_points
Definition: psaux.h:743
T1_Builder_Add_Point1_Func add_point1
Definition: psaux.h:745
void(* init)(T1_Builder builder, FT_Face face, FT_Size size, FT_GlyphSlot slot, FT_Bool hinting)
Definition: psaux.h:734
T1_Builder_Add_Point_Func add_point
Definition: psaux.h:744
T1_Builder_Start_Point_Func start_point
Definition: psaux.h:747
void(* done)(T1_Builder builder)
Definition: psaux.h:741
T1_Builder_Close_Contour_Func close_contour
Definition: psaux.h:748
T1_Builder_Add_Contour_Func add_contour
Definition: psaux.h:746
FT_CMap_Class standard
Definition: psaux.h:1329
FT_CMap_Class custom
Definition: psaux.h:1331
FT_CMap_Class expert
Definition: psaux.h:1330
FT_CMap_Class unicode
Definition: psaux.h:1332
FT_Byte ** subrs
Definition: psaux.h:957
FT_Matrix font_matrix
Definition: psaux.h:961
FT_UInt * subrs_len
Definition: psaux.h:958
PS_Blend blend
Definition: psaux.h:968
FT_UInt num_glyphs
Definition: psaux.h:952
FT_Int flex_state
Definition: psaux.h:964
FT_Render_Mode hint_mode
Definition: psaux.h:970
FT_Int num_flex_vectors
Definition: psaux.h:965
FT_Vector flex_vectors[7]
Definition: psaux.h:966
FT_Bool seac
Definition: psaux.h:978
T1_Decoder_ZoneRec zones[T1_MAX_SUBRS_CALLS+1]
Definition: psaux.h:948
FT_UInt len_buildchar
Definition: psaux.h:976
FT_Long * top
Definition: psaux.h:946
T1_Decoder_FuncsRec funcs
Definition: psaux.h:973
FT_Int num_subrs
Definition: psaux.h:956
T1_BuilderRec builder
Definition: psaux.h:943
T1_Decoder_Callback parse_callback
Definition: psaux.h:972
FT_Vector font_offset
Definition: psaux.h:962
FT_Long * buildchar
Definition: psaux.h:975
FT_Service_PsCMaps psnames
Definition: psaux.h:951
FT_Hash subrs_hash
Definition: psaux.h:959
FT_Byte ** glyph_names
Definition: psaux.h:953
T1_Decoder_Zone zone
Definition: psaux.h:949
FT_Int lenIV
Definition: psaux.h:955
FT_Generic cf2_instance
Definition: psaux.h:980
void(* done)(T1_Decoder decoder)
Definition: psaux.h:918
FT_Error(* parse_charstrings)(PS_Decoder *decoder, FT_Byte *charstring_base, FT_ULong charstring_len)
Definition: psaux.h:933
FT_Error(* parse_metrics)(T1_Decoder decoder, FT_Byte *base, FT_UInt len)
Definition: psaux.h:927
FT_Error(* init)(T1_Decoder decoder, FT_Face face, FT_Size size, FT_GlyphSlot slot, FT_Byte **glyph_names, PS_Blend blend, FT_Bool hinting, FT_Render_Mode hint_mode, T1_Decoder_Callback callback)
Definition: psaux.h:907
FT_Byte * cursor
Definition: psaux.h:888
FT_Byte * limit
Definition: psaux.h:890
FT_Byte * base
Definition: psaux.h:889
T1_FieldLocation location
Definition: psaux.h:258
FT_UInt offset
Definition: psaux.h:261
FT_UInt count_offset
Definition: psaux.h:265
FT_UInt dict
Definition: psaux.h:271
FT_UInt array_max
Definition: psaux.h:263
FT_Byte size
Definition: psaux.h:262
T1_Field_ParseFunc reader
Definition: psaux.h:260
const char * ident
Definition: psaux.h:257
T1_FieldType type
Definition: psaux.h:259
FT_Byte * start
Definition: psaux.h:202
T1_TokenType type
Definition: psaux.h:204
FT_Byte * limit
Definition: psaux.h:203
Definition: parser.c:44
Definition: name.c:39
Definition: import.c:81
Definition: format.c:80
struct _slot slot
Definition: vfat.h:196