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

Side by Side Diff: src/sfnt/ttcmap.h

Issue 89753003: Update freetype to latest version of ASOP. (Closed) Base URL: https://chromium.googlesource.com/chromium/src/third_party/freetype.git@master
Patch Set: Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/sfnt/ttbdf.c ('k') | src/sfnt/ttcmap.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /***************************************************************************/ 1 /***************************************************************************/
2 /* */ 2 /* */
3 /* ttcmap.h */ 3 /* ttcmap.h */
4 /* */ 4 /* */
5 /* TrueType character mapping table (cmap) support (specification). */ 5 /* TrueType character mapping table (cmap) support (specification). */
6 /* */ 6 /* */
7 /* Copyright 2002, 2003, 2004, 2005 by */ 7 /* Copyright 2002-2005, 2009, 2012 by */
8 /* David Turner, Robert Wilhelm, and Werner Lemberg. */ 8 /* David Turner, Robert Wilhelm, and Werner Lemberg. */
9 /* */ 9 /* */
10 /* This file is part of the FreeType project, and may only be used, */ 10 /* This file is part of the FreeType project, and may only be used, */
11 /* modified, and distributed under the terms of the FreeType project */ 11 /* modified, and distributed under the terms of the FreeType project */
12 /* license, LICENSE.TXT. By continuing to use, modify, or distribute */ 12 /* license, LICENSE.TXT. By continuing to use, modify, or distribute */
13 /* this file you indicate that you have read the license and */ 13 /* this file you indicate that you have read the license and */
14 /* understand and accept it fully. */ 14 /* understand and accept it fully. */
15 /* */ 15 /* */
16 /***************************************************************************/ 16 /***************************************************************************/
17 17
(...skipping 30 matching lines...) Expand all
48 48
49 typedef struct TT_CMap_ClassRec_ 49 typedef struct TT_CMap_ClassRec_
50 { 50 {
51 FT_CMap_ClassRec clazz; 51 FT_CMap_ClassRec clazz;
52 FT_UInt format; 52 FT_UInt format;
53 TT_CMap_ValidateFunc validate; 53 TT_CMap_ValidateFunc validate;
54 TT_CMap_Info_GetFunc get_cmap_info; 54 TT_CMap_Info_GetFunc get_cmap_info;
55 55
56 } TT_CMap_ClassRec; 56 } TT_CMap_ClassRec;
57 57
58
58 #ifndef FT_CONFIG_OPTION_PIC 59 #ifndef FT_CONFIG_OPTION_PIC
59 60
60 #define FT_DEFINE_TT_CMAP(class_, size_, init_, done_, char_index_, \ 61 #define FT_DEFINE_TT_CMAP( class_, \
61 char_next_, char_var_index_, char_var_default_, variant_list_, \ 62 size_, \
62 charvariant_list_,variantchar_list_, \ 63 init_, \
63 format_, validate_, get_cmap_info_) \ 64 done_, \
64 FT_CALLBACK_TABLE_DEF \ 65 char_index_, \
65 const TT_CMap_ClassRec class_ = \ 66 char_next_, \
66 { \ 67 char_var_index_, \
67 {size_, init_, done_, char_index_, \ 68 char_var_default_, \
68 char_next_, char_var_index_, char_var_default_, variant_list_, \ 69 variant_list_, \
69 charvariant_list_, variantchar_list_}, \ 70 charvariant_list_, \
70 format_, validate_, get_cmap_info_ \ 71 variantchar_list_, \
72 format_, \
73 validate_, \
74 get_cmap_info_ ) \
75 FT_CALLBACK_TABLE_DEF \
76 const TT_CMap_ClassRec class_ = \
77 { \
78 { size_, \
79 init_, \
80 done_, \
81 char_index_, \
82 char_next_, \
83 char_var_index_, \
84 char_var_default_, \
85 variant_list_, \
86 charvariant_list_, \
87 variantchar_list_ \
88 }, \
89 \
90 format_, \
91 validate_, \
92 get_cmap_info_ \
71 }; 93 };
72 94
73 #else /* FT_CONFIG_OPTION_PIC */ 95 #else /* FT_CONFIG_OPTION_PIC */
74 96
75 #define FT_DEFINE_TT_CMAP(class_, size_, init_, done_, char_index_, \ 97 #define FT_DEFINE_TT_CMAP( class_, \
76 char_next_, char_var_index_, char_var_default_, variant_list_, \ 98 size_, \
77 charvariant_list_,variantchar_list_, \ 99 init_, \
78 format_, validate_, get_cmap_info_) \ 100 done_, \
79 void \ 101 char_index_, \
80 FT_Init_Class_##class_( TT_CMap_ClassRec* clazz ) \ 102 char_next_, \
81 { \ 103 char_var_index_, \
82 clazz->clazz.size = size_; \ 104 char_var_default_, \
83 clazz->clazz.init = init_; \ 105 variant_list_, \
84 clazz->clazz.done = done_; \ 106 charvariant_list_, \
85 clazz->clazz.char_index = char_index_; \ 107 variantchar_list_, \
86 clazz->clazz.char_next = char_next_; \ 108 format_, \
87 clazz->clazz.char_var_index = char_var_index_; \ 109 validate_, \
88 clazz->clazz.char_var_default = char_var_default_; \ 110 get_cmap_info_ ) \
89 clazz->clazz.variant_list = variant_list_; \ 111 void \
90 clazz->clazz.charvariant_list = charvariant_list_; \ 112 FT_Init_Class_ ## class_( TT_CMap_ClassRec* clazz ) \
91 clazz->clazz.variantchar_list = variantchar_list_; \ 113 { \
92 clazz->format = format_; \ 114 clazz->clazz.size = size_; \
93 clazz->validate = validate_; \ 115 clazz->clazz.init = init_; \
94 clazz->get_cmap_info = get_cmap_info_; \ 116 clazz->clazz.done = done_; \
117 clazz->clazz.char_index = char_index_; \
118 clazz->clazz.char_next = char_next_; \
119 clazz->clazz.char_var_index = char_var_index_; \
120 clazz->clazz.char_var_default = char_var_default_; \
121 clazz->clazz.variant_list = variant_list_; \
122 clazz->clazz.charvariant_list = charvariant_list_; \
123 clazz->clazz.variantchar_list = variantchar_list_; \
124 clazz->format = format_; \
125 clazz->validate = validate_; \
126 clazz->get_cmap_info = get_cmap_info_; \
95 } 127 }
96 128
97 #endif /* FT_CONFIG_OPTION_PIC */ 129 #endif /* FT_CONFIG_OPTION_PIC */
98 130
131
99 typedef struct TT_ValidatorRec_ 132 typedef struct TT_ValidatorRec_
100 { 133 {
101 FT_ValidatorRec validator; 134 FT_ValidatorRec validator;
102 FT_UInt num_glyphs; 135 FT_UInt num_glyphs;
103 136
104 } TT_ValidatorRec, *TT_Validator; 137 } TT_ValidatorRec, *TT_Validator;
105 138
106 139
107 #define TT_VALIDATOR( x ) ((TT_Validator)( x )) 140 #define TT_VALIDATOR( x ) ( (TT_Validator)( x ) )
108 #define TT_VALID_GLYPH_COUNT( x ) TT_VALIDATOR( x )->num_glyphs 141 #define TT_VALID_GLYPH_COUNT( x ) TT_VALIDATOR( x )->num_glyphs
109 142
110 143
111 FT_LOCAL( FT_Error ) 144 FT_LOCAL( FT_Error )
112 tt_face_build_cmaps( TT_Face face ); 145 tt_face_build_cmaps( TT_Face face );
113 146
114 /* used in tt-cmaps service */ 147 /* used in tt-cmaps service */
115 FT_LOCAL( FT_Error ) 148 FT_LOCAL( FT_Error )
116 tt_get_cmap_info( FT_CharMap charmap, 149 tt_get_cmap_info( FT_CharMap charmap,
117 TT_CMapInfo *cmap_info ); 150 TT_CMapInfo *cmap_info );
118 151
119 152
120 FT_END_HEADER 153 FT_END_HEADER
121 154
122 #endif /* __TTCMAP_H__ */ 155 #endif /* __TTCMAP_H__ */
123 156
124 157
125 /* END */ 158 /* END */
OLDNEW
« no previous file with comments | « src/sfnt/ttbdf.c ('k') | src/sfnt/ttcmap.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698