00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 #ifndef __T1PARSE_H__
00020 #define __T1PARSE_H__
00021
00022
00023 #include <ft2build.h>
00024 #include FT_INTERNAL_TYPE1_TYPES_H
00025 #include FT_INTERNAL_STREAM_H
00026
00027
00028 FT_BEGIN_HEADER
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061 typedef struct T1_ParserRec_
00062 {
00063 PS_ParserRec root;
00064 FT_Stream stream;
00065
00066 FT_Byte* base_dict;
00067 FT_ULong base_len;
00068
00069 FT_Byte* private_dict;
00070 FT_ULong private_len;
00071
00072 FT_Bool in_pfb;
00073 FT_Bool in_memory;
00074 FT_Bool single_block;
00075
00076 } T1_ParserRec, *T1_Parser;
00077
00078
00079 #define T1_Add_Table( p, i, o, l ) (p)->funcs.add( (p), i, o, l )
00080 #define T1_Done_Table( p ) \
00081 do \
00082 { \
00083 if ( (p)->funcs.done ) \
00084 (p)->funcs.done( p ); \
00085 } while ( 0 )
00086 #define T1_Release_Table( p ) \
00087 do \
00088 { \
00089 if ( (p)->funcs.release ) \
00090 (p)->funcs.release( p ); \
00091 } while ( 0 )
00092
00093
00094 #define T1_Skip_Spaces( p ) (p)->root.funcs.skip_spaces( &(p)->root )
00095 #define T1_Skip_PS_Token( p ) (p)->root.funcs.skip_PS_token( &(p)->root )
00096
00097 #define T1_ToInt( p ) (p)->root.funcs.to_int( &(p)->root )
00098 #define T1_ToFixed( p, t ) (p)->root.funcs.to_fixed( &(p)->root, t )
00099
00100 #define T1_ToCoordArray( p, m, c ) \
00101 (p)->root.funcs.to_coord_array( &(p)->root, m, c )
00102 #define T1_ToFixedArray( p, m, f, t ) \
00103 (p)->root.funcs.to_fixed_array( &(p)->root, m, f, t )
00104 #define T1_ToToken( p, t ) \
00105 (p)->root.funcs.to_token( &(p)->root, t )
00106 #define T1_ToTokenArray( p, t, m, c ) \
00107 (p)->root.funcs.to_token_array( &(p)->root, t, m, c )
00108
00109 #define T1_Load_Field( p, f, o, m, pf ) \
00110 (p)->root.funcs.load_field( &(p)->root, f, o, m, pf )
00111
00112 #define T1_Load_Field_Table( p, f, o, m, pf ) \
00113 (p)->root.funcs.load_field_table( &(p)->root, f, o, m, pf )
00114
00115
00116 FT_LOCAL( FT_Error )
00117 T1_New_Parser( T1_Parser parser,
00118 FT_Stream stream,
00119 FT_Memory memory,
00120 PSAux_Service psaux );
00121
00122 FT_LOCAL( FT_Error )
00123 T1_Get_Private_Dict( T1_Parser parser,
00124 PSAux_Service psaux );
00125
00126 FT_LOCAL( void )
00127 T1_Finalize_Parser( T1_Parser parser );
00128
00129
00130 FT_END_HEADER
00131
00132 #endif
00133
00134
00135