update for HEAD-2003050101
[reactos.git] / lib / freetype / src / psaux / psauxmod.c
1 /***************************************************************************/
2 /*                                                                         */
3 /*  psauxmod.c                                                             */
4 /*                                                                         */
5 /*    FreeType auxiliary PostScript module implementation (body).          */
6 /*                                                                         */
7 /*  Copyright 2000-2001, 2002 by                                           */
8 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
9 /*                                                                         */
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      */
12 /*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
13 /*  this file you indicate that you have read the license and              */
14 /*  understand and accept it fully.                                        */
15 /*                                                                         */
16 /***************************************************************************/
17
18
19 #include <ft2build.h>
20 #include "psauxmod.h"
21 #include "psobjs.h"
22 #include "t1decode.h"
23 #include "t1cmap.h"
24
25
26   FT_CALLBACK_TABLE_DEF
27   const PS_Table_FuncsRec  ps_table_funcs =
28   {
29     ps_table_new,
30     ps_table_done,
31     ps_table_add,
32     ps_table_release
33   };
34
35
36   FT_CALLBACK_TABLE_DEF
37   const PS_Parser_FuncsRec  ps_parser_funcs =
38   {
39     ps_parser_init,
40     ps_parser_done,
41     ps_parser_skip_spaces,
42     ps_parser_skip_alpha,
43     ps_parser_to_int,
44     ps_parser_to_fixed,
45     ps_parser_to_coord_array,
46     ps_parser_to_fixed_array,
47     ps_parser_to_token,
48     ps_parser_to_token_array,
49     ps_parser_load_field,
50     ps_parser_load_field_table
51   };
52
53
54   FT_CALLBACK_TABLE_DEF
55   const T1_Builder_FuncsRec  t1_builder_funcs =
56   {
57     t1_builder_init,
58     t1_builder_done,
59     t1_builder_check_points,
60     t1_builder_add_point,
61     t1_builder_add_point1,
62     t1_builder_add_contour,
63     t1_builder_start_point,
64     t1_builder_close_contour
65   };
66
67
68   FT_CALLBACK_TABLE_DEF
69   const T1_Decoder_FuncsRec  t1_decoder_funcs =
70   {
71     t1_decoder_init,
72     t1_decoder_done,
73     t1_decoder_parse_charstrings
74   };
75
76
77   FT_CALLBACK_TABLE_DEF
78   const T1_CMap_ClassesRec  t1_cmap_classes =
79   {
80     &t1_cmap_standard_class_rec,
81     &t1_cmap_expert_class_rec,
82     &t1_cmap_custom_class_rec,
83     &t1_cmap_unicode_class_rec
84   };
85
86
87   static
88   const PSAux_Interface  psaux_interface =
89   {
90     &ps_table_funcs,
91     &ps_parser_funcs,
92     &t1_builder_funcs,
93     &t1_decoder_funcs,
94
95     t1_decrypt,
96     
97     (const T1_CMap_ClassesRec*) &t1_cmap_classes,
98   };
99
100
101   FT_CALLBACK_TABLE_DEF
102   const FT_Module_Class  psaux_module_class =
103   {
104     0,
105     sizeof( FT_ModuleRec ),
106     "psaux",
107     0x10000L,
108     0x20000L,
109
110     &psaux_interface,  /* module-specific interface */
111
112     (FT_Module_Constructor)0,
113     (FT_Module_Destructor) 0,
114     (FT_Module_Requester)  0
115   };
116
117
118 /* END */