rev |
line source |
nuclear@0
|
1 /***************************************************************************/
|
nuclear@0
|
2 /* */
|
nuclear@0
|
3 /* ftmoderr.h */
|
nuclear@0
|
4 /* */
|
nuclear@0
|
5 /* FreeType module error offsets (specification). */
|
nuclear@0
|
6 /* */
|
nuclear@0
|
7 /* Copyright 2001, 2002, 2003, 2004, 2005 by */
|
nuclear@0
|
8 /* David Turner, Robert Wilhelm, and Werner Lemberg. */
|
nuclear@0
|
9 /* */
|
nuclear@0
|
10 /* This file is part of the FreeType project, and may only be used, */
|
nuclear@0
|
11 /* modified, and distributed under the terms of the FreeType project */
|
nuclear@0
|
12 /* license, LICENSE.TXT. By continuing to use, modify, or distribute */
|
nuclear@0
|
13 /* this file you indicate that you have read the license and */
|
nuclear@0
|
14 /* understand and accept it fully. */
|
nuclear@0
|
15 /* */
|
nuclear@0
|
16 /***************************************************************************/
|
nuclear@0
|
17
|
nuclear@0
|
18
|
nuclear@0
|
19 /*************************************************************************/
|
nuclear@0
|
20 /* */
|
nuclear@0
|
21 /* This file is used to define the FreeType module error offsets. */
|
nuclear@0
|
22 /* */
|
nuclear@0
|
23 /* The lower byte gives the error code, the higher byte gives the */
|
nuclear@0
|
24 /* module. The base module has error offset 0. For example, the error */
|
nuclear@0
|
25 /* `FT_Err_Invalid_File_Format' has value 0x003, the error */
|
nuclear@0
|
26 /* `TT_Err_Invalid_File_Format' has value 0x1103, the error */
|
nuclear@0
|
27 /* `T1_Err_Invalid_File_Format' has value 0x1203, etc. */
|
nuclear@0
|
28 /* */
|
nuclear@0
|
29 /* Undefine the macro FT_CONFIG_OPTION_USE_MODULE_ERRORS in ftoption.h */
|
nuclear@0
|
30 /* to make the higher byte always zero (disabling the module error */
|
nuclear@0
|
31 /* mechanism). */
|
nuclear@0
|
32 /* */
|
nuclear@0
|
33 /* It can also be used to create a module error message table easily */
|
nuclear@0
|
34 /* with something like */
|
nuclear@0
|
35 /* */
|
nuclear@0
|
36 /* { */
|
nuclear@0
|
37 /* #undef __FTMODERR_H__ */
|
nuclear@0
|
38 /* #define FT_MODERRDEF( e, v, s ) { FT_Mod_Err_ ## e, s }, */
|
nuclear@0
|
39 /* #define FT_MODERR_START_LIST { */
|
nuclear@0
|
40 /* #define FT_MODERR_END_LIST { 0, 0 } }; */
|
nuclear@0
|
41 /* */
|
nuclear@0
|
42 /* const struct */
|
nuclear@0
|
43 /* { */
|
nuclear@0
|
44 /* int mod_err_offset; */
|
nuclear@0
|
45 /* const char* mod_err_msg */
|
nuclear@0
|
46 /* } ft_mod_errors[] = */
|
nuclear@0
|
47 /* */
|
nuclear@0
|
48 /* #include FT_MODULE_ERRORS_H */
|
nuclear@0
|
49 /* } */
|
nuclear@0
|
50 /* */
|
nuclear@0
|
51 /* To use such a table, all errors must be ANDed with 0xFF00 to remove */
|
nuclear@0
|
52 /* the error code. */
|
nuclear@0
|
53 /* */
|
nuclear@0
|
54 /*************************************************************************/
|
nuclear@0
|
55
|
nuclear@0
|
56
|
nuclear@0
|
57 #ifndef __FTMODERR_H__
|
nuclear@0
|
58 #define __FTMODERR_H__
|
nuclear@0
|
59
|
nuclear@0
|
60
|
nuclear@0
|
61 /*******************************************************************/
|
nuclear@0
|
62 /*******************************************************************/
|
nuclear@0
|
63 /***** *****/
|
nuclear@0
|
64 /***** SETUP MACROS *****/
|
nuclear@0
|
65 /***** *****/
|
nuclear@0
|
66 /*******************************************************************/
|
nuclear@0
|
67 /*******************************************************************/
|
nuclear@0
|
68
|
nuclear@0
|
69
|
nuclear@0
|
70 #undef FT_NEED_EXTERN_C
|
nuclear@0
|
71
|
nuclear@0
|
72 #ifndef FT_MODERRDEF
|
nuclear@0
|
73
|
nuclear@0
|
74 #ifdef FT_CONFIG_OPTION_USE_MODULE_ERRORS
|
nuclear@0
|
75 #define FT_MODERRDEF( e, v, s ) FT_Mod_Err_ ## e = v,
|
nuclear@0
|
76 #else
|
nuclear@0
|
77 #define FT_MODERRDEF( e, v, s ) FT_Mod_Err_ ## e = 0,
|
nuclear@0
|
78 #endif
|
nuclear@0
|
79
|
nuclear@0
|
80 #define FT_MODERR_START_LIST enum {
|
nuclear@0
|
81 #define FT_MODERR_END_LIST FT_Mod_Err_Max };
|
nuclear@0
|
82
|
nuclear@0
|
83 #ifdef __cplusplus
|
nuclear@0
|
84 #define FT_NEED_EXTERN_C
|
nuclear@0
|
85 extern "C" {
|
nuclear@0
|
86 #endif
|
nuclear@0
|
87
|
nuclear@0
|
88 #endif /* !FT_MODERRDEF */
|
nuclear@0
|
89
|
nuclear@0
|
90
|
nuclear@0
|
91 /*******************************************************************/
|
nuclear@0
|
92 /*******************************************************************/
|
nuclear@0
|
93 /***** *****/
|
nuclear@0
|
94 /***** LIST MODULE ERROR BASES *****/
|
nuclear@0
|
95 /***** *****/
|
nuclear@0
|
96 /*******************************************************************/
|
nuclear@0
|
97 /*******************************************************************/
|
nuclear@0
|
98
|
nuclear@0
|
99
|
nuclear@0
|
100 #ifdef FT_MODERR_START_LIST
|
nuclear@0
|
101 FT_MODERR_START_LIST
|
nuclear@0
|
102 #endif
|
nuclear@0
|
103
|
nuclear@0
|
104
|
nuclear@0
|
105 FT_MODERRDEF( Base, 0x000, "base module" )
|
nuclear@0
|
106 FT_MODERRDEF( Autofit, 0x100, "autofitter module" )
|
nuclear@0
|
107 FT_MODERRDEF( BDF, 0x200, "BDF module" )
|
nuclear@0
|
108 FT_MODERRDEF( Cache, 0x300, "cache module" )
|
nuclear@0
|
109 FT_MODERRDEF( CFF, 0x400, "CFF module" )
|
nuclear@0
|
110 FT_MODERRDEF( CID, 0x500, "CID module" )
|
nuclear@0
|
111 FT_MODERRDEF( Gzip, 0x600, "Gzip module" )
|
nuclear@0
|
112 FT_MODERRDEF( LZW, 0x700, "LZW module" )
|
nuclear@0
|
113 FT_MODERRDEF( OTvalid, 0x800, "OpenType validation module" )
|
nuclear@0
|
114 FT_MODERRDEF( PCF, 0x900, "PCF module" )
|
nuclear@0
|
115 FT_MODERRDEF( PFR, 0xA00, "PFR module" )
|
nuclear@0
|
116 FT_MODERRDEF( PSaux, 0xB00, "PS auxiliary module" )
|
nuclear@0
|
117 FT_MODERRDEF( PShinter, 0xC00, "PS hinter module" )
|
nuclear@0
|
118 FT_MODERRDEF( PSnames, 0xD00, "PS names module" )
|
nuclear@0
|
119 FT_MODERRDEF( Raster, 0xE00, "raster module" )
|
nuclear@0
|
120 FT_MODERRDEF( SFNT, 0xF00, "SFNT module" )
|
nuclear@0
|
121 FT_MODERRDEF( Smooth, 0x1000, "smooth raster module" )
|
nuclear@0
|
122 FT_MODERRDEF( TrueType, 0x1100, "TrueType module" )
|
nuclear@0
|
123 FT_MODERRDEF( Type1, 0x1200, "Type 1 module" )
|
nuclear@0
|
124 FT_MODERRDEF( Type42, 0x1300, "Type 42 module" )
|
nuclear@0
|
125 FT_MODERRDEF( Winfonts, 0x1400, "Windows FON/FNT module" )
|
nuclear@0
|
126
|
nuclear@0
|
127
|
nuclear@0
|
128 #ifdef FT_MODERR_END_LIST
|
nuclear@0
|
129 FT_MODERR_END_LIST
|
nuclear@0
|
130 #endif
|
nuclear@0
|
131
|
nuclear@0
|
132
|
nuclear@0
|
133 /*******************************************************************/
|
nuclear@0
|
134 /*******************************************************************/
|
nuclear@0
|
135 /***** *****/
|
nuclear@0
|
136 /***** CLEANUP *****/
|
nuclear@0
|
137 /***** *****/
|
nuclear@0
|
138 /*******************************************************************/
|
nuclear@0
|
139 /*******************************************************************/
|
nuclear@0
|
140
|
nuclear@0
|
141
|
nuclear@0
|
142 #ifdef FT_NEED_EXTERN_C
|
nuclear@0
|
143 }
|
nuclear@0
|
144 #endif
|
nuclear@0
|
145
|
nuclear@0
|
146 #undef FT_MODERR_START_LIST
|
nuclear@0
|
147 #undef FT_MODERR_END_LIST
|
nuclear@0
|
148 #undef FT_MODERRDEF
|
nuclear@0
|
149 #undef FT_NEED_EXTERN_C
|
nuclear@0
|
150
|
nuclear@0
|
151
|
nuclear@0
|
152 #endif /* __FTMODERR_H__ */
|
nuclear@0
|
153
|
nuclear@0
|
154
|
nuclear@0
|
155 /* END */
|