~ubuntu-branches/ubuntu/trusty/libxfont/trusty-updates

« back to all changes in this revision

Viewing changes to src/Type1/fontfcn.h

  • Committer: Bazaar Package Importer
  • Author(s): Julien Cristau
  • Date: 2007-02-16 14:32:57 UTC
  • mfrom: (1.1.4 upstream)
  • Revision ID: james.westby@ubuntu.com-20070216143257-r24zgvh3taklylv9
Tags: 1:1.2.7-1
* New upstream release.
* Add XS-Vcs-Git header to debian/control, and drop obsolete CVS information.
* Install the upstream ChangeLog.

Show diffs side-by-side

added added

removed removed

Lines of Context:
27
27
 * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
28
28
 * SOFTWARE.
29
29
 */
30
 
/* Copyright (c) 1994-1999 Silicon Graphics, Inc. All Rights Reserved.
31
 
 *
32
 
 * The contents of this file are subject to the CID Font Code Public Licence
33
 
 * Version 1.0 (the "License"). You may not use this file except in compliance
34
 
 * with the Licence. You may obtain a copy of the License at Silicon Graphics,
35
 
 * Inc., attn: Legal Services, 2011 N. Shoreline Blvd., Mountain View, CA
36
 
 * 94043 or at http://www.sgi.com/software/opensource/cid/license.html.
37
 
 *
38
 
 * Software distributed under the License is distributed on an "AS IS" basis.
39
 
 * ALL WARRANTIES ARE DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED
40
 
 * WARRANTIES OF MERCHANTABILITY, OF FITNESS FOR A PARTICULAR PURPOSE OR OF
41
 
 * NON-INFRINGEMENT. See the License for the specific language governing
42
 
 * rights and limitations under the License.
43
 
 *
44
 
 * The Original Software is CID font code that was developed by Silicon
45
 
 * Graphics, Inc.
46
 
 */
47
30
/* $XFree86: xc/lib/font/Type1/fontfcn.h,v 1.4 1999/08/22 08:58:50 dawes Exp $ */
48
31
 
49
32
 
50
 
#ifdef BUILDCID
51
 
#define XFONT_CID 1
52
 
#endif
53
 
 
54
33
/* modular config.h defines VERSION as libXfont version */
55
34
#ifdef VERSION
56
35
#undef VERSION
57
36
#endif
58
37
 
59
 
#if XFONT_CID
60
 
/* Definition of a PostScript CIDFont resource */
61
 
typedef struct cid_font {
62
 
            char               *vm_start;
63
 
            int                spacerangecnt;
64
 
            int                notdefrangecnt;
65
 
            int                cidrangecnt;
66
 
            spacerange         *spacerangeP;
67
 
            cidrange           *notdefrangeP;
68
 
            cidrange           *cidrangeP;
69
 
            int                binarydata; /* 1=binary data, 0=hex data */
70
 
            long               bytecnt;
71
 
            psobj              CIDFontFileName;
72
 
            psdict             *CIDfontInfoP;
73
 
} cidfont;
74
 
 
75
 
/* Definition of a PostScript CMap resource */
76
 
typedef struct cmap_res {
77
 
            unsigned short firstCol;
78
 
            unsigned short lastCol;
79
 
            unsigned short firstRow;
80
 
            unsigned short lastRow;
81
 
            psobj   CMapFileName;
82
 
            psdict  *CMapInfoP;
83
 
} cmapres;
84
 
#endif
 
38
#include "util.h"
85
39
 
86
40
/*     Definition of a PostScript FONT             */
87
41
typedef struct ps_font {
98
52
/***================================================================***/
99
53
 
100
54
extern boolean Init_BuiltInEncoding ( void );
101
 
#if XFONT_CID
102
 
extern int scan_cidfont ( cidfont *CIDFontP, cmapres *CMapP );
103
 
extern int scan_cidtype1font ( psfont *FontP );
104
 
#endif
105
55
extern int scan_font ( psfont *FontP );
106
56
/***================================================================***/
107
57
/*  Return codes from scan_font                                       */
115
65
#define SCAN_FALSE           -6
116
66
#define SCAN_END             -7
117
67
 
118
 
#if XFONT_CID
119
 
/***================================================================***/
120
 
/*  Name of CID FontInfo fields                                       */
121
 
/***================================================================***/
122
 
#define CIDCOUNT 1
123
 
#define CIDFONTNAME 2
124
 
#define CIDFONTTYPE 3
125
 
#define CIDVERSION 4
126
 
#define CIDREGISTRY 5
127
 
#define CIDORDERING 6
128
 
#define CIDSUPPLEMENT 7
129
 
#define CIDMAPOFFSET 8
130
 
#define CIDFDARRAY 9
131
 
#define CIDFDBYTES 10
132
 
#define CIDFONTBBOX 11
133
 
#define CIDFULLNAME 12
134
 
#define CIDFAMILYNAME 13
135
 
#define CIDWEIGHT 14
136
 
#define CIDNOTICE 15
137
 
#define CIDGDBYTES 16
138
 
#define CIDUIDBASE 17
139
 
#define CIDXUID 18
140
 
 
141
 
/***================================================================***/
142
 
/*  Name of CMapInfo fields                                           */
143
 
/***================================================================***/
144
 
#define CMAPREGISTRY 1
145
 
#define CMAPORDERING 2
146
 
#define CMAPSUPPLEMENT 3
147
 
#define CMAPNAME 4
148
 
#define CMAPVERSION 5
149
 
#define CMAPTYPE 6
150
 
#define CMAPWMODE 7
151
 
#define CMAPCIDCOUNT 8
152
 
#endif
153
 
 
154
68
/***================================================================***/
155
69
/*  Name of FontInfo fields                                           */
156
70
/***================================================================***/
192
106
#define RNDSTEMUP 15
193
107
#define EXPANSIONFACTOR 16
194
108
 
195
 
#if XFONT_CID
196
 
/***================================================================***/
197
 
/*  Name of CID Type 1 Private values                                 */
198
 
/***================================================================***/
199
 
#define CIDT1MINFEATURE     1
200
 
#define CIDT1LENIV          2
201
 
#define CIDT1LANGGROUP      3
202
 
#define CIDT1BLUEVALUES     4
203
 
#define CIDT1OTHERBLUES     5
204
 
#define CIDT1BLUESCALE      6
205
 
#define CIDT1BLUEFUZZ       7
206
 
#define CIDT1BLUESHIFT      8
207
 
#define CIDT1FAMBLUES       9
208
 
#define CIDT1FAMOTHERBLUES 10
209
 
#define CIDT1STDHW         11
210
 
#define CIDT1STDVW         12
211
 
#define CIDT1STEMSNAPH     13
212
 
#define CIDT1STEMSNAPV     14
213
 
#define CIDT1SUBMAPOFF     15
214
 
#define CIDT1SDBYTES       16
215
 
#define CIDT1SUBRCNT       17
216
 
#define CIDT1FORCEBOLD     18
217
 
#define CIDT1RNDSTEMUP     19
218
 
#define CIDT1EXPFACTOR     20
219
 
 
220
 
#define CID_BITMAP_UNDEFINED       0
221
109
extern int SearchDictName ( psdict *dictP, psobj *keyP );
222
 
#if XFONT_CID
223
 
extern boolean initCIDType1Font ( void );
224
 
#endif
225
110
extern boolean initFont ( int cnt );
226
 
#if XFONT_CID
227
 
extern int readCIDFont ( char *cidfontname, char *cmapfile );
228
 
extern int readCIDType1Font ( void );
229
 
#endif
230
111
extern int readFont ( char *env );
231
112
extern struct xobject *fontfcnB ( struct XYspace *S, unsigned char *code, 
232
 
                                  int *lenP, int *mode );
233
 
#if XFONT_CID
234
 
extern Bool CIDfontfcnA ( char *cidfontname, char *cmapfile, int *mode );
235
 
extern Bool CIDType1fontfcnA ( int *mode );
236
 
#endif
 
113
                                  int *lenP, int *mode );
237
114
extern Bool fontfcnA ( char *env, int *mode );
238
 
#if XFONT_CID
239
 
extern void CIDQueryFontLib ( char *cidfontname, char *cmapfile, 
240
 
                              char *infoName, pointer infoValue, int *rcodeP );
241
 
#endif
242
115
extern void QueryFontLib ( char *env, char *infoName, pointer infoValue, 
243
 
                           int *rcodeP );
244
 
#if XFONT_CID
245
 
extern struct xobject *CIDfontfcnC ( struct XYspace *S, psobj *theStringP, 
246
 
                                     psobj *SubrsArrayP,
247
 
                                     struct blues_struct *BluesP, int *lenP, 
248
 
                                     int *mode );
249
 
#endif
250
 
#endif
 
116
                           int *rcodeP );