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

Side by Side Diff: third_party/freetype/include/freetype.h

Issue 815103002: Update freetype to 2.5.4. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Adjust GYP and GN Created 6 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 | « third_party/freetype/include/config/ftstdlib.h ('k') | third_party/freetype/include/ft2build.h » ('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 /* freetype.h */ 3 /* freetype.h */
4 /* */ 4 /* */
5 /* FreeType high-level API and common types (specification only). */ 5 /* FreeType high-level API and common types (specification only). */
6 /* */ 6 /* */
7 /* Copyright 1996-2013 by */ 7 /* Copyright 1996-2014 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
18 18
19 #ifndef __FREETYPE_H__ 19 #ifndef __FREETYPE_H__
20 #define __FREETYPE_H__ 20 #define __FREETYPE_H__
21 21
22 22
23 #ifndef FT_FREETYPE_H 23 #ifndef FT_FREETYPE_H
24 #error "`ft2build.h' hasn't been included yet!" 24 #error "`ft2build.h' hasn't been included yet!"
25 #error "Please always use macros to include FreeType header files." 25 #error "Please always use macros to include FreeType header files."
26 #error "Example:" 26 #error "Example:"
27 #error " #include <ft2build.h>" 27 #error " #include <ft2build.h>"
28 #error " #include FT_FREETYPE_H" 28 #error " #include FT_FREETYPE_H"
29 #endif 29 #endif
30 30
31 31
32 #include "../ft2build.h" 32 #include <ft2build.h>
33 #include "config/ftconfig.h" 33 #include FT_CONFIG_CONFIG_H
34 #include "fttypes.h" 34 #include FT_TYPES_H
35 #include "fterrors.h" 35 #include FT_ERRORS_H
36 36
37 37
38 FT_BEGIN_HEADER 38 FT_BEGIN_HEADER
39 39
40 40
41 41
42 /*************************************************************************/ 42 /*************************************************************************/
43 /* */ 43 /* */
44 /* <Section> */ 44 /* <Section> */
45 /* header_inclusion */
46 /* */
47 /* <Title> */
48 /* FreeType's header inclusion scheme */
49 /* */
50 /* <Abstract> */
51 /* How client applications should include FreeType header files. */
52 /* */
53 /* <Description> */
54 /* To be as flexible as possible (and for historical reasons), */
55 /* FreeType uses a very special inclusion scheme to load header */
56 /* files, for example */
57 /* */
58 /* { */
59 /* #include <ft2build.h> */
60 /* */
61 /* #include FT_FREETYPE_H */
62 /* #include FT_OUTLINE_H */
63 /* } */
64 /* */
65 /* A compiler and its preprocessor only needs an include path to find */
66 /* the file `ft2build.h'; the exact locations and names of the other */
67 /* FreeType header files are hidden by preprocessor macro names, */
68 /* loaded by `ft2build.h'. The API documentation always gives the */
69 /* header macro name needed for a particular function. */
70 /* */
71 /*************************************************************************/
72
73
74 /*************************************************************************/
75 /* */
76 /* <Section> */
45 /* user_allocation */ 77 /* user_allocation */
46 /* */ 78 /* */
47 /* <Title> */ 79 /* <Title> */
48 /* User allocation */ 80 /* User allocation */
49 /* */ 81 /* */
50 /* <Abstract> */ 82 /* <Abstract> */
51 /* How client applications should allocate FreeType data structures. */ 83 /* How client applications should allocate FreeType data structures. */
52 /* */ 84 /* */
53 /* <Description> */ 85 /* <Description> */
54 /* FreeType assumes that structures allocated by the user and passed */ 86 /* FreeType assumes that structures allocated by the user and passed */
(...skipping 19 matching lines...) Expand all
74 /* <Section> */ 106 /* <Section> */
75 /* base_interface */ 107 /* base_interface */
76 /* */ 108 /* */
77 /* <Title> */ 109 /* <Title> */
78 /* Base Interface */ 110 /* Base Interface */
79 /* */ 111 /* */
80 /* <Abstract> */ 112 /* <Abstract> */
81 /* The FreeType~2 base font interface. */ 113 /* The FreeType~2 base font interface. */
82 /* */ 114 /* */
83 /* <Description> */ 115 /* <Description> */
84 /* This section describes the public high-level API of FreeType~2. */ 116 /* This section describes the most important public high-level API */
117 /* functions of FreeType~2. */
85 /* */ 118 /* */
86 /* <Order> */ 119 /* <Order> */
87 /* FT_Library */ 120 /* FT_Library */
88 /* FT_Face */ 121 /* FT_Face */
89 /* FT_Size */ 122 /* FT_Size */
90 /* FT_GlyphSlot */ 123 /* FT_GlyphSlot */
91 /* FT_CharMap */ 124 /* FT_CharMap */
92 /* FT_Encoding */ 125 /* FT_Encoding */
126 /* FT_ENC_TAG */
93 /* */ 127 /* */
94 /* FT_FaceRec */ 128 /* FT_FaceRec */
95 /* */ 129 /* */
96 /* FT_FACE_FLAG_SCALABLE */ 130 /* FT_FACE_FLAG_SCALABLE */
97 /* FT_FACE_FLAG_FIXED_SIZES */ 131 /* FT_FACE_FLAG_FIXED_SIZES */
98 /* FT_FACE_FLAG_FIXED_WIDTH */ 132 /* FT_FACE_FLAG_FIXED_WIDTH */
99 /* FT_FACE_FLAG_HORIZONTAL */ 133 /* FT_FACE_FLAG_HORIZONTAL */
100 /* FT_FACE_FLAG_VERTICAL */ 134 /* FT_FACE_FLAG_VERTICAL */
135 /* FT_FACE_FLAG_COLOR */
101 /* FT_FACE_FLAG_SFNT */ 136 /* FT_FACE_FLAG_SFNT */
137 /* FT_FACE_FLAG_CID_KEYED */
138 /* FT_FACE_FLAG_TRICKY */
102 /* FT_FACE_FLAG_KERNING */ 139 /* FT_FACE_FLAG_KERNING */
103 /* FT_FACE_FLAG_MULTIPLE_MASTERS */ 140 /* FT_FACE_FLAG_MULTIPLE_MASTERS */
104 /* FT_FACE_FLAG_GLYPH_NAMES */ 141 /* FT_FACE_FLAG_GLYPH_NAMES */
105 /* FT_FACE_FLAG_EXTERNAL_STREAM */ 142 /* FT_FACE_FLAG_EXTERNAL_STREAM */
106 /* FT_FACE_FLAG_FAST_GLYPHS */
107 /* FT_FACE_FLAG_HINTER */ 143 /* FT_FACE_FLAG_HINTER */
144 /* FT_FACE_FLAG_TRICKY */
145 /* */
146 /* FT_HAS_HORIZONTAL */
147 /* FT_HAS_VERTICAL */
148 /* FT_HAS_KERNING */
149 /* FT_HAS_FIXED_SIZES */
150 /* FT_HAS_GLYPH_NAMES */
151 /* FT_HAS_MULTIPLE_MASTERS */
152 /* FT_HAS_COLOR */
153 /* */
154 /* FT_IS_SFNT */
155 /* FT_IS_SCALABLE */
156 /* FT_IS_FIXED_WIDTH */
157 /* FT_IS_CID_KEYED */
158 /* FT_IS_TRICKY */
108 /* */ 159 /* */
109 /* FT_STYLE_FLAG_BOLD */ 160 /* FT_STYLE_FLAG_BOLD */
110 /* FT_STYLE_FLAG_ITALIC */ 161 /* FT_STYLE_FLAG_ITALIC */
111 /* */ 162 /* */
112 /* FT_SizeRec */ 163 /* FT_SizeRec */
113 /* FT_Size_Metrics */ 164 /* FT_Size_Metrics */
114 /* */ 165 /* */
115 /* FT_GlyphSlotRec */ 166 /* FT_GlyphSlotRec */
116 /* FT_Glyph_Metrics */ 167 /* FT_Glyph_Metrics */
117 /* FT_SubGlyph */ 168 /* FT_SubGlyph */
118 /* */ 169 /* */
119 /* FT_Bitmap_Size */ 170 /* FT_Bitmap_Size */
120 /* */ 171 /* */
121 /* FT_Init_FreeType */ 172 /* FT_Init_FreeType */
122 /* FT_Done_FreeType */ 173 /* FT_Done_FreeType */
123 /* */ 174 /* */
124 /* FT_New_Face */ 175 /* FT_New_Face */
125 /* FT_Done_Face */ 176 /* FT_Done_Face */
177 /* FT_Reference_Face */
126 /* FT_New_Memory_Face */ 178 /* FT_New_Memory_Face */
127 /* FT_Open_Face */ 179 /* FT_Open_Face */
128 /* FT_Open_Args */ 180 /* FT_Open_Args */
129 /* FT_Parameter */ 181 /* FT_Parameter */
130 /* FT_Attach_File */ 182 /* FT_Attach_File */
131 /* FT_Attach_Stream */ 183 /* FT_Attach_Stream */
132 /* */ 184 /* */
133 /* FT_Set_Char_Size */ 185 /* FT_Set_Char_Size */
134 /* FT_Set_Pixel_Sizes */ 186 /* FT_Set_Pixel_Sizes */
135 /* FT_Request_Size */ 187 /* FT_Request_Size */
136 /* FT_Select_Size */ 188 /* FT_Select_Size */
137 /* FT_Size_Request_Type */ 189 /* FT_Size_Request_Type */
190 /* FT_Size_RequestRec */
138 /* FT_Size_Request */ 191 /* FT_Size_Request */
139 /* FT_Set_Transform */ 192 /* FT_Set_Transform */
140 /* FT_Load_Glyph */ 193 /* FT_Load_Glyph */
141 /* FT_Get_Char_Index */ 194 /* FT_Get_Char_Index */
195 /* FT_Get_First_Char */
196 /* FT_Get_Next_Char */
142 /* FT_Get_Name_Index */ 197 /* FT_Get_Name_Index */
143 /* FT_Load_Char */ 198 /* FT_Load_Char */
144 /* */ 199 /* */
145 /* FT_OPEN_MEMORY */ 200 /* FT_OPEN_MEMORY */
146 /* FT_OPEN_STREAM */ 201 /* FT_OPEN_STREAM */
147 /* FT_OPEN_PATHNAME */ 202 /* FT_OPEN_PATHNAME */
148 /* FT_OPEN_DRIVER */ 203 /* FT_OPEN_DRIVER */
149 /* FT_OPEN_PARAMS */ 204 /* FT_OPEN_PARAMS */
150 /* */ 205 /* */
151 /* FT_LOAD_DEFAULT */ 206 /* FT_LOAD_DEFAULT */
152 /* FT_LOAD_RENDER */ 207 /* FT_LOAD_RENDER */
153 /* FT_LOAD_MONOCHROME */ 208 /* FT_LOAD_MONOCHROME */
154 /* FT_LOAD_LINEAR_DESIGN */ 209 /* FT_LOAD_LINEAR_DESIGN */
155 /* FT_LOAD_NO_SCALE */ 210 /* FT_LOAD_NO_SCALE */
156 /* FT_LOAD_NO_HINTING */ 211 /* FT_LOAD_NO_HINTING */
157 /* FT_LOAD_NO_BITMAP */ 212 /* FT_LOAD_NO_BITMAP */
158 /* FT_LOAD_CROP_BITMAP */ 213 /* FT_LOAD_NO_AUTOHINT */
214 /* FT_LOAD_COLOR */
159 /* */ 215 /* */
160 /* FT_LOAD_VERTICAL_LAYOUT */ 216 /* FT_LOAD_VERTICAL_LAYOUT */
161 /* FT_LOAD_IGNORE_TRANSFORM */ 217 /* FT_LOAD_IGNORE_TRANSFORM */
162 /* FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH */
163 /* FT_LOAD_FORCE_AUTOHINT */ 218 /* FT_LOAD_FORCE_AUTOHINT */
164 /* FT_LOAD_NO_RECURSE */ 219 /* FT_LOAD_NO_RECURSE */
165 /* FT_LOAD_PEDANTIC */ 220 /* FT_LOAD_PEDANTIC */
166 /* */ 221 /* */
167 /* FT_LOAD_TARGET_NORMAL */ 222 /* FT_LOAD_TARGET_NORMAL */
168 /* FT_LOAD_TARGET_LIGHT */ 223 /* FT_LOAD_TARGET_LIGHT */
169 /* FT_LOAD_TARGET_MONO */ 224 /* FT_LOAD_TARGET_MONO */
170 /* FT_LOAD_TARGET_LCD */ 225 /* FT_LOAD_TARGET_LCD */
171 /* FT_LOAD_TARGET_LCD_V */ 226 /* FT_LOAD_TARGET_LCD_V */
172 /* */ 227 /* */
228 /* FT_LOAD_TARGET_MODE */
229 /* */
173 /* FT_Render_Glyph */ 230 /* FT_Render_Glyph */
174 /* FT_Render_Mode */ 231 /* FT_Render_Mode */
175 /* FT_Get_Kerning */ 232 /* FT_Get_Kerning */
176 /* FT_Kerning_Mode */ 233 /* FT_Kerning_Mode */
177 /* FT_Get_Track_Kerning */ 234 /* FT_Get_Track_Kerning */
178 /* FT_Get_Glyph_Name */ 235 /* FT_Get_Glyph_Name */
179 /* FT_Get_Postscript_Name */ 236 /* FT_Get_Postscript_Name */
180 /* */ 237 /* */
181 /* FT_CharMapRec */ 238 /* FT_CharMapRec */
182 /* FT_Select_Charmap */ 239 /* FT_Select_Charmap */
183 /* FT_Set_Charmap */ 240 /* FT_Set_Charmap */
184 /* FT_Get_Charmap_Index */ 241 /* FT_Get_Charmap_Index */
185 /* */ 242 /* */
186 /* FT_FSTYPE_INSTALLABLE_EMBEDDING */ 243 /* FT_Get_FSType_Flags */
187 /* FT_FSTYPE_RESTRICTED_LICENSE_EMBEDDING */ 244 /* FT_Get_SubGlyph_Info */
188 /* FT_FSTYPE_PREVIEW_AND_PRINT_EMBEDDING */
189 /* FT_FSTYPE_EDITABLE_EMBEDDING */
190 /* FT_FSTYPE_NO_SUBSETTING */
191 /* FT_FSTYPE_BITMAP_EMBEDDING_ONLY */
192 /* */ 245 /* */
193 /* FT_Get_FSType_Flags */ 246 /* FT_Face_Internal */
247 /* FT_Size_Internal */
248 /* FT_Slot_Internal */
249 /* */
250 /* FT_FACE_FLAG_XXX */
251 /* FT_STYLE_FLAG_XXX */
252 /* FT_OPEN_XXX */
253 /* FT_LOAD_XXX */
254 /* FT_LOAD_TARGET_XXX */
255 /* FT_SUBGLYPH_FLAG_XXX */
256 /* FT_FSTYPE_XXX */
257 /* */
258 /* FT_HAS_FAST_GLYPHS */
194 /* */ 259 /* */
195 /*************************************************************************/ 260 /*************************************************************************/
196 261
197 262
198 /*************************************************************************/ 263 /*************************************************************************/
199 /* */ 264 /* */
200 /* <Struct> */ 265 /* <Struct> */
201 /* FT_Glyph_Metrics */ 266 /* FT_Glyph_Metrics */
202 /* */ 267 /* */
203 /* <Description> */ 268 /* <Description> */
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
336 /* Library objects are normally created by @FT_Init_FreeType, and */ 401 /* Library objects are normally created by @FT_Init_FreeType, and */
337 /* destroyed with @FT_Done_FreeType. If you need reference-counting */ 402 /* destroyed with @FT_Done_FreeType. If you need reference-counting */
338 /* (cf. @FT_Reference_Library), use @FT_New_Library and */ 403 /* (cf. @FT_Reference_Library), use @FT_New_Library and */
339 /* @FT_Done_Library. */ 404 /* @FT_Done_Library. */
340 /* */ 405 /* */
341 typedef struct FT_LibraryRec_ *FT_Library; 406 typedef struct FT_LibraryRec_ *FT_Library;
342 407
343 408
344 /*************************************************************************/ 409 /*************************************************************************/
345 /* */ 410 /* */
411 /* <Section> */
412 /* module_management */
413 /* */
414 /*************************************************************************/
415
416 /*************************************************************************/
417 /* */
346 /* <Type> */ 418 /* <Type> */
347 /* FT_Module */ 419 /* FT_Module */
348 /* */ 420 /* */
349 /* <Description> */ 421 /* <Description> */
350 /* A handle to a given FreeType module object. Each module can be a */ 422 /* A handle to a given FreeType module object. Each module can be a */
351 /* font driver, a renderer, or anything else that provides services */ 423 /* font driver, a renderer, or anything else that provides services */
352 /* to the formers. */ 424 /* to the formers. */
353 /* */ 425 /* */
354 typedef struct FT_ModuleRec_* FT_Module; 426 typedef struct FT_ModuleRec_* FT_Module;
355 427
(...skipping 19 matching lines...) Expand all
375 /* A handle to a given FreeType renderer. A renderer is a special */ 447 /* A handle to a given FreeType renderer. A renderer is a special */
376 /* module in charge of converting a glyph image to a bitmap, when */ 448 /* module in charge of converting a glyph image to a bitmap, when */
377 /* necessary. Each renderer supports a given glyph image format, and */ 449 /* necessary. Each renderer supports a given glyph image format, and */
378 /* one or more target surface depths. */ 450 /* one or more target surface depths. */
379 /* */ 451 /* */
380 typedef struct FT_RendererRec_* FT_Renderer; 452 typedef struct FT_RendererRec_* FT_Renderer;
381 453
382 454
383 /*************************************************************************/ 455 /*************************************************************************/
384 /* */ 456 /* */
457 /* <Section> */
458 /* base_interface */
459 /* */
460 /*************************************************************************/
461
462 /*************************************************************************/
463 /* */
385 /* <Type> */ 464 /* <Type> */
386 /* FT_Face */ 465 /* FT_Face */
387 /* */ 466 /* */
388 /* <Description> */ 467 /* <Description> */
389 /* A handle to a given typographic face object. A face object models */ 468 /* A handle to a given typographic face object. A face object models */
390 /* a given typeface, in a given style. */ 469 /* a given typeface, in a given style. */
391 /* */ 470 /* */
392 /* <Note> */ 471 /* <Note> */
393 /* Each face object also owns a single @FT_GlyphSlot object, as well */ 472 /* Each face object also owns a single @FT_GlyphSlot object, as well */
394 /* as one or more @FT_Size objects. */ 473 /* as one or more @FT_Size objects. */
(...skipping 15 matching lines...) Expand all
410 /* <Type> */ 489 /* <Type> */
411 /* FT_Size */ 490 /* FT_Size */
412 /* */ 491 /* */
413 /* <Description> */ 492 /* <Description> */
414 /* A handle to an object used to model a face scaled to a given */ 493 /* A handle to an object used to model a face scaled to a given */
415 /* character size. */ 494 /* character size. */
416 /* */ 495 /* */
417 /* <Note> */ 496 /* <Note> */
418 /* Each @FT_Face has an _active_ @FT_Size object that is used by */ 497 /* Each @FT_Face has an _active_ @FT_Size object that is used by */
419 /* functions like @FT_Load_Glyph to determine the scaling */ 498 /* functions like @FT_Load_Glyph to determine the scaling */
420 /* transformation which is used to load and hint glyphs and metrics. */ 499 /* transformation that in turn is used to load and hint glyphs and */
500 /* metrics. */
421 /* */ 501 /* */
422 /* You can use @FT_Set_Char_Size, @FT_Set_Pixel_Sizes, */ 502 /* You can use @FT_Set_Char_Size, @FT_Set_Pixel_Sizes, */
423 /* @FT_Request_Size or even @FT_Select_Size to change the content */ 503 /* @FT_Request_Size or even @FT_Select_Size to change the content */
424 /* (i.e., the scaling values) of the active @FT_Size. */ 504 /* (i.e., the scaling values) of the active @FT_Size. */
425 /* */ 505 /* */
426 /* You can use @FT_New_Size to create additional size objects for a */ 506 /* You can use @FT_New_Size to create additional size objects for a */
427 /* given @FT_Face, but they won't be used by other functions until */ 507 /* given @FT_Face, but they won't be used by other functions until */
428 /* you activate it through @FT_Activate_Size. Only one size can be */ 508 /* you activate it through @FT_Activate_Size. Only one size can be */
429 /* activated at any given time per face. */ 509 /* activated at any given time per face. */
430 /* */ 510 /* */
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
545 /* Latin-1. Most fonts include a Unicode charmap, but not all */ 625 /* Latin-1. Most fonts include a Unicode charmap, but not all */
546 /* of them. */ 626 /* of them. */
547 /* */ 627 /* */
548 /* For example, if you want to access Unicode value U+1F028 (and */ 628 /* For example, if you want to access Unicode value U+1F028 (and */
549 /* the font contains it), use value 0x1F028 as the input value for */ 629 /* the font contains it), use value 0x1F028 as the input value for */
550 /* @FT_Get_Char_Index. */ 630 /* @FT_Get_Char_Index. */
551 /* */ 631 /* */
552 /* FT_ENCODING_MS_SYMBOL :: */ 632 /* FT_ENCODING_MS_SYMBOL :: */
553 /* Corresponds to the Microsoft Symbol encoding, used to encode */ 633 /* Corresponds to the Microsoft Symbol encoding, used to encode */
554 /* mathematical symbols in the 32..255 character code range. For */ 634 /* mathematical symbols in the 32..255 character code range. For */
555 /* more information, see `http://www.ceviz.net/symbol.htm'. */ 635 /* more information, see */
636 /* `http://www.kostis.net/charsets/symbol.htm'. */
556 /* */ 637 /* */
557 /* FT_ENCODING_SJIS :: */ 638 /* FT_ENCODING_SJIS :: */
558 /* Corresponds to Japanese SJIS encoding. More info at */ 639 /* Corresponds to Japanese SJIS encoding. More info at */
559 /* at `http://langsupport.japanreference.com/encoding.shtml'. */ 640 /* at `http://en.wikipedia.org/wiki/Shift_JIS'. */
560 /* See note on multi-byte encodings below. */ 641 /* See note on multi-byte encodings below. */
561 /* */ 642 /* */
562 /* FT_ENCODING_GB2312 :: */ 643 /* FT_ENCODING_GB2312 :: */
563 /* Corresponds to an encoding system for Simplified Chinese as used */ 644 /* Corresponds to an encoding system for Simplified Chinese as used */
564 /* used in mainland China. */ 645 /* used in mainland China. */
565 /* */ 646 /* */
566 /* FT_ENCODING_BIG5 :: */ 647 /* FT_ENCODING_BIG5 :: */
567 /* Corresponds to an encoding system for Traditional Chinese as */ 648 /* Corresponds to an encoding system for Traditional Chinese as */
568 /* used in Taiwan and Hong Kong. */ 649 /* used in Taiwan and Hong Kong. */
569 /* */ 650 /* */
570 /* FT_ENCODING_WANSUNG :: */ 651 /* FT_ENCODING_WANSUNG :: */
571 /* Corresponds to the Korean encoding system known as Wansung. */ 652 /* Corresponds to the Korean encoding system known as Wansung. */
572 /* For more information see */ 653 /* For more information see */
573 /* `http://www.microsoft.com/typography/unicode/949.txt'. */ 654 /* `http://msdn.microsoft.com/en-US/goglobal/cc305154'. */
574 /* */ 655 /* */
575 /* FT_ENCODING_JOHAB :: */ 656 /* FT_ENCODING_JOHAB :: */
576 /* The Korean standard character set (KS~C 5601-1992), which */ 657 /* The Korean standard character set (KS~C 5601-1992), which */
577 /* corresponds to MS Windows code page 1361. This character set */ 658 /* corresponds to MS Windows code page 1361. This character set */
578 /* includes all possible Hangeul character combinations. */ 659 /* includes all possible Hangeul character combinations. */
579 /* */ 660 /* */
580 /* FT_ENCODING_ADOBE_LATIN_1 :: */ 661 /* FT_ENCODING_ADOBE_LATIN_1 :: */
581 /* Corresponds to a Latin-1 encoding as defined in a Type~1 */ 662 /* Corresponds to a Latin-1 encoding as defined in a Type~1 */
582 /* PostScript font. It is limited to 256 character codes. */ 663 /* PostScript font. It is limited to 256 character codes. */
583 /* */ 664 /* */
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
638 /* `charset' field of the @FT_WinFNT_HeaderRec structure to find out */ 719 /* `charset' field of the @FT_WinFNT_HeaderRec structure to find out */
639 /* which encoding is really present. For example, */ 720 /* which encoding is really present. For example, */
640 /* @FT_WinFNT_ID_CP1251 (204) means Windows code page 1251 (for */ 721 /* @FT_WinFNT_ID_CP1251 (204) means Windows code page 1251 (for */
641 /* Russian). */ 722 /* Russian). */
642 /* */ 723 /* */
643 /* FT_ENCODING_NONE is set if `platform_id' is @TT_PLATFORM_MACINTOSH */ 724 /* FT_ENCODING_NONE is set if `platform_id' is @TT_PLATFORM_MACINTOSH */
644 /* and `encoding_id' is not @TT_MAC_ID_ROMAN (otherwise it is set to */ 725 /* and `encoding_id' is not @TT_MAC_ID_ROMAN (otherwise it is set to */
645 /* FT_ENCODING_APPLE_ROMAN). */ 726 /* FT_ENCODING_APPLE_ROMAN). */
646 /* */ 727 /* */
647 /* If `platform_id' is @TT_PLATFORM_MACINTOSH, use the function */ 728 /* If `platform_id' is @TT_PLATFORM_MACINTOSH, use the function */
648 /* @FT_Get_CMap_Language_ID to query the Mac language ID which may */ 729 /* @FT_Get_CMap_Language_ID to query the Mac language ID that may */
649 /* be needed to be able to distinguish Apple encoding variants. See */ 730 /* be needed to be able to distinguish Apple encoding variants. See */
650 /* */ 731 /* */
651 /* http://www.unicode.org/Public/MAPPINGS/VENDORS/APPLE/README.TXT */ 732 /* http://www.unicode.org/Public/MAPPINGS/VENDORS/APPLE/Readme.txt */
652 /* */ 733 /* */
653 /* to get an idea how to do that. Basically, if the language ID */ 734 /* to get an idea how to do that. Basically, if the language ID */
654 /* is~0, don't use it, otherwise subtract 1 from the language ID. */ 735 /* is~0, don't use it, otherwise subtract 1 from the language ID. */
655 /* Then examine `encoding_id'. If, for example, `encoding_id' is */ 736 /* Then examine `encoding_id'. If, for example, `encoding_id' is */
656 /* @TT_MAC_ID_ROMAN and the language ID (minus~1) is */ 737 /* @TT_MAC_ID_ROMAN and the language ID (minus~1) is */
657 /* `TT_MAC_LANGID_GREEK', it is the Greek encoding, not Roman. */ 738 /* `TT_MAC_LANGID_GREEK', it is the Greek encoding, not Roman. */
658 /* @TT_MAC_ID_ARABIC with `TT_MAC_LANGID_FARSI' means the Farsi */ 739 /* @TT_MAC_ID_ARABIC with `TT_MAC_LANGID_FARSI' means the Farsi */
659 /* variant the Arabic encoding. */ 740 /* variant the Arabic encoding. */
660 /* */ 741 /* */
661 typedef enum FT_Encoding_ 742 typedef enum FT_Encoding_
(...skipping 21 matching lines...) Expand all
683 FT_ENC_TAG( FT_ENCODING_ADOBE_CUSTOM, 'A', 'D', 'B', 'C' ), 764 FT_ENC_TAG( FT_ENCODING_ADOBE_CUSTOM, 'A', 'D', 'B', 'C' ),
684 FT_ENC_TAG( FT_ENCODING_ADOBE_LATIN_1, 'l', 'a', 't', '1' ), 765 FT_ENC_TAG( FT_ENCODING_ADOBE_LATIN_1, 'l', 'a', 't', '1' ),
685 766
686 FT_ENC_TAG( FT_ENCODING_OLD_LATIN_2, 'l', 'a', 't', '2' ), 767 FT_ENC_TAG( FT_ENCODING_OLD_LATIN_2, 'l', 'a', 't', '2' ),
687 768
688 FT_ENC_TAG( FT_ENCODING_APPLE_ROMAN, 'a', 'r', 'm', 'n' ) 769 FT_ENC_TAG( FT_ENCODING_APPLE_ROMAN, 'a', 'r', 'm', 'n' )
689 770
690 } FT_Encoding; 771 } FT_Encoding;
691 772
692 773
693 /*************************************************************************/ 774 /* these constants are deprecated; use the corresponding `FT_Encoding' */
694 /* */ 775 /* values instead */
695 /* <Enum> */
696 /* ft_encoding_xxx */
697 /* */
698 /* <Description> */
699 /* These constants are deprecated; use the corresponding @FT_Encoding */
700 /* values instead. */
701 /* */
702 #define ft_encoding_none FT_ENCODING_NONE 776 #define ft_encoding_none FT_ENCODING_NONE
703 #define ft_encoding_unicode FT_ENCODING_UNICODE 777 #define ft_encoding_unicode FT_ENCODING_UNICODE
704 #define ft_encoding_symbol FT_ENCODING_MS_SYMBOL 778 #define ft_encoding_symbol FT_ENCODING_MS_SYMBOL
705 #define ft_encoding_latin_1 FT_ENCODING_ADOBE_LATIN_1 779 #define ft_encoding_latin_1 FT_ENCODING_ADOBE_LATIN_1
706 #define ft_encoding_latin_2 FT_ENCODING_OLD_LATIN_2 780 #define ft_encoding_latin_2 FT_ENCODING_OLD_LATIN_2
707 #define ft_encoding_sjis FT_ENCODING_SJIS 781 #define ft_encoding_sjis FT_ENCODING_SJIS
708 #define ft_encoding_gb2312 FT_ENCODING_GB2312 782 #define ft_encoding_gb2312 FT_ENCODING_GB2312
709 #define ft_encoding_big5 FT_ENCODING_BIG5 783 #define ft_encoding_big5 FT_ENCODING_BIG5
710 #define ft_encoding_wansung FT_ENCODING_WANSUNG 784 #define ft_encoding_wansung FT_ENCODING_WANSUNG
711 #define ft_encoding_johab FT_ENCODING_JOHAB 785 #define ft_encoding_johab FT_ENCODING_JOHAB
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
801 /* */ 875 /* */
802 /* num_glyphs :: The number of glyphs in the face. If the */ 876 /* num_glyphs :: The number of glyphs in the face. If the */
803 /* face is scalable and has sbits (see */ 877 /* face is scalable and has sbits (see */
804 /* `num_fixed_sizes'), it is set to the number */ 878 /* `num_fixed_sizes'), it is set to the number */
805 /* of outline glyphs. */ 879 /* of outline glyphs. */
806 /* */ 880 /* */
807 /* For CID-keyed fonts, this value gives the */ 881 /* For CID-keyed fonts, this value gives the */
808 /* highest CID used in the font. */ 882 /* highest CID used in the font. */
809 /* */ 883 /* */
810 /* family_name :: The face's family name. This is an ASCII */ 884 /* family_name :: The face's family name. This is an ASCII */
811 /* string, usually in English, which describes */ 885 /* string, usually in English, that describes */
812 /* the typeface's family (like `Times New */ 886 /* the typeface's family (like `Times New */
813 /* Roman', `Bodoni', `Garamond', etc). This */ 887 /* Roman', `Bodoni', `Garamond', etc). This */
814 /* is a least common denominator used to list */ 888 /* is a least common denominator used to list */
815 /* fonts. Some formats (TrueType & OpenType) */ 889 /* fonts. Some formats (TrueType & OpenType) */
816 /* provide localized and Unicode versions of */ 890 /* provide localized and Unicode versions of */
817 /* this string. Applications should use the */ 891 /* this string. Applications should use the */
818 /* format specific interface to access them. */ 892 /* format specific interface to access them. */
819 /* Can be NULL (e.g., in fonts embedded in a */ 893 /* Can be NULL (e.g., in fonts embedded in a */
820 /* PDF file). */ 894 /* PDF file). */
821 /* */ 895 /* */
822 /* style_name :: The face's style name. This is an ASCII */ 896 /* style_name :: The face's style name. This is an ASCII */
823 /* string, usually in English, which describes */ 897 /* string, usually in English, that describes */
824 /* the typeface's style (like `Italic', */ 898 /* the typeface's style (like `Italic', */
825 /* `Bold', `Condensed', etc). Not all font */ 899 /* `Bold', `Condensed', etc). Not all font */
826 /* formats provide a style name, so this field */ 900 /* formats provide a style name, so this field */
827 /* is optional, and can be set to NULL. As */ 901 /* is optional, and can be set to NULL. As */
828 /* for `family_name', some formats provide */ 902 /* for `family_name', some formats provide */
829 /* localized and Unicode versions of this */ 903 /* localized and Unicode versions of this */
830 /* string. Applications should use the format */ 904 /* string. Applications should use the format */
831 /* specific interface to access them. */ 905 /* specific interface to access them. */
832 /* */ 906 /* */
833 /* num_fixed_sizes :: The number of bitmap strikes in the face. */ 907 /* num_fixed_sizes :: The number of bitmap strikes in the face. */
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
930 1004
931 FT_String* family_name; 1005 FT_String* family_name;
932 FT_String* style_name; 1006 FT_String* style_name;
933 1007
934 FT_Int num_fixed_sizes; 1008 FT_Int num_fixed_sizes;
935 FT_Bitmap_Size* available_sizes; 1009 FT_Bitmap_Size* available_sizes;
936 1010
937 FT_Int num_charmaps; 1011 FT_Int num_charmaps;
938 FT_CharMap* charmaps; 1012 FT_CharMap* charmaps;
939 1013
940 #ifdef _FX_MANAGED_CODE_
941 #define generic generic_data
942 #endif
943
944 FT_Generic generic; 1014 FT_Generic generic;
945 1015
946 /*# The following member variables (down to `underline_thickness') */ 1016 /*# The following member variables (down to `underline_thickness') */
947 /*# are only relevant to scalable outlines; cf. @FT_Bitmap_Size */ 1017 /*# are only relevant to scalable outlines; cf. @FT_Bitmap_Size */
948 /*# for bitmap fonts. */ 1018 /*# for bitmap fonts. */
949 FT_BBox bbox; 1019 FT_BBox bbox;
950 1020
951 FT_UShort units_per_EM; 1021 FT_UShort units_per_EM;
952 FT_Short ascender; 1022 FT_Short ascender;
953 FT_Short descender; 1023 FT_Short descender;
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
1051 /* */ 1121 /* */
1052 /* FT_FACE_FLAG_CID_KEYED :: */ 1122 /* FT_FACE_FLAG_CID_KEYED :: */
1053 /* Set if the font is CID-keyed. In that case, the font is not */ 1123 /* Set if the font is CID-keyed. In that case, the font is not */
1054 /* accessed by glyph indices but by CID values. For subsetted */ 1124 /* accessed by glyph indices but by CID values. For subsetted */
1055 /* CID-keyed fonts this has the consequence that not all index */ 1125 /* CID-keyed fonts this has the consequence that not all index */
1056 /* values are a valid argument to FT_Load_Glyph. Only the CID */ 1126 /* values are a valid argument to FT_Load_Glyph. Only the CID */
1057 /* values for which corresponding glyphs in the subsetted font */ 1127 /* values for which corresponding glyphs in the subsetted font */
1058 /* exist make FT_Load_Glyph return successfully; in all other cases */ 1128 /* exist make FT_Load_Glyph return successfully; in all other cases */
1059 /* you get an `FT_Err_Invalid_Argument' error. */ 1129 /* you get an `FT_Err_Invalid_Argument' error. */
1060 /* */ 1130 /* */
1061 /* Note that CID-keyed fonts which are in an SFNT wrapper don't */ 1131 /* Note that CID-keyed fonts that are in an SFNT wrapper don't */
1062 /* have this flag set since the glyphs are accessed in the normal */ 1132 /* have this flag set since the glyphs are accessed in the normal */
1063 /* way (using contiguous indices); the `CID-ness' isn't visible to */ 1133 /* way (using contiguous indices); the `CID-ness' isn't visible to */
1064 /* the application. */ 1134 /* the application. */
1065 /* */ 1135 /* */
1066 /* FT_FACE_FLAG_TRICKY :: */ 1136 /* FT_FACE_FLAG_TRICKY :: */
1067 /* Set if the font is `tricky', this is, it always needs the */ 1137 /* Set if the font is `tricky', this is, it always needs the */
1068 /* font format's native hinting engine to get a reasonable result. */ 1138 /* font format's native hinting engine to get a reasonable result. */
1069 /* A typical example is the Chinese font `mingli.ttf' which uses */ 1139 /* A typical example is the Chinese font `mingli.ttf' that uses */
1070 /* TrueType bytecode instructions to move and scale all of its */ 1140 /* TrueType bytecode instructions to move and scale all of its */
1071 /* subglyphs. */ 1141 /* subglyphs. */
1072 /* */ 1142 /* */
1073 /* It is not possible to autohint such fonts using */ 1143 /* It is not possible to autohint such fonts using */
1074 /* @FT_LOAD_FORCE_AUTOHINT; it will also ignore */ 1144 /* @FT_LOAD_FORCE_AUTOHINT; it will also ignore */
1075 /* @FT_LOAD_NO_HINTING. You have to set both @FT_LOAD_NO_HINTING */ 1145 /* @FT_LOAD_NO_HINTING. You have to set both @FT_LOAD_NO_HINTING */
1076 /* and @FT_LOAD_NO_AUTOHINT to really disable hinting; however, you */ 1146 /* and @FT_LOAD_NO_AUTOHINT to really disable hinting; however, you */
1077 /* probably never want this except for demonstration purposes. */ 1147 /* probably never want this except for demonstration purposes. */
1078 /* */ 1148 /* */
1079 /* Currently, there are about a dozen TrueType fonts in the list of */ 1149 /* Currently, there are about a dozen TrueType fonts in the list of */
1080 /* tricky fonts; they are hard-coded in file `ttobjs.c'. */ 1150 /* tricky fonts; they are hard-coded in file `ttobjs.c'. */
1081 /* */ 1151 /* */
1152 /* FT_FACE_FLAG_COLOR :: */
1153 /* Set if the font has color glyph tables. To access color glyphs */
1154 /* use @FT_LOAD_COLOR. */
1155 /* */
1082 #define FT_FACE_FLAG_SCALABLE ( 1L << 0 ) 1156 #define FT_FACE_FLAG_SCALABLE ( 1L << 0 )
1083 #define FT_FACE_FLAG_FIXED_SIZES ( 1L << 1 ) 1157 #define FT_FACE_FLAG_FIXED_SIZES ( 1L << 1 )
1084 #define FT_FACE_FLAG_FIXED_WIDTH ( 1L << 2 ) 1158 #define FT_FACE_FLAG_FIXED_WIDTH ( 1L << 2 )
1085 #define FT_FACE_FLAG_SFNT ( 1L << 3 ) 1159 #define FT_FACE_FLAG_SFNT ( 1L << 3 )
1086 #define FT_FACE_FLAG_HORIZONTAL ( 1L << 4 ) 1160 #define FT_FACE_FLAG_HORIZONTAL ( 1L << 4 )
1087 #define FT_FACE_FLAG_VERTICAL ( 1L << 5 ) 1161 #define FT_FACE_FLAG_VERTICAL ( 1L << 5 )
1088 #define FT_FACE_FLAG_KERNING ( 1L << 6 ) 1162 #define FT_FACE_FLAG_KERNING ( 1L << 6 )
1089 #define FT_FACE_FLAG_FAST_GLYPHS ( 1L << 7 ) 1163 #define FT_FACE_FLAG_FAST_GLYPHS ( 1L << 7 )
1090 #define FT_FACE_FLAG_MULTIPLE_MASTERS ( 1L << 8 ) 1164 #define FT_FACE_FLAG_MULTIPLE_MASTERS ( 1L << 8 )
1091 #define FT_FACE_FLAG_GLYPH_NAMES ( 1L << 9 ) 1165 #define FT_FACE_FLAG_GLYPH_NAMES ( 1L << 9 )
1092 #define FT_FACE_FLAG_EXTERNAL_STREAM ( 1L << 10 ) 1166 #define FT_FACE_FLAG_EXTERNAL_STREAM ( 1L << 10 )
1093 #define FT_FACE_FLAG_HINTER ( 1L << 11 ) 1167 #define FT_FACE_FLAG_HINTER ( 1L << 11 )
1094 #define FT_FACE_FLAG_CID_KEYED ( 1L << 12 ) 1168 #define FT_FACE_FLAG_CID_KEYED ( 1L << 12 )
1095 #define FT_FACE_FLAG_TRICKY ( 1L << 13 ) 1169 #define FT_FACE_FLAG_TRICKY ( 1L << 13 )
1170 #define FT_FACE_FLAG_COLOR ( 1L << 14 )
1096 1171
1097 1172
1098 /************************************************************************* 1173 /*************************************************************************
1099 * 1174 *
1100 * @macro: 1175 * @macro:
1101 * FT_HAS_HORIZONTAL( face ) 1176 * FT_HAS_HORIZONTAL( face )
1102 * 1177 *
1103 * @description: 1178 * @description:
1104 * A macro that returns true whenever a face object contains 1179 * A macro that returns true whenever a face object contains
1105 * horizontal metrics (this is true for all font formats though). 1180 * horizontal metrics (this is true for all font formats though).
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
1270 * 1345 *
1271 * @description: 1346 * @description:
1272 * A macro that returns true whenever a face represents a `tricky' font. 1347 * A macro that returns true whenever a face represents a `tricky' font.
1273 * See the discussion of @FT_FACE_FLAG_TRICKY for more details. 1348 * See the discussion of @FT_FACE_FLAG_TRICKY for more details.
1274 * 1349 *
1275 */ 1350 */
1276 #define FT_IS_TRICKY( face ) \ 1351 #define FT_IS_TRICKY( face ) \
1277 ( face->face_flags & FT_FACE_FLAG_TRICKY ) 1352 ( face->face_flags & FT_FACE_FLAG_TRICKY )
1278 1353
1279 1354
1355 /*************************************************************************
1356 *
1357 * @macro:
1358 * FT_HAS_COLOR( face )
1359 *
1360 * @description:
1361 * A macro that returns true whenever a face object contains
1362 * tables for color glyphs.
1363 *
1364 */
1365 #define FT_HAS_COLOR( face ) \
1366 ( face->face_flags & FT_FACE_FLAG_COLOR )
1367
1368
1280 /*************************************************************************/ 1369 /*************************************************************************/
1281 /* */ 1370 /* */
1282 /* <Const> */ 1371 /* <Const> */
1283 /* FT_STYLE_FLAG_XXX */ 1372 /* FT_STYLE_FLAG_XXX */
1284 /* */ 1373 /* */
1285 /* <Description> */ 1374 /* <Description> */
1286 /* A list of bit-flags used to indicate the style of a given face. */ 1375 /* A list of bit-flags used to indicate the style of a given face. */
1287 /* These are used in the `style_flags' field of @FT_FaceRec. */ 1376 /* These are used in the `style_flags' field of @FT_FaceRec. */
1288 /* */ 1377 /* */
1289 /* <Values> */ 1378 /* <Values> */
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
1391 /* <Struct> */ 1480 /* <Struct> */
1392 /* FT_SizeRec */ 1481 /* FT_SizeRec */
1393 /* */ 1482 /* */
1394 /* <Description> */ 1483 /* <Description> */
1395 /* FreeType root size class structure. A size object models a face */ 1484 /* FreeType root size class structure. A size object models a face */
1396 /* object at a given size. */ 1485 /* object at a given size. */
1397 /* */ 1486 /* */
1398 /* <Fields> */ 1487 /* <Fields> */
1399 /* face :: Handle to the parent face object. */ 1488 /* face :: Handle to the parent face object. */
1400 /* */ 1489 /* */
1401 /* generic :: A typeless pointer, which is unused by the FreeType */ 1490 /* generic :: A typeless pointer, unused by the FreeType library or */
1402 /* library or any of its drivers. It can be used by */ 1491 /* any of its drivers. It can be used by client */
1403 /* client applications to link their own data to each size */ 1492 /* applications to link their own data to each size */
1404 /* object. */ 1493 /* object. */
1405 /* */ 1494 /* */
1406 /* metrics :: Metrics for this size object. This field is read-only. */ 1495 /* metrics :: Metrics for this size object. This field is read-only. */
1407 /* */ 1496 /* */
1408 typedef struct FT_SizeRec_ 1497 typedef struct FT_SizeRec_
1409 { 1498 {
1410 FT_Face face; /* parent face object */ 1499 FT_Face face; /* parent face object */
1411 FT_Generic generic; /* generic pointer for client uses */ 1500 FT_Generic generic; /* generic pointer for client uses */
1412 FT_Size_Metrics metrics; /* size metrics */ 1501 FT_Size_Metrics metrics; /* size metrics */
1413 FT_Size_Internal internal; 1502 FT_Size_Internal internal;
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
1461 /* this slot belongs to. */ 1550 /* this slot belongs to. */
1462 /* */ 1551 /* */
1463 /* face :: A handle to the parent face object. */ 1552 /* face :: A handle to the parent face object. */
1464 /* */ 1553 /* */
1465 /* next :: In some cases (like some font tools), several */ 1554 /* next :: In some cases (like some font tools), several */
1466 /* glyph slots per face object can be a good */ 1555 /* glyph slots per face object can be a good */
1467 /* thing. As this is rare, the glyph slots are */ 1556 /* thing. As this is rare, the glyph slots are */
1468 /* listed through a direct, single-linked list */ 1557 /* listed through a direct, single-linked list */
1469 /* using its `next' field. */ 1558 /* using its `next' field. */
1470 /* */ 1559 /* */
1471 /* generic :: A typeless pointer which is unused by the */ 1560 /* generic :: A typeless pointer unused by the FreeType */
1472 /* FreeType library or any of its drivers. It */ 1561 /* library or any of its drivers. It can be */
1473 /* can be used by client applications to link */ 1562 /* used by client applications to link their own */
1474 /* their own data to each glyph slot object. */ 1563 /* data to each glyph slot object. */
1475 /* */ 1564 /* */
1476 /* metrics :: The metrics of the last loaded glyph in the */ 1565 /* metrics :: The metrics of the last loaded glyph in the */
1477 /* slot. The returned values depend on the last */ 1566 /* slot. The returned values depend on the last */
1478 /* load flags (see the @FT_Load_Glyph API */ 1567 /* load flags (see the @FT_Load_Glyph API */
1479 /* function) and can be expressed either in 26.6 */ 1568 /* function) and can be expressed either in 26.6 */
1480 /* fractional pixels or font units. */ 1569 /* fractional pixels or font units. */
1481 /* */ 1570 /* */
1482 /* Note that even when the glyph image is */ 1571 /* Note that even when the glyph image is */
1483 /* transformed, the metrics are not. */ 1572 /* transformed, the metrics are not. */
1484 /* */ 1573 /* */
1485 /* linearHoriAdvance :: The advance width of the unhinted glyph. */ 1574 /* linearHoriAdvance :: The advance width of the unhinted glyph. */
1486 /* Its value is expressed in 16.16 fractional */ 1575 /* Its value is expressed in 16.16 fractional */
1487 /* pixels, unless @FT_LOAD_LINEAR_DESIGN is set */ 1576 /* pixels, unless @FT_LOAD_LINEAR_DESIGN is set */
1488 /* when loading the glyph. This field can be */ 1577 /* when loading the glyph. This field can be */
1489 /* important to perform correct WYSIWYG layout. */ 1578 /* important to perform correct WYSIWYG layout. */
1490 /* Only relevant for outline glyphs. */ 1579 /* Only relevant for outline glyphs. */
1491 /* */ 1580 /* */
1492 /* linearVertAdvance :: The advance height of the unhinted glyph. */ 1581 /* linearVertAdvance :: The advance height of the unhinted glyph. */
1493 /* Its value is expressed in 16.16 fractional */ 1582 /* Its value is expressed in 16.16 fractional */
1494 /* pixels, unless @FT_LOAD_LINEAR_DESIGN is set */ 1583 /* pixels, unless @FT_LOAD_LINEAR_DESIGN is set */
1495 /* when loading the glyph. This field can be */ 1584 /* when loading the glyph. This field can be */
1496 /* important to perform correct WYSIWYG layout. */ 1585 /* important to perform correct WYSIWYG layout. */
1497 /* Only relevant for outline glyphs. */ 1586 /* Only relevant for outline glyphs. */
1498 /* */ 1587 /* */
1499 /* advance :: This shorthand is, depending on */ 1588 /* advance :: This shorthand is, depending on */
1500 /* @FT_LOAD_IGNORE_TRANSFORM, the transformed */ 1589 /* @FT_LOAD_IGNORE_TRANSFORM, the transformed */
1501 /* advance width for the glyph (in 26.6 */ 1590 /* (hinted) advance width for the glyph, in 26.6 */
1502 /* fractional pixel format). As specified with */ 1591 /* fractional pixel format. As specified with */
1503 /* @FT_LOAD_VERTICAL_LAYOUT, it uses either the */ 1592 /* @FT_LOAD_VERTICAL_LAYOUT, it uses either the */
1504 /* `horiAdvance' or the `vertAdvance' value of */ 1593 /* `horiAdvance' or the `vertAdvance' value of */
1505 /* `metrics' field. */ 1594 /* `metrics' field. */
1506 /* */ 1595 /* */
1507 /* format :: This field indicates the format of the image */ 1596 /* format :: This field indicates the format of the image */
1508 /* contained in the glyph slot. Typically */ 1597 /* contained in the glyph slot. Typically */
1509 /* @FT_GLYPH_FORMAT_BITMAP, */ 1598 /* @FT_GLYPH_FORMAT_BITMAP, */
1510 /* @FT_GLYPH_FORMAT_OUTLINE, or */ 1599 /* @FT_GLYPH_FORMAT_OUTLINE, or */
1511 /* @FT_GLYPH_FORMAT_COMPOSITE, but others are */ 1600 /* @FT_GLYPH_FORMAT_COMPOSITE, but others are */
1512 /* possible. */ 1601 /* possible. */
1513 /* */ 1602 /* */
1514 /* bitmap :: This field is used as a bitmap descriptor */ 1603 /* bitmap :: This field is used as a bitmap descriptor */
1515 /* when the slot format is */ 1604 /* when the slot format is */
1516 /* @FT_GLYPH_FORMAT_BITMAP. Note that the */ 1605 /* @FT_GLYPH_FORMAT_BITMAP. Note that the */
1517 /* address and content of the bitmap buffer can */ 1606 /* address and content of the bitmap buffer can */
1518 /* change between calls of @FT_Load_Glyph and a */ 1607 /* change between calls of @FT_Load_Glyph and a */
1519 /* few other functions. */ 1608 /* few other functions. */
1520 /* */ 1609 /* */
1521 /* bitmap_left :: This is the bitmap's left bearing expressed */ 1610 /* bitmap_left :: The bitmap's left bearing expressed in */
1522 /* in integer pixels. Of course, this is only */ 1611 /* integer pixels. Only valid if the format is */
1523 /* valid if the format is */ 1612 /* @FT_GLYPH_FORMAT_BITMAP, this is, if the */
1524 /* @FT_GLYPH_FORMAT_BITMAP. */ 1613 /* glyph slot contains a bitmap. */
1525 /* */ 1614 /* */
1526 /* bitmap_top :: This is the bitmap's top bearing expressed in */ 1615 /* bitmap_top :: The bitmap's top bearing expressed in integer */
1527 /* integer pixels. Remember that this is the */ 1616 /* pixels. Remember that this is the distance */
1528 /* distance from the baseline to the top-most */ 1617 /* from the baseline to the top-most glyph */
1529 /* glyph scanline, upwards y~coordinates being */ 1618 /* scanline, upwards y~coordinates being */
1530 /* *positive*. */ 1619 /* *positive*. */
1531 /* */ 1620 /* */
1532 /* outline :: The outline descriptor for the current glyph */ 1621 /* outline :: The outline descriptor for the current glyph */
1533 /* image if its format is */ 1622 /* image if its format is */
1534 /* @FT_GLYPH_FORMAT_OUTLINE. Once a glyph is */ 1623 /* @FT_GLYPH_FORMAT_OUTLINE. Once a glyph is */
1535 /* loaded, `outline' can be transformed, */ 1624 /* loaded, `outline' can be transformed, */
1536 /* distorted, embolded, etc. However, it must */ 1625 /* distorted, embolded, etc. However, it must */
1537 /* not be freed. */ 1626 /* not be freed. */
1538 /* */ 1627 /* */
1539 /* num_subglyphs :: The number of subglyphs in a composite glyph. */ 1628 /* num_subglyphs :: The number of subglyphs in a composite glyph. */
1540 /* This field is only valid for the composite */ 1629 /* This field is only valid for the composite */
1541 /* glyph format that should normally only be */ 1630 /* glyph format that should normally only be */
1542 /* loaded with the @FT_LOAD_NO_RECURSE flag. */ 1631 /* loaded with the @FT_LOAD_NO_RECURSE flag. */
1543 /* For now this is internal to FreeType. */
1544 /* */ 1632 /* */
1545 /* subglyphs :: An array of subglyph descriptors for */ 1633 /* subglyphs :: An array of subglyph descriptors for */
1546 /* composite glyphs. There are `num_subglyphs' */ 1634 /* composite glyphs. There are `num_subglyphs' */
1547 /* elements in there. Currently internal to */ 1635 /* elements in there. Currently internal to */
1548 /* FreeType. */ 1636 /* FreeType. */
1549 /* */ 1637 /* */
1550 /* control_data :: Certain font drivers can also return the */ 1638 /* control_data :: Certain font drivers can also return the */
1551 /* control data for a given glyph image (e.g. */ 1639 /* control data for a given glyph image (e.g. */
1552 /* TrueType bytecode, Type~1 charstrings, etc.). */ 1640 /* TrueType bytecode, Type~1 charstrings, etc.). */
1553 /* This field is a pointer to such data. */ 1641 /* This field is a pointer to such data. */
(...skipping 27 matching lines...) Expand all
1581 /* The renderer is in charge of transforming the native image through */ 1669 /* The renderer is in charge of transforming the native image through */
1582 /* the slot's face transformation fields, then converting it into a */ 1670 /* the slot's face transformation fields, then converting it into a */
1583 /* bitmap that is returned in `slot->bitmap'. */ 1671 /* bitmap that is returned in `slot->bitmap'. */
1584 /* */ 1672 /* */
1585 /* Note that `slot->bitmap_left' and `slot->bitmap_top' are also used */ 1673 /* Note that `slot->bitmap_left' and `slot->bitmap_top' are also used */
1586 /* to specify the position of the bitmap relative to the current pen */ 1674 /* to specify the position of the bitmap relative to the current pen */
1587 /* position (e.g., coordinates (0,0) on the baseline). Of course, */ 1675 /* position (e.g., coordinates (0,0) on the baseline). Of course, */
1588 /* `slot->format' is also changed to @FT_GLYPH_FORMAT_BITMAP. */ 1676 /* `slot->format' is also changed to @FT_GLYPH_FORMAT_BITMAP. */
1589 /* */ 1677 /* */
1590 /* <Note> */ 1678 /* <Note> */
1591 /* Here a small pseudo code fragment which shows how to use */ 1679 /* Here a small pseudo code fragment that shows how to use */
1592 /* `lsb_delta' and `rsb_delta': */ 1680 /* `lsb_delta' and `rsb_delta': */
1593 /* */ 1681 /* */
1594 /* { */ 1682 /* { */
1595 /* FT_Pos origin_x = 0; */ 1683 /* FT_Pos origin_x = 0; */
1596 /* FT_Pos prev_rsb_delta = 0; */ 1684 /* FT_Pos prev_rsb_delta = 0; */
1597 /* */ 1685 /* */
1598 /* */ 1686 /* */
1599 /* for all glyphs do */ 1687 /* for all glyphs do */
1600 /* <compute kern between current and previous glyph and add it to */ 1688 /* <compute kern between current and previous glyph and add it to */
1601 /* `origin_x'> */ 1689 /* `origin_x'> */
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
1724 /* */ 1812 /* */
1725 /* FT_OPEN_STREAM :: Copy the stream from the `stream' field. */ 1813 /* FT_OPEN_STREAM :: Copy the stream from the `stream' field. */
1726 /* */ 1814 /* */
1727 /* FT_OPEN_PATHNAME :: Create a new input stream from a C~path */ 1815 /* FT_OPEN_PATHNAME :: Create a new input stream from a C~path */
1728 /* name. */ 1816 /* name. */
1729 /* */ 1817 /* */
1730 /* FT_OPEN_DRIVER :: Use the `driver' field. */ 1818 /* FT_OPEN_DRIVER :: Use the `driver' field. */
1731 /* */ 1819 /* */
1732 /* FT_OPEN_PARAMS :: Use the `num_params' and `params' fields. */ 1820 /* FT_OPEN_PARAMS :: Use the `num_params' and `params' fields. */
1733 /* */ 1821 /* */
1734 /* ft_open_memory :: Deprecated; use @FT_OPEN_MEMORY instead. */
1735 /* */
1736 /* ft_open_stream :: Deprecated; use @FT_OPEN_STREAM instead. */
1737 /* */
1738 /* ft_open_pathname :: Deprecated; use @FT_OPEN_PATHNAME instead. */
1739 /* */
1740 /* ft_open_driver :: Deprecated; use @FT_OPEN_DRIVER instead. */
1741 /* */
1742 /* ft_open_params :: Deprecated; use @FT_OPEN_PARAMS instead. */
1743 /* */
1744 /* <Note> */ 1822 /* <Note> */
1745 /* The `FT_OPEN_MEMORY', `FT_OPEN_STREAM', and `FT_OPEN_PATHNAME' */ 1823 /* The `FT_OPEN_MEMORY', `FT_OPEN_STREAM', and `FT_OPEN_PATHNAME' */
1746 /* flags are mutually exclusive. */ 1824 /* flags are mutually exclusive. */
1747 /* */ 1825 /* */
1748 #define FT_OPEN_MEMORY 0x1 1826 #define FT_OPEN_MEMORY 0x1
1749 #define FT_OPEN_STREAM 0x2 1827 #define FT_OPEN_STREAM 0x2
1750 #define FT_OPEN_PATHNAME 0x4 1828 #define FT_OPEN_PATHNAME 0x4
1751 #define FT_OPEN_DRIVER 0x8 1829 #define FT_OPEN_DRIVER 0x8
1752 #define FT_OPEN_PARAMS 0x10 1830 #define FT_OPEN_PARAMS 0x10
1753 1831
1754 #define ft_open_memory FT_OPEN_MEMORY /* deprecated */ 1832
1755 #define ft_open_stream FT_OPEN_STREAM /* deprecated */ 1833 /* these constants are deprecated; use the corresponding `FT_OPEN_XXX' */
1756 #define ft_open_pathname FT_OPEN_PATHNAME /* deprecated */ 1834 /* values instead */
1757 #define ft_open_driver FT_OPEN_DRIVER /* deprecated */ 1835 #define ft_open_memory FT_OPEN_MEMORY
1758 #define ft_open_params FT_OPEN_PARAMS /* deprecated */ 1836 #define ft_open_stream FT_OPEN_STREAM
1837 #define ft_open_pathname FT_OPEN_PATHNAME
1838 #define ft_open_driver FT_OPEN_DRIVER
1839 #define ft_open_params FT_OPEN_PARAMS
1759 1840
1760 1841
1761 /*************************************************************************/ 1842 /*************************************************************************/
1762 /* */ 1843 /* */
1763 /* <Struct> */ 1844 /* <Struct> */
1764 /* FT_Parameter */ 1845 /* FT_Parameter */
1765 /* */ 1846 /* */
1766 /* <Description> */ 1847 /* <Description> */
1767 /* A simple structure used to pass more or less generic parameters to */ 1848 /* A simple structure used to pass more or less generic parameters to */
1768 /* @FT_Open_Face. */ 1849 /* @FT_Open_Face. */
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
1810 /* it simply specifies the font driver to use to open */ 1891 /* it simply specifies the font driver to use to open */
1811 /* the face. If set to~0, FreeType tries to load the */ 1892 /* the face. If set to~0, FreeType tries to load the */
1812 /* face with each one of the drivers in its list. */ 1893 /* face with each one of the drivers in its list. */
1813 /* */ 1894 /* */
1814 /* num_params :: The number of extra parameters. */ 1895 /* num_params :: The number of extra parameters. */
1815 /* */ 1896 /* */
1816 /* params :: Extra parameters passed to the font driver when */ 1897 /* params :: Extra parameters passed to the font driver when */
1817 /* opening a new face. */ 1898 /* opening a new face. */
1818 /* */ 1899 /* */
1819 /* <Note> */ 1900 /* <Note> */
1820 /* The stream type is determined by the contents of `flags' which */ 1901 /* The stream type is determined by the contents of `flags' that */
1821 /* are tested in the following order by @FT_Open_Face: */ 1902 /* are tested in the following order by @FT_Open_Face: */
1822 /* */ 1903 /* */
1823 /* If the `FT_OPEN_MEMORY' bit is set, assume that this is a */ 1904 /* If the @FT_OPEN_MEMORY bit is set, assume that this is a */
1824 /* memory file of `memory_size' bytes, located at `memory_address'. */ 1905 /* memory file of `memory_size' bytes, located at `memory_address'. */
1825 /* The data are are not copied, and the client is responsible for */ 1906 /* The data are are not copied, and the client is responsible for */
1826 /* releasing and destroying them _after_ the corresponding call to */ 1907 /* releasing and destroying them _after_ the corresponding call to */
1827 /* @FT_Done_Face. */ 1908 /* @FT_Done_Face. */
1828 /* */ 1909 /* */
1829 /* Otherwise, if the `FT_OPEN_STREAM' bit is set, assume that a */ 1910 /* Otherwise, if the @FT_OPEN_STREAM bit is set, assume that a */
1830 /* custom input stream `stream' is used. */ 1911 /* custom input stream `stream' is used. */
1831 /* */ 1912 /* */
1832 /* Otherwise, if the `FT_OPEN_PATHNAME' bit is set, assume that this */ 1913 /* Otherwise, if the @FT_OPEN_PATHNAME bit is set, assume that this */
1833 /* is a normal file and use `pathname' to open it. */ 1914 /* is a normal file and use `pathname' to open it. */
1834 /* */ 1915 /* */
1835 /* If the `FT_OPEN_DRIVER' bit is set, @FT_Open_Face only tries to */ 1916 /* If the @FT_OPEN_DRIVER bit is set, @FT_Open_Face only tries to */
1836 /* open the file with the driver whose handler is in `driver'. */ 1917 /* open the file with the driver whose handler is in `driver'. */
1837 /* */ 1918 /* */
1838 /* If the `FT_OPEN_PARAMS' bit is set, the parameters given by */ 1919 /* If the @FT_OPEN_PARAMS bit is set, the parameters given by */
1839 /* `num_params' and `params' is used. They are ignored otherwise. */ 1920 /* `num_params' and `params' is used. They are ignored otherwise. */
1840 /* */ 1921 /* */
1841 /* Ideally, both the `pathname' and `params' fields should be tagged */ 1922 /* Ideally, both the `pathname' and `params' fields should be tagged */
1842 /* as `const'; this is missing for API backwards compatibility. In */ 1923 /* as `const'; this is missing for API backwards compatibility. In */
1843 /* other words, applications should treat them as read-only. */ 1924 /* other words, applications should treat them as read-only. */
1844 /* */ 1925 /* */
1845 typedef struct FT_Open_Args_ 1926 typedef struct FT_Open_Args_
1846 { 1927 {
1847 FT_UInt flags; 1928 FT_UInt flags;
1848 const FT_Byte* memory_base; 1929 const FT_Byte* memory_base;
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
1891 FT_Long face_index, 1972 FT_Long face_index,
1892 FT_Face *aface ); 1973 FT_Face *aface );
1893 1974
1894 1975
1895 /*************************************************************************/ 1976 /*************************************************************************/
1896 /* */ 1977 /* */
1897 /* <Function> */ 1978 /* <Function> */
1898 /* FT_New_Memory_Face */ 1979 /* FT_New_Memory_Face */
1899 /* */ 1980 /* */
1900 /* <Description> */ 1981 /* <Description> */
1901 /* This function calls @FT_Open_Face to open a font which has been */ 1982 /* This function calls @FT_Open_Face to open a font that has been */
1902 /* loaded into memory. */ 1983 /* loaded into memory. */
1903 /* */ 1984 /* */
1904 /* <InOut> */ 1985 /* <InOut> */
1905 /* library :: A handle to the library resource. */ 1986 /* library :: A handle to the library resource. */
1906 /* */ 1987 /* */
1907 /* <Input> */ 1988 /* <Input> */
1908 /* file_base :: A pointer to the beginning of the font data. */ 1989 /* file_base :: A pointer to the beginning of the font data. */
1909 /* */ 1990 /* */
1910 /* file_size :: The size of the memory chunk used by the font data. */ 1991 /* file_size :: The size of the memory chunk used by the font data. */
1911 /* */ 1992 /* */
(...skipping 25 matching lines...) Expand all
1937 /* FT_Open_Face */ 2018 /* FT_Open_Face */
1938 /* */ 2019 /* */
1939 /* <Description> */ 2020 /* <Description> */
1940 /* Create a face object from a given resource described by */ 2021 /* Create a face object from a given resource described by */
1941 /* @FT_Open_Args. */ 2022 /* @FT_Open_Args. */
1942 /* */ 2023 /* */
1943 /* <InOut> */ 2024 /* <InOut> */
1944 /* library :: A handle to the library resource. */ 2025 /* library :: A handle to the library resource. */
1945 /* */ 2026 /* */
1946 /* <Input> */ 2027 /* <Input> */
1947 /* args :: A pointer to an `FT_Open_Args' structure which must */ 2028 /* args :: A pointer to an `FT_Open_Args' structure that must */
1948 /* be filled by the caller. */ 2029 /* be filled by the caller. */
1949 /* */ 2030 /* */
1950 /* face_index :: The index of the face within the font. The first */ 2031 /* face_index :: The index of the face within the font. The first */
1951 /* face has index~0. */ 2032 /* face has index~0. */
1952 /* */ 2033 /* */
1953 /* <Output> */ 2034 /* <Output> */
1954 /* aface :: A handle to a new face object. If `face_index' is */ 2035 /* aface :: A handle to a new face object. If `face_index' is */
1955 /* greater than or equal to zero, it must be non-NULL. */ 2036 /* greater than or equal to zero, it must be non-NULL. */
1956 /* See note below. */ 2037 /* See note below. */
1957 /* */ 2038 /* */
1958 /* <Return> */ 2039 /* <Return> */
1959 /* FreeType error code. 0~means success. */ 2040 /* FreeType error code. 0~means success. */
1960 /* */ 2041 /* */
1961 /* <Note> */ 2042 /* <Note> */
1962 /* Unlike FreeType 1.x, this function automatically creates a glyph */ 2043 /* Unlike FreeType 1.x, this function automatically creates a glyph */
1963 /* slot for the face object which can be accessed directly through */ 2044 /* slot for the face object that can be accessed directly through */
1964 /* `face->glyph'. */ 2045 /* `face->glyph'. */
1965 /* */ 2046 /* */
1966 /* FT_Open_Face can be used to quickly check whether the font */ 2047 /* FT_Open_Face can be used to quickly check whether the font */
1967 /* format of a given font resource is supported by FreeType. If the */ 2048 /* format of a given font resource is supported by FreeType. If the */
1968 /* `face_index' field is negative, the function's return value is~0 */ 2049 /* `face_index' field is negative, the function's return value is~0 */
1969 /* if the font format is recognized, or non-zero otherwise; */ 2050 /* if the font format is recognized, or non-zero otherwise; */
1970 /* the function returns a more or less empty face handle in `*aface' */ 2051 /* the function returns a more or less empty face handle in `*aface' */
1971 /* (if `aface' isn't NULL). The only useful field in this special */ 2052 /* (if `aface' isn't NULL). The only useful field in this special */
1972 /* case is `face->num_faces' which gives the number of faces within */ 2053 /* case is `face->num_faces' that gives the number of faces within */
1973 /* the font file. After examination, the returned @FT_Face structure */ 2054 /* the font file. After examination, the returned @FT_Face structure */
1974 /* should be deallocated with a call to @FT_Done_Face. */ 2055 /* should be deallocated with a call to @FT_Done_Face. */
1975 /* */ 2056 /* */
1976 /* Each new face object created with this function also owns a */ 2057 /* Each new face object created with this function also owns a */
1977 /* default @FT_Size object, accessible as `face->size'. */ 2058 /* default @FT_Size object, accessible as `face->size'. */
1978 /* */ 2059 /* */
1979 /* One @FT_Library instance can have multiple face objects, this is, */ 2060 /* One @FT_Library instance can have multiple face objects, this is, */
1980 /* @FT_Open_Face and its siblings can be called multiple times using */ 2061 /* @FT_Open_Face and its siblings can be called multiple times using */
1981 /* the same `library' argument. */ 2062 /* the same `library' argument. */
1982 /* */ 2063 /* */
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
2020 /* <Description> */ 2101 /* <Description> */
2021 /* `Attach' data to a face object. Normally, this is used to read */ 2102 /* `Attach' data to a face object. Normally, this is used to read */
2022 /* additional information for the face object. For example, you can */ 2103 /* additional information for the face object. For example, you can */
2023 /* attach an AFM file that comes with a Type~1 font to get the */ 2104 /* attach an AFM file that comes with a Type~1 font to get the */
2024 /* kerning values and other metrics. */ 2105 /* kerning values and other metrics. */
2025 /* */ 2106 /* */
2026 /* <InOut> */ 2107 /* <InOut> */
2027 /* face :: The target face object. */ 2108 /* face :: The target face object. */
2028 /* */ 2109 /* */
2029 /* <Input> */ 2110 /* <Input> */
2030 /* parameters :: A pointer to @FT_Open_Args which must be filled by */ 2111 /* parameters :: A pointer to @FT_Open_Args that must be filled by */
2031 /* the caller. */ 2112 /* the caller. */
2032 /* */ 2113 /* */
2033 /* <Return> */ 2114 /* <Return> */
2034 /* FreeType error code. 0~means success. */ 2115 /* FreeType error code. 0~means success. */
2035 /* */ 2116 /* */
2036 /* <Note> */ 2117 /* <Note> */
2037 /* The meaning of the `attach' (i.e., what really happens when the */ 2118 /* The meaning of the `attach' (i.e., what really happens when the */
2038 /* new file is read) is not fixed by FreeType itself. It really */ 2119 /* new file is read) is not fixed by FreeType itself. It really */
2039 /* depends on the font format (and thus the font driver). */ 2120 /* depends on the font format (and thus the font driver). */
2040 /* */ 2121 /* */
(...skipping 10 matching lines...) Expand all
2051 /* */ 2132 /* */
2052 /* <Function> */ 2133 /* <Function> */
2053 /* FT_Reference_Face */ 2134 /* FT_Reference_Face */
2054 /* */ 2135 /* */
2055 /* <Description> */ 2136 /* <Description> */
2056 /* A counter gets initialized to~1 at the time an @FT_Face structure */ 2137 /* A counter gets initialized to~1 at the time an @FT_Face structure */
2057 /* is created. This function increments the counter. @FT_Done_Face */ 2138 /* is created. This function increments the counter. @FT_Done_Face */
2058 /* then only destroys a face if the counter is~1, otherwise it simply */ 2139 /* then only destroys a face if the counter is~1, otherwise it simply */
2059 /* decrements the counter. */ 2140 /* decrements the counter. */
2060 /* */ 2141 /* */
2061 /* This function helps in managing life-cycles of structures which */ 2142 /* This function helps in managing life-cycles of structures that */
2062 /* reference @FT_Face objects. */ 2143 /* reference @FT_Face objects. */
2063 /* */ 2144 /* */
2064 /* <Input> */ 2145 /* <Input> */
2065 /* face :: A handle to a target face object. */ 2146 /* face :: A handle to a target face object. */
2066 /* */ 2147 /* */
2067 /* <Return> */ 2148 /* <Return> */
2068 /* FreeType error code. 0~means success. */ 2149 /* FreeType error code. 0~means success. */
2069 /* */ 2150 /* */
2070 /* <Since> */ 2151 /* <Since> */
2071 /* 2.4.2 */ 2152 /* 2.4.2 */
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
2246 /* request, you should not rely on this if you intend to select a */ 2327 /* request, you should not rely on this if you intend to select a */
2247 /* particular bitmap strike. Use @FT_Select_Size instead in that */ 2328 /* particular bitmap strike. Use @FT_Select_Size instead in that */
2248 /* case. */ 2329 /* case. */
2249 /* */ 2330 /* */
2250 /* The relation between the requested size and the resulting glyph */ 2331 /* The relation between the requested size and the resulting glyph */
2251 /* size is dependent entirely on how the size is defined in the */ 2332 /* size is dependent entirely on how the size is defined in the */
2252 /* source face. The font designer chooses the final size of each */ 2333 /* source face. The font designer chooses the final size of each */
2253 /* glyph relative to this size. For more information refer to */ 2334 /* glyph relative to this size. For more information refer to */
2254 /* `http://www.freetype.org/freetype2/docs/glyphs/glyphs-2.html' */ 2335 /* `http://www.freetype.org/freetype2/docs/glyphs/glyphs-2.html' */
2255 /* */ 2336 /* */
2337 /* Don't use this function if you are using the FreeType cache API. */
2338 /* */
2256 FT_EXPORT( FT_Error ) 2339 FT_EXPORT( FT_Error )
2257 FT_Request_Size( FT_Face face, 2340 FT_Request_Size( FT_Face face,
2258 FT_Size_Request req ); 2341 FT_Size_Request req );
2259 2342
2260 2343
2261 /*************************************************************************/ 2344 /*************************************************************************/
2262 /* */ 2345 /* */
2263 /* <Function> */ 2346 /* <Function> */
2264 /* FT_Set_Char_Size */ 2347 /* FT_Set_Char_Size */
2265 /* */ 2348 /* */
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
2320 /* pixel_height :: The nominal height, in pixels. */ 2403 /* pixel_height :: The nominal height, in pixels. */
2321 /* */ 2404 /* */
2322 /* <Return> */ 2405 /* <Return> */
2323 /* FreeType error code. 0~means success. */ 2406 /* FreeType error code. 0~means success. */
2324 /* */ 2407 /* */
2325 /* <Note> */ 2408 /* <Note> */
2326 /* You should not rely on the resulting glyphs matching, or being */ 2409 /* You should not rely on the resulting glyphs matching, or being */
2327 /* constrained, to this pixel size. Refer to @FT_Request_Size to */ 2410 /* constrained, to this pixel size. Refer to @FT_Request_Size to */
2328 /* understand how requested sizes relate to actual sizes. */ 2411 /* understand how requested sizes relate to actual sizes. */
2329 /* */ 2412 /* */
2413 /* Don't use this function if you are using the FreeType cache API. */
2414 /* */
2330 FT_EXPORT( FT_Error ) 2415 FT_EXPORT( FT_Error )
2331 FT_Set_Pixel_Sizes( FT_Face face, 2416 FT_Set_Pixel_Sizes( FT_Face face,
2332 FT_UInt pixel_width, 2417 FT_UInt pixel_width,
2333 FT_UInt pixel_height ); 2418 FT_UInt pixel_height );
2334 2419
2335 2420
2336 /*************************************************************************/ 2421 /*************************************************************************/
2337 /* */ 2422 /* */
2338 /* <Function> */ 2423 /* <Function> */
2339 /* FT_Load_Glyph */ 2424 /* FT_Load_Glyph */
(...skipping 18 matching lines...) Expand all
2358 /* whether to hint the outline, etc). */ 2443 /* whether to hint the outline, etc). */
2359 /* */ 2444 /* */
2360 /* <Return> */ 2445 /* <Return> */
2361 /* FreeType error code. 0~means success. */ 2446 /* FreeType error code. 0~means success. */
2362 /* */ 2447 /* */
2363 /* <Note> */ 2448 /* <Note> */
2364 /* The loaded glyph may be transformed. See @FT_Set_Transform for */ 2449 /* The loaded glyph may be transformed. See @FT_Set_Transform for */
2365 /* the details. */ 2450 /* the details. */
2366 /* */ 2451 /* */
2367 /* For subsetted CID-keyed fonts, `FT_Err_Invalid_Argument' is */ 2452 /* For subsetted CID-keyed fonts, `FT_Err_Invalid_Argument' is */
2368 /* returned for invalid CID values (this is, for CID values which */ 2453 /* returned for invalid CID values (this is, for CID values that */
2369 /* don't have a corresponding glyph in the font). See the discussion */ 2454 /* don't have a corresponding glyph in the font). See the discussion */
2370 /* of the @FT_FACE_FLAG_CID_KEYED flag for more details. */ 2455 /* of the @FT_FACE_FLAG_CID_KEYED flag for more details. */
2371 /* */ 2456 /* */
2372 FT_EXPORT( FT_Error ) 2457 FT_EXPORT( FT_Error )
2373 FT_Load_Glyph( FT_Face face, 2458 FT_Load_Glyph( FT_Face face,
2374 FT_UInt glyph_index, 2459 FT_UInt glyph_index,
2375 FT_Int32 load_flags ); 2460 FT_Int32 load_flags );
2376 2461
2377 2462
2378 /*************************************************************************/ 2463 /*************************************************************************/
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
2478 * 2563 *
2479 * In case @FT_HAS_VERTICAL doesn't return true, you shouldn't use 2564 * In case @FT_HAS_VERTICAL doesn't return true, you shouldn't use
2480 * this flag currently. Reason is that in this case vertical metrics 2565 * this flag currently. Reason is that in this case vertical metrics
2481 * get synthesized, and those values are not always consistent across 2566 * get synthesized, and those values are not always consistent across
2482 * various font formats. 2567 * various font formats.
2483 * 2568 *
2484 * FT_LOAD_FORCE_AUTOHINT :: 2569 * FT_LOAD_FORCE_AUTOHINT ::
2485 * Indicates that the auto-hinter is preferred over the font's native 2570 * Indicates that the auto-hinter is preferred over the font's native
2486 * hinter. See also the note below. 2571 * hinter. See also the note below.
2487 * 2572 *
2488 * FT_LOAD_CROP_BITMAP ::
2489 * Indicates that the font driver should crop the loaded bitmap glyph
2490 * (i.e., remove all space around its black bits). Not all drivers
2491 * implement this.
2492 *
2493 * FT_LOAD_PEDANTIC :: 2573 * FT_LOAD_PEDANTIC ::
2494 * Indicates that the font driver should perform pedantic verifications 2574 * Indicates that the font driver should perform pedantic verifications
2495 * during glyph loading. This is mostly used to detect broken glyphs 2575 * during glyph loading. This is mostly used to detect broken glyphs
2496 * in fonts. By default, FreeType tries to handle broken fonts also. 2576 * in fonts. By default, FreeType tries to handle broken fonts also.
2497 * 2577 *
2498 * In particular, errors from the TrueType bytecode engine are not 2578 * In particular, errors from the TrueType bytecode engine are not
2499 * passed to the application if this flag is not set; this might 2579 * passed to the application if this flag is not set; this might
2500 * result in partially hinted or distorted glyphs in case a glyph's 2580 * result in partially hinted or distorted glyphs in case a glyph's
2501 * bytecode is buggy. 2581 * bytecode is buggy.
2502 * 2582 *
2503 * FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH ::
2504 * Ignored. Deprecated.
2505 *
2506 * FT_LOAD_NO_RECURSE :: 2583 * FT_LOAD_NO_RECURSE ::
2507 * This flag is only used internally. It merely indicates that the 2584 * Indicate that the font driver should not load composite glyphs
2508 * font driver should not load composite glyphs recursively. Instead, 2585 * recursively. Instead, it should set the `num_subglyph' and
2509 * it should set the `num_subglyph' and `subglyphs' values of the 2586 * `subglyphs' values of the glyph slot accordingly, and set
2510 * glyph slot accordingly, and set `glyph->format' to 2587 * `glyph->format' to @FT_GLYPH_FORMAT_COMPOSITE. The description of
2511 * @FT_GLYPH_FORMAT_COMPOSITE. 2588 * subglyphs can then be accessed with @FT_Get_SubGlyph_Info.
2512 *
2513 * The description of sub-glyphs is not available to client
2514 * applications for now.
2515 * 2589 *
2516 * This flag implies @FT_LOAD_NO_SCALE and @FT_LOAD_IGNORE_TRANSFORM. 2590 * This flag implies @FT_LOAD_NO_SCALE and @FT_LOAD_IGNORE_TRANSFORM.
2517 * 2591 *
2518 * FT_LOAD_IGNORE_TRANSFORM :: 2592 * FT_LOAD_IGNORE_TRANSFORM ::
2519 * Indicates that the transform matrix set by @FT_Set_Transform should 2593 * Indicates that the transform matrix set by @FT_Set_Transform should
2520 * be ignored. 2594 * be ignored.
2521 * 2595 *
2522 * FT_LOAD_MONOCHROME :: 2596 * FT_LOAD_MONOCHROME ::
2523 * This flag is used with @FT_LOAD_RENDER to indicate that you want to 2597 * This flag is used with @FT_LOAD_RENDER to indicate that you want to
2524 * render an outline glyph to a 1-bit monochrome bitmap glyph, with 2598 * render an outline glyph to a 1-bit monochrome bitmap glyph, with
(...skipping 12 matching lines...) Expand all
2537 * Disable auto-hinter. See also the note below. 2611 * Disable auto-hinter. See also the note below.
2538 * 2612 *
2539 * FT_LOAD_COLOR :: 2613 * FT_LOAD_COLOR ::
2540 * This flag is used to request loading of color embedded-bitmap 2614 * This flag is used to request loading of color embedded-bitmap
2541 * images. The resulting color bitmaps, if available, will have the 2615 * images. The resulting color bitmaps, if available, will have the
2542 * @FT_PIXEL_MODE_BGRA format. When the flag is not used and color 2616 * @FT_PIXEL_MODE_BGRA format. When the flag is not used and color
2543 * bitmaps are found, they will be converted to 256-level gray 2617 * bitmaps are found, they will be converted to 256-level gray
2544 * bitmaps transparently. Those bitmaps will be in the 2618 * bitmaps transparently. Those bitmaps will be in the
2545 * @FT_PIXEL_MODE_GRAY format. 2619 * @FT_PIXEL_MODE_GRAY format.
2546 * 2620 *
2621 * FT_LOAD_CROP_BITMAP ::
2622 * Ignored. Deprecated.
2623 *
2624 * FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH ::
2625 * Ignored. Deprecated.
2626 *
2547 * @note: 2627 * @note:
2548 * By default, hinting is enabled and the font's native hinter (see 2628 * By default, hinting is enabled and the font's native hinter (see
2549 * @FT_FACE_FLAG_HINTER) is preferred over the auto-hinter. You can 2629 * @FT_FACE_FLAG_HINTER) is preferred over the auto-hinter. You can
2550 * disable hinting by setting @FT_LOAD_NO_HINTING or change the 2630 * disable hinting by setting @FT_LOAD_NO_HINTING or change the
2551 * precedence by setting @FT_LOAD_FORCE_AUTOHINT. You can also set 2631 * precedence by setting @FT_LOAD_FORCE_AUTOHINT. You can also set
2552 * @FT_LOAD_NO_AUTOHINT in case you don't want the auto-hinter to be 2632 * @FT_LOAD_NO_AUTOHINT in case you don't want the auto-hinter to be
2553 * used at all. 2633 * used at all.
2554 * 2634 *
2555 * See the description of @FT_FACE_FLAG_TRICKY for a special exception 2635 * See the description of @FT_FACE_FLAG_TRICKY for a special exception
2556 * (affecting only a handful of Asian fonts). 2636 * (affecting only a handful of Asian fonts).
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
2632 * 2712 *
2633 * FT_LOAD_TARGET_LCD_V :: 2713 * FT_LOAD_TARGET_LCD_V ::
2634 * A variant of @FT_LOAD_TARGET_NORMAL optimized for vertically 2714 * A variant of @FT_LOAD_TARGET_NORMAL optimized for vertically
2635 * decimated LCD displays. 2715 * decimated LCD displays.
2636 * 2716 *
2637 * @note: 2717 * @note:
2638 * You should use only _one_ of the FT_LOAD_TARGET_XXX values in your 2718 * You should use only _one_ of the FT_LOAD_TARGET_XXX values in your
2639 * `load_flags'. They can't be ORed. 2719 * `load_flags'. They can't be ORed.
2640 * 2720 *
2641 * If @FT_LOAD_RENDER is also set, the glyph is rendered in the 2721 * If @FT_LOAD_RENDER is also set, the glyph is rendered in the
2642 * corresponding mode (i.e., the mode which matches the used algorithm 2722 * corresponding mode (i.e., the mode that matches the used algorithm
2643 * best). An exeption is FT_LOAD_TARGET_MONO since it implies 2723 * best). An exeption is FT_LOAD_TARGET_MONO since it implies
2644 * @FT_LOAD_MONOCHROME. 2724 * @FT_LOAD_MONOCHROME.
2645 * 2725 *
2646 * You can use a hinting algorithm that doesn't correspond to the same 2726 * You can use a hinting algorithm that doesn't correspond to the same
2647 * rendering mode. As an example, it is possible to use the `light' 2727 * rendering mode. As an example, it is possible to use the `light'
2648 * hinting algorithm and have the results rendered in horizontal LCD 2728 * hinting algorithm and have the results rendered in horizontal LCD
2649 * pixel mode, with code like 2729 * pixel mode, with code like
2650 * 2730 *
2651 * { 2731 * {
2652 * FT_Load_Glyph( face, glyph_index, 2732 * FT_Load_Glyph( face, glyph_index,
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
2773 FT_RENDER_MODE_LIGHT, 2853 FT_RENDER_MODE_LIGHT,
2774 FT_RENDER_MODE_MONO, 2854 FT_RENDER_MODE_MONO,
2775 FT_RENDER_MODE_LCD, 2855 FT_RENDER_MODE_LCD,
2776 FT_RENDER_MODE_LCD_V, 2856 FT_RENDER_MODE_LCD_V,
2777 2857
2778 FT_RENDER_MODE_MAX 2858 FT_RENDER_MODE_MAX
2779 2859
2780 } FT_Render_Mode; 2860 } FT_Render_Mode;
2781 2861
2782 2862
2783 /*************************************************************************/ 2863 /* these constants are deprecated; use the corresponding */
2784 /* */ 2864 /* `FT_Render_Mode' values instead */
2785 /* <Enum> */
2786 /* ft_render_mode_xxx */
2787 /* */
2788 /* <Description> */
2789 /* These constants are deprecated. Use the corresponding */
2790 /* @FT_Render_Mode values instead. */
2791 /* */
2792 /* <Values> */
2793 /* ft_render_mode_normal :: see @FT_RENDER_MODE_NORMAL */
2794 /* ft_render_mode_mono :: see @FT_RENDER_MODE_MONO */
2795 /* */
2796 #define ft_render_mode_normal FT_RENDER_MODE_NORMAL 2865 #define ft_render_mode_normal FT_RENDER_MODE_NORMAL
2797 #define ft_render_mode_mono FT_RENDER_MODE_MONO 2866 #define ft_render_mode_mono FT_RENDER_MODE_MONO
2798 2867
2799 2868
2800 /*************************************************************************/ 2869 /*************************************************************************/
2801 /* */ 2870 /* */
2802 /* <Function> */ 2871 /* <Function> */
2803 /* FT_Render_Glyph */ 2872 /* FT_Render_Glyph */
2804 /* */ 2873 /* */
2805 /* <Description> */ 2874 /* <Description> */
2806 /* Convert a given glyph image to a bitmap. It does so by inspecting */ 2875 /* Convert a given glyph image to a bitmap. It does so by inspecting */
2807 /* the glyph image format, finding the relevant renderer, and */ 2876 /* the glyph image format, finding the relevant renderer, and */
2808 /* invoking it. */ 2877 /* invoking it. */
2809 /* */ 2878 /* */
2810 /* <InOut> */ 2879 /* <InOut> */
2811 /* slot :: A handle to the glyph slot containing the image to */ 2880 /* slot :: A handle to the glyph slot containing the image to */
2812 /* convert. */ 2881 /* convert. */
2813 /* */ 2882 /* */
2814 /* <Input> */ 2883 /* <Input> */
2815 /* render_mode :: This is the render mode used to render the glyph */ 2884 /* render_mode :: This is the render mode used to render the glyph */
2816 /* image into a bitmap. See @FT_Render_Mode for a */ 2885 /* image into a bitmap. See @FT_Render_Mode for a */
2817 /* list of possible values. */ 2886 /* list of possible values. */
2818 /* */ 2887 /* */
2819 /* <Return> */ 2888 /* <Return> */
2820 /* FreeType error code. 0~means success. */ 2889 /* FreeType error code. 0~means success. */
2821 /* */ 2890 /* */
2891 /* <Note> */
2892 /* To get meaningful results, font scaling values must be set with */
2893 /* functions like @FT_Set_Char_Size before calling FT_Render_Glyph. */
2894 /* */
2822 FT_EXPORT( FT_Error ) 2895 FT_EXPORT( FT_Error )
2823 FT_Render_Glyph( FT_GlyphSlot slot, 2896 FT_Render_Glyph( FT_GlyphSlot slot,
2824 FT_Render_Mode render_mode ); 2897 FT_Render_Mode render_mode );
2825 2898
2826 2899
2827 /*************************************************************************/ 2900 /*************************************************************************/
2828 /* */ 2901 /* */
2829 /* <Enum> */ 2902 /* <Enum> */
2830 /* FT_Kerning_Mode */ 2903 /* FT_Kerning_Mode */
2831 /* */ 2904 /* */
(...skipping 13 matching lines...) Expand all
2845 /* */ 2918 /* */
2846 typedef enum FT_Kerning_Mode_ 2919 typedef enum FT_Kerning_Mode_
2847 { 2920 {
2848 FT_KERNING_DEFAULT = 0, 2921 FT_KERNING_DEFAULT = 0,
2849 FT_KERNING_UNFITTED, 2922 FT_KERNING_UNFITTED,
2850 FT_KERNING_UNSCALED 2923 FT_KERNING_UNSCALED
2851 2924
2852 } FT_Kerning_Mode; 2925 } FT_Kerning_Mode;
2853 2926
2854 2927
2855 /*************************************************************************/ 2928 /* these constants are deprecated; use the corresponding */
2856 /* */ 2929 /* `FT_Kerning_Mode' values instead */
2857 /* <Const> */
2858 /* ft_kerning_default */
2859 /* */
2860 /* <Description> */
2861 /* This constant is deprecated. Please use @FT_KERNING_DEFAULT */
2862 /* instead. */
2863 /* */
2864 #define ft_kerning_default FT_KERNING_DEFAULT 2930 #define ft_kerning_default FT_KERNING_DEFAULT
2865
2866
2867 /*************************************************************************/
2868 /* */
2869 /* <Const> */
2870 /* ft_kerning_unfitted */
2871 /* */
2872 /* <Description> */
2873 /* This constant is deprecated. Please use @FT_KERNING_UNFITTED */
2874 /* instead. */
2875 /* */
2876 #define ft_kerning_unfitted FT_KERNING_UNFITTED 2931 #define ft_kerning_unfitted FT_KERNING_UNFITTED
2877
2878
2879 /*************************************************************************/
2880 /* */
2881 /* <Const> */
2882 /* ft_kerning_unscaled */
2883 /* */
2884 /* <Description> */
2885 /* This constant is deprecated. Please use @FT_KERNING_UNSCALED */
2886 /* instead. */
2887 /* */
2888 #define ft_kerning_unscaled FT_KERNING_UNSCALED 2932 #define ft_kerning_unscaled FT_KERNING_UNSCALED
2889 2933
2890 2934
2891 /*************************************************************************/ 2935 /*************************************************************************/
2892 /* */ 2936 /* */
2893 /* <Function> */ 2937 /* <Function> */
2894 /* FT_Get_Kerning */ 2938 /* FT_Get_Kerning */
2895 /* */ 2939 /* */
2896 /* <Description> */ 2940 /* <Description> */
2897 /* Return the kerning vector between two glyphs of a same face. */ 2941 /* Return the kerning vector between two glyphs of a same face. */
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
2998 /* the glyph index is invalid. In all cases of failure, the first */ 3042 /* the glyph index is invalid. In all cases of failure, the first */
2999 /* byte of `buffer' is set to~0 to indicate an empty name. */ 3043 /* byte of `buffer' is set to~0 to indicate an empty name. */
3000 /* */ 3044 /* */
3001 /* The glyph name is truncated to fit within the buffer if it is too */ 3045 /* The glyph name is truncated to fit within the buffer if it is too */
3002 /* long. The returned string is always zero-terminated. */ 3046 /* long. The returned string is always zero-terminated. */
3003 /* */ 3047 /* */
3004 /* Be aware that FreeType reorders glyph indices internally so that */ 3048 /* Be aware that FreeType reorders glyph indices internally so that */
3005 /* glyph index~0 always corresponds to the `missing glyph' (called */ 3049 /* glyph index~0 always corresponds to the `missing glyph' (called */
3006 /* `.notdef'). */ 3050 /* `.notdef'). */
3007 /* */ 3051 /* */
3008 /* This function is not compiled within the library if the config */ 3052 /* This function always returns an error if the config macro */
3009 /* macro `FT_CONFIG_OPTION_NO_GLYPH_NAMES' is defined in */ 3053 /* `FT_CONFIG_OPTION_NO_GLYPH_NAMES' is not defined in `ftoptions.h'. */
3010 /* `include/freetype/config/ftoptions.h'. */
3011 /* */ 3054 /* */
3012 FT_EXPORT( FT_Error ) 3055 FT_EXPORT( FT_Error )
3013 FT_Get_Glyph_Name( FT_Face face, 3056 FT_Get_Glyph_Name( FT_Face face,
3014 FT_UInt glyph_index, 3057 FT_UInt glyph_index,
3015 FT_Pointer buffer, 3058 FT_Pointer buffer,
3016 FT_UInt buffer_max ); 3059 FT_UInt buffer_max );
3017 3060
3018 3061
3019 /*************************************************************************/ 3062 /*************************************************************************/
3020 /* */ 3063 /* */
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
3056 /* */ 3099 /* */
3057 /* <Return> */ 3100 /* <Return> */
3058 /* FreeType error code. 0~means success. */ 3101 /* FreeType error code. 0~means success. */
3059 /* */ 3102 /* */
3060 /* <Note> */ 3103 /* <Note> */
3061 /* This function returns an error if no charmap in the face */ 3104 /* This function returns an error if no charmap in the face */
3062 /* corresponds to the encoding queried here. */ 3105 /* corresponds to the encoding queried here. */
3063 /* */ 3106 /* */
3064 /* Because many fonts contain more than a single cmap for Unicode */ 3107 /* Because many fonts contain more than a single cmap for Unicode */
3065 /* encoding, this function has some special code to select the one */ 3108 /* encoding, this function has some special code to select the one */
3066 /* which covers Unicode best (`best' in the sense that a UCS-4 cmap */ 3109 /* that covers Unicode best (`best' in the sense that a UCS-4 cmap is */
3067 /* is preferred to a UCS-2 cmap). It is thus preferable to */ 3110 /* preferred to a UCS-2 cmap). It is thus preferable to */
3068 /* @FT_Set_Charmap in this case. */ 3111 /* @FT_Set_Charmap in this case. */
3069 /* */ 3112 /* */
3070 FT_EXPORT( FT_Error ) 3113 FT_EXPORT( FT_Error )
3071 FT_Select_Charmap( FT_Face face, 3114 FT_Select_Charmap( FT_Face face,
3072 FT_Encoding encoding ); 3115 FT_Encoding encoding );
3073 3116
3074 3117
3075 /*************************************************************************/ 3118 /*************************************************************************/
3076 /* */ 3119 /* */
3077 /* <Function> */ 3120 /* <Function> */
(...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after
3411 /* Return the fsType flags for a font. */ 3454 /* Return the fsType flags for a font. */
3412 /* */ 3455 /* */
3413 /* <Input> */ 3456 /* <Input> */
3414 /* face :: A handle to the source face object. */ 3457 /* face :: A handle to the source face object. */
3415 /* */ 3458 /* */
3416 /* <Return> */ 3459 /* <Return> */
3417 /* The fsType flags, @FT_FSTYPE_XXX. */ 3460 /* The fsType flags, @FT_FSTYPE_XXX. */
3418 /* */ 3461 /* */
3419 /* <Note> */ 3462 /* <Note> */
3420 /* Use this function rather than directly reading the `fs_type' field */ 3463 /* Use this function rather than directly reading the `fs_type' field */
3421 /* in the @PS_FontInfoRec structure which is only guaranteed to */ 3464 /* in the @PS_FontInfoRec structure, which is only guaranteed to */
3422 /* return the correct results for Type~1 fonts. */ 3465 /* return the correct results for Type~1 fonts. */
3423 /* */ 3466 /* */
3424 /* <Since> */ 3467 /* <Since> */
3425 /* 2.3.8 */ 3468 /* 2.3.8 */
3426 /* */ 3469 /* */
3427 FT_EXPORT( FT_UShort ) 3470 FT_EXPORT( FT_UShort )
3428 FT_Get_FSType_Flags( FT_Face face ); 3471 FT_Get_FSType_Flags( FT_Face face );
3429 3472
3430 3473
3431 /*************************************************************************/ 3474 /*************************************************************************/
(...skipping 16 matching lines...) Expand all
3448 /* Unicode base character and one of 240 variant selectors */ 3491 /* Unicode base character and one of 240 variant selectors */
3449 /* (U+E0100-U+E01EF), instead of further extending the already huge */ 3492 /* (U+E0100-U+E01EF), instead of further extending the already huge */
3450 /* code range for CJK characters. */ 3493 /* code range for CJK characters. */
3451 /* */ 3494 /* */
3452 /* An IVS is registered and unique; for further details please refer */ 3495 /* An IVS is registered and unique; for further details please refer */
3453 /* to Unicode Technical Standard #37, the Ideographic Variation */ 3496 /* to Unicode Technical Standard #37, the Ideographic Variation */
3454 /* Database: */ 3497 /* Database: */
3455 /* */ 3498 /* */
3456 /* http://www.unicode.org/reports/tr37/ */ 3499 /* http://www.unicode.org/reports/tr37/ */
3457 /* */ 3500 /* */
3458 /* To date (November 2012), the character with the most variants is */ 3501 /* To date (November 2014), the character with the most variants is */
3459 /* U+9089, having 31 such IVS. */ 3502 /* U+9089, having 32 such IVS. */
3460 /* */ 3503 /* */
3461 /* Adobe and MS decided to support IVS with a new cmap subtable */ 3504 /* Adobe and MS decided to support IVS with a new cmap subtable */
3462 /* (format~14). It is an odd subtable because it is not a mapping of */ 3505 /* (format~14). It is an odd subtable because it is not a mapping of */
3463 /* input code points to glyphs, but contains lists of all variants */ 3506 /* input code points to glyphs, but contains lists of all variants */
3464 /* supported by the font. */ 3507 /* supported by the font. */
3465 /* */ 3508 /* */
3466 /* A variant may be either `default' or `non-default'. A default */ 3509 /* A variant may be either `default' or `non-default'. A default */
3467 /* variant is the one you will get for that code point if you look it */ 3510 /* variant is the one you will get for that code point if you look it */
3468 /* up in the standard Unicode cmap. A non-default variant is a */ 3511 /* up in the standard Unicode cmap. A non-default variant is a */
3469 /* different glyph. */ 3512 /* different glyph. */
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after
3591 /* for the specified character code. */ 3634 /* for the specified character code. */
3592 /* */ 3635 /* */
3593 /* <Input> */ 3636 /* <Input> */
3594 /* face :: */ 3637 /* face :: */
3595 /* A handle to the source face object. */ 3638 /* A handle to the source face object. */
3596 /* */ 3639 /* */
3597 /* charcode :: */ 3640 /* charcode :: */
3598 /* The character codepoint in Unicode. */ 3641 /* The character codepoint in Unicode. */
3599 /* */ 3642 /* */
3600 /* <Return> */ 3643 /* <Return> */
3601 /* A pointer to an array of variant selector code points which are */ 3644 /* A pointer to an array of variant selector code points that are */
3602 /* active for the given character, or NULL if the corresponding list */ 3645 /* active for the given character, or NULL if the corresponding list */
3603 /* is empty. */ 3646 /* is empty. */
3604 /* */ 3647 /* */
3605 /* <Note> */ 3648 /* <Note> */
3606 /* The last item in the array is~0; the array is owned by the */ 3649 /* The last item in the array is~0; the array is owned by the */
3607 /* @FT_Face object but can be overwritten or released on the next */ 3650 /* @FT_Face object but can be overwritten or released on the next */
3608 /* call to a FreeType function. */ 3651 /* call to a FreeType function. */
3609 /* */ 3652 /* */
3610 /* <Since> */ 3653 /* <Since> */
3611 /* 2.3.6 */ 3654 /* 2.3.6 */
(...skipping 13 matching lines...) Expand all
3625 /* the specified variant selector. */ 3668 /* the specified variant selector. */
3626 /* */ 3669 /* */
3627 /* <Input> */ 3670 /* <Input> */
3628 /* face :: */ 3671 /* face :: */
3629 /* A handle to the source face object. */ 3672 /* A handle to the source face object. */
3630 /* */ 3673 /* */
3631 /* variantSelector :: */ 3674 /* variantSelector :: */
3632 /* The variant selector code point in Unicode. */ 3675 /* The variant selector code point in Unicode. */
3633 /* */ 3676 /* */
3634 /* <Return> */ 3677 /* <Return> */
3635 /* A list of all the code points which are specified by this selector */ 3678 /* A list of all the code points that are specified by this selector */
3636 /* (both default and non-default codes are returned) or NULL if there */ 3679 /* (both default and non-default codes are returned) or NULL if there */
3637 /* is no valid cmap or the variant selector is invalid. */ 3680 /* is no valid cmap or the variant selector is invalid. */
3638 /* */ 3681 /* */
3639 /* <Note> */ 3682 /* <Note> */
3640 /* The last item in the array is~0; the array is owned by the */ 3683 /* The last item in the array is~0; the array is owned by the */
3641 /* @FT_Face object but can be overwritten or released on the next */ 3684 /* @FT_Face object but can be overwritten or released on the next */
3642 /* call to a FreeType function. */ 3685 /* call to a FreeType function. */
3643 /* */ 3686 /* */
3644 /* <Since> */ 3687 /* <Since> */
3645 /* 2.3.6 */ 3688 /* 2.3.6 */
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
3700 /* The result of `(a*b)/c'. This function never traps when trying to */ 3743 /* The result of `(a*b)/c'. This function never traps when trying to */
3701 /* divide by zero; it simply returns `MaxInt' or `MinInt' depending */ 3744 /* divide by zero; it simply returns `MaxInt' or `MinInt' depending */
3702 /* on the signs of `a' and `b'. */ 3745 /* on the signs of `a' and `b'. */
3703 /* */ 3746 /* */
3704 FT_EXPORT( FT_Long ) 3747 FT_EXPORT( FT_Long )
3705 FT_MulDiv( FT_Long a, 3748 FT_MulDiv( FT_Long a,
3706 FT_Long b, 3749 FT_Long b,
3707 FT_Long c ); 3750 FT_Long c );
3708 3751
3709 3752
3710 /* */
3711
3712 /* The following #if 0 ... #endif is for the documentation formatter, */
3713 /* hiding the internal `FT_MULFIX_INLINED' macro. */
3714
3715 #if 0
3716 /*************************************************************************/ 3753 /*************************************************************************/
3717 /* */ 3754 /* */
3718 /* <Function> */ 3755 /* <Function> */
3719 /* FT_MulFix */ 3756 /* FT_MulFix */
3720 /* */ 3757 /* */
3721 /* <Description> */ 3758 /* <Description> */
3722 /* A very simple function used to perform the computation */ 3759 /* A very simple function used to perform the computation */
3723 /* `(a*b)/0x10000' with maximum accuracy. Most of the time this is */ 3760 /* `(a*b)/0x10000' with maximum accuracy. Most of the time this is */
3724 /* used to multiply a given value by a 16.16 fixed-point factor. */ 3761 /* used to multiply a given value by a 16.16 fixed-point factor. */
3725 /* */ 3762 /* */
(...skipping 13 matching lines...) Expand all
3739 /* improvements between versions 2.x and 1.x. */ 3776 /* improvements between versions 2.x and 1.x. */
3740 /* */ 3777 /* */
3741 /* As a conclusion, always try to place a 16.16 factor as the */ 3778 /* As a conclusion, always try to place a 16.16 factor as the */
3742 /* _second_ argument of this function; this can make a great */ 3779 /* _second_ argument of this function; this can make a great */
3743 /* difference. */ 3780 /* difference. */
3744 /* */ 3781 /* */
3745 FT_EXPORT( FT_Long ) 3782 FT_EXPORT( FT_Long )
3746 FT_MulFix( FT_Long a, 3783 FT_MulFix( FT_Long a,
3747 FT_Long b ); 3784 FT_Long b );
3748 3785
3749 /* */
3750 #endif
3751
3752 #ifdef FT_MULFIX_INLINED
3753 #define FPDFAPI_FT_MulFix( a, b ) FT_MULFIX_INLINED( a, b )
3754 #else
3755 FT_EXPORT( FT_Long )
3756 FT_MulFix( FT_Long a,
3757 FT_Long b );
3758 #endif
3759
3760 3786
3761 /*************************************************************************/ 3787 /*************************************************************************/
3762 /* */ 3788 /* */
3763 /* <Function> */ 3789 /* <Function> */
3764 /* FT_DivFix */ 3790 /* FT_DivFix */
3765 /* */ 3791 /* */
3766 /* <Description> */ 3792 /* <Description> */
3767 /* A very simple function used to perform the computation */ 3793 /* A very simple function used to perform the computation */
3768 /* `(a*0x10000)/b' with maximum accuracy. Most of the time, this is */ 3794 /* `(a*0x10000)/b' with maximum accuracy. Most of the time, this is */
3769 /* used to divide a given value by a 16.16 fixed-point factor. */ 3795 /* used to divide a given value by a 16.16 fixed-point factor. */
3770 /* */ 3796 /* */
3771 /* <Input> */ 3797 /* <Input> */
3772 /* a :: The first multiplier. */ 3798 /* a :: The numerator. */
3773 /* b :: The second multiplier. Use a 16.16 factor here whenever */ 3799 /* b :: The denominator. Use a 16.16 factor here. */
3774 /* possible (see note below). */
3775 /* */ 3800 /* */
3776 /* <Return> */ 3801 /* <Return> */
3777 /* The result of `(a*0x10000)/b'. */ 3802 /* The result of `(a*0x10000)/b'. */
3778 /* */ 3803 /* */
3779 /* <Note> */
3780 /* The optimization for FT_DivFix() is simple: If (a~<<~16) fits in */
3781 /* 32~bits, then the division is computed directly. Otherwise, we */
3782 /* use a specialized version of @FT_MulDiv. */
3783 /* */
3784 FT_EXPORT( FT_Long ) 3804 FT_EXPORT( FT_Long )
3785 FT_DivFix( FT_Long a, 3805 FT_DivFix( FT_Long a,
3786 FT_Long b ); 3806 FT_Long b );
3787 3807
3788 3808
3789 /*************************************************************************/ 3809 /*************************************************************************/
3790 /* */ 3810 /* */
3791 /* <Function> */ 3811 /* <Function> */
3792 /* FT_RoundFix */ 3812 /* FT_RoundFix */
3793 /* */ 3813 /* */
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
3873 /* FreeType Version */ 3893 /* FreeType Version */
3874 /* */ 3894 /* */
3875 /* <Abstract> */ 3895 /* <Abstract> */
3876 /* Functions and macros related to FreeType versions. */ 3896 /* Functions and macros related to FreeType versions. */
3877 /* */ 3897 /* */
3878 /* <Description> */ 3898 /* <Description> */
3879 /* Note that those functions and macros are of limited use because */ 3899 /* Note that those functions and macros are of limited use because */
3880 /* even a new release of FreeType with only documentation changes */ 3900 /* even a new release of FreeType with only documentation changes */
3881 /* increases the version number. */ 3901 /* increases the version number. */
3882 /* */ 3902 /* */
3903 /* <Order> */
3904 /* FT_Library_Version */
3905 /* */
3906 /* FREETYPE_MAJOR */
3907 /* FREETYPE_MINOR */
3908 /* FREETYPE_PATCH */
3909 /* */
3910 /* FT_Face_CheckTrueTypePatents */
3911 /* FT_Face_SetUnpatentedHinting */
3912 /* */
3913 /* FREETYPE_XXX */
3914 /* */
3883 /*************************************************************************/ 3915 /*************************************************************************/
3884 3916
3885 3917
3886 /************************************************************************* 3918 /*************************************************************************
3887 * 3919 *
3888 * @enum: 3920 * @enum:
3889 * FREETYPE_XXX 3921 * FREETYPE_XXX
3890 * 3922 *
3891 * @description: 3923 * @description:
3892 * These three macros identify the FreeType source code version. 3924 * These three macros identify the FreeType source code version.
3893 * Use @FT_Library_Version to access them at runtime. 3925 * Use @FT_Library_Version to access them at runtime.
3894 * 3926 *
3895 * @values: 3927 * @values:
3896 * FREETYPE_MAJOR :: The major version number. 3928 * FREETYPE_MAJOR :: The major version number.
3897 * FREETYPE_MINOR :: The minor version number. 3929 * FREETYPE_MINOR :: The minor version number.
3898 * FREETYPE_PATCH :: The patch level. 3930 * FREETYPE_PATCH :: The patch level.
3899 * 3931 *
3900 * @note: 3932 * @note:
3901 * The version number of FreeType if built as a dynamic link library 3933 * The version number of FreeType if built as a dynamic link library
3902 * with the `libtool' package is _not_ controlled by these three 3934 * with the `libtool' package is _not_ controlled by these three
3903 * macros. 3935 * macros.
3904 * 3936 *
3905 */ 3937 */
3906 #define FREETYPE_MAJOR 2 3938 #define FREETYPE_MAJOR 2
3907 #define FREETYPE_MINOR 5 3939 #define FREETYPE_MINOR 5
3908 #define FREETYPE_PATCH 0 3940 #define FREETYPE_PATCH 4
3909 3941
3910 3942
3911 /*************************************************************************/ 3943 /*************************************************************************/
3912 /* */ 3944 /* */
3913 /* <Function> */ 3945 /* <Function> */
3914 /* FT_Library_Version */ 3946 /* FT_Library_Version */
3915 /* */ 3947 /* */
3916 /* <Description> */ 3948 /* <Description> */
3917 /* Return the version of the FreeType library being used. This is */ 3949 /* Return the version of the FreeType library being used. This is */
3918 /* useful when dynamically linking to the library, since one cannot */ 3950 /* useful when dynamically linking to the library, since one cannot */
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
4007 4039
4008 /* */ 4040 /* */
4009 4041
4010 4042
4011 FT_END_HEADER 4043 FT_END_HEADER
4012 4044
4013 #endif /* __FREETYPE_H__ */ 4045 #endif /* __FREETYPE_H__ */
4014 4046
4015 4047
4016 /* END */ 4048 /* END */
OLDNEW
« no previous file with comments | « third_party/freetype/include/config/ftstdlib.h ('k') | third_party/freetype/include/ft2build.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698