Added YUV routines needed for v4l driver, and in the future possibly
[wine/gsoc-2012-control.git] / dlls / wineps / psdrv.h
blobf50f995b23d5a34e88f69b306c41928fd793d3dc
1 /*
2 * PostScript driver definitions
4 * Copyright 1998 Huw D M Davies
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
21 #ifndef __WINE_PSDRV_H
22 #define __WINE_PSDRV_H
24 #include <stdarg.h>
26 #include "windef.h"
27 #include "winbase.h"
28 #include "wingdi.h"
29 #include "wine/wingdi16.h"
30 #include "winspool.h"
32 typedef struct {
33 INT index;
34 LPCSTR sz;
35 } GLYPHNAME;
37 typedef struct {
38 LONG UV;
39 const GLYPHNAME *name;
40 } UNICODEGLYPH;
42 typedef struct {
43 float llx, lly, urx, ury;
44 } AFMBBOX;
46 typedef struct _tagAFMLIGS {
47 char *successor;
48 char *ligature;
49 struct _tagAFMLIGS *next;
50 } AFMLIGS;
52 typedef struct {
53 int C; /* character */
54 LONG UV;
55 float WX;
56 const GLYPHNAME *N; /* name */
57 AFMBBOX B;
58 const AFMLIGS *L; /* Ligatures */
59 } OLD_AFMMETRICS;
61 typedef struct {
62 INT C; /* AFM encoding (or -1) */
63 LONG UV; /* Unicode value */
64 FLOAT WX; /* Advance width */
65 const GLYPHNAME *N; /* Glyph name */
66 } AFMMETRICS;
68 typedef struct {
69 USHORT usUnitsPerEm; /* head:unitsPerEm */
70 SHORT sAscender; /* hhea:Ascender */
71 SHORT sDescender; /* hhea:Descender */
72 SHORT sLineGap; /* hhea:LineGap */
73 SHORT sAvgCharWidth; /* OS/2:xAvgCharWidth */
74 SHORT sTypoAscender; /* OS/2:sTypoAscender */
75 SHORT sTypoDescender; /* OS/2:sTypoDescender */
76 SHORT sTypoLineGap; /* OS/2:sTypeLineGap */
77 USHORT usWinAscent; /* OS/2:usWinAscent */
78 USHORT usWinDescent; /* OS/2:usWinDescent */
79 } WINMETRICS;
81 typedef struct _tagAFM {
82 LPCSTR FontName;
83 LPCSTR FullName;
84 LPCSTR FamilyName;
85 LPCSTR EncodingScheme;
86 LONG Weight; /* FW_NORMAL etc. */
87 float ItalicAngle;
88 BOOL IsFixedPitch;
89 float UnderlinePosition;
90 float UnderlineThickness;
91 AFMBBOX FontBBox;
92 float Ascender;
93 float Descender;
94 WINMETRICS WinMetrics;
95 int NumofMetrics;
96 const AFMMETRICS *Metrics;
97 } AFM;
99 /* Note no 'next' in AFM. Use AFMLISTENTRY as a container. This allow more than
100 one list to exist without having to reallocate the entire AFM structure. We
101 keep a global list of all afms (PSDRV_AFMFontList) plus a list of available
102 fonts for each DC (dc->physDev->Fonts) */
104 typedef struct _tagAFMLISTENTRY {
105 const AFM *afm;
106 struct _tagAFMLISTENTRY *next;
107 } AFMLISTENTRY;
109 typedef struct _tagFONTFAMILY {
110 char *FamilyName; /* family name */
111 AFMLISTENTRY *afmlist; /* list of afms for this family */
112 struct _tagFONTFAMILY *next; /* next family */
113 } FONTFAMILY;
115 extern FONTFAMILY *PSDRV_AFMFontList;
116 extern const AFM *const PSDRV_BuiltinAFMs[]; /* last element is NULL */
118 typedef struct _tagFONTNAME {
119 char *Name;
120 struct _tagFONTNAME *next;
121 } FONTNAME;
123 typedef struct {
124 float llx, lly, urx, ury;
125 } IMAGEABLEAREA;
127 typedef struct {
128 float x, y;
129 } PAPERDIMENSION;
131 /* Solaris kludge */
132 #undef PAGESIZE
133 typedef struct _tagPAGESIZE {
134 char *Name;
135 char *FullName;
136 char *InvocationString;
137 IMAGEABLEAREA *ImageableArea;
138 PAPERDIMENSION *PaperDimension;
139 WORD WinPage; /*eg DMPAPER_A4. Doesn't really belong here */
140 struct _tagPAGESIZE *next;
141 } PAGESIZE;
144 typedef struct _tagOPTIONENTRY {
145 char *Name; /* eg "True" */
146 char *FullName; /* eg "Installed" */
147 char *InvocationString; /* Often NULL */
148 struct _tagOPTIONENTRY *next;
149 } OPTIONENTRY;
151 typedef struct _tagOPTION { /* Treat bool as a special case of pickone */
152 char *OptionName; /* eg "*Option1" */
153 char *FullName; /* eg "Envelope Feeder" */
154 char *DefaultOption; /* eg "False" */
155 OPTIONENTRY *Options;
156 struct _tagOPTION *next;
157 } OPTION;
159 typedef struct _tagCONSTRAINT {
160 char *Feature1;
161 char *Value1;
162 char *Feature2;
163 char *Value2;
164 struct _tagCONSTRAINT *next;
165 } CONSTRAINT;
167 typedef struct _tagINPUTSLOT {
168 char *Name;
169 char *FullName;
170 char *InvocationString;
171 WORD WinBin; /* eg DMBIN_LOWER */
172 struct _tagINPUTSLOT *next;
173 } INPUTSLOT;
175 typedef enum _RASTERIZEROPTION
176 {RO_None, RO_Accept68K, RO_Type42, RO_TrueImage} RASTERIZEROPTION;
178 typedef struct _tagDUPLEX {
179 char *Name;
180 char *FullName;
181 char *InvocationString;
182 WORD WinDuplex; /* eg DMDUP_SIMPLEX */
183 struct _tagDUPLEX *next;
184 } DUPLEX;
186 typedef struct {
187 char *NickName;
188 int LanguageLevel;
189 BOOL ColorDevice;
190 int DefaultResolution;
191 signed int LandscapeOrientation;
192 char *JCLBegin;
193 char *JCLToPSInterpreter;
194 char *JCLEnd;
195 char *DefaultFont;
196 FONTNAME *InstalledFonts; /* ptr to a list of FontNames */
197 PAGESIZE *PageSizes;
198 PAGESIZE *DefaultPageSize;
199 OPTION *InstalledOptions;
200 CONSTRAINT *Constraints;
201 INPUTSLOT *InputSlots;
202 RASTERIZEROPTION TTRasterizer;
203 DUPLEX *Duplexes;
204 DUPLEX *DefaultDuplex;
205 } PPD;
207 typedef struct {
208 DEVMODEA dmPublic;
209 struct _tagdocprivate {
210 int dummy;
211 } dmDocPrivate;
212 struct _tagdrvprivate {
213 UINT numInstalledOptions; /* Options at end of struct */
214 } dmDrvPrivate;
216 /* Now comes:
218 numInstalledOptions of OPTIONs
222 } PSDRV_DEVMODEA;
224 typedef struct _tagPI {
225 char *FriendlyName;
226 PPD *ppd;
227 PSDRV_DEVMODEA *Devmode;
228 FONTFAMILY *Fonts;
229 PPRINTER_ENUM_VALUESA FontSubTable;
230 DWORD FontSubTableSize;
231 struct _tagPI *next;
232 } PRINTERINFO;
234 typedef struct {
235 float r, g, b;
236 } PSRGB;
238 typedef struct {
239 float i;
240 } PSGRAY;
243 /* def's for PSCOLOR.type */
244 #define PSCOLOR_GRAY 0
245 #define PSCOLOR_RGB 1
247 typedef struct {
248 int type;
249 union {
250 PSRGB rgb;
251 PSGRAY gray;
252 } value;
253 } PSCOLOR;
255 typedef struct {
256 const AFM *afm;
257 float scale;
258 TEXTMETRICW tm;
259 } BUILTIN;
261 typedef struct tagTYPE42 TYPE42;
263 typedef struct tagTYPE1 TYPE1;
265 enum downloadtype {
266 Type1, Type42
269 typedef struct _tagDOWNLOAD {
270 enum downloadtype type;
271 union {
272 TYPE1 *Type1;
273 TYPE42 *Type42;
274 } typeinfo;
275 char *ps_name;
276 struct _tagDOWNLOAD *next;
277 } DOWNLOAD;
279 enum fontloc {
280 Builtin, Download
283 typedef struct {
284 enum fontloc fontloc;
285 union {
286 BUILTIN Builtin;
287 DOWNLOAD *Download;
288 } fontinfo;
290 int size;
291 PSCOLOR color;
292 BOOL set; /* Have we done a setfont yet */
294 /* These are needed by PSDRV_ExtTextOut */
295 int escapement;
296 int underlineThickness;
297 int underlinePosition;
298 int strikeoutThickness;
299 int strikeoutPosition;
301 } PSFONT;
303 typedef struct {
304 PSCOLOR color;
305 BOOL set;
306 } PSBRUSH;
308 typedef struct {
309 INT style;
310 INT width;
311 const char* dash;
312 PSCOLOR color;
313 BOOL set;
314 } PSPEN;
316 typedef struct {
317 HANDLE16 hJob;
318 LPSTR output; /* Output file/port */
319 LPSTR DocName; /* Document Name */
320 BOOL banding; /* Have we received a NEXTBAND */
321 BOOL OutOfPage; /* Page header not sent yet */
322 INT PageNo;
323 BOOL quiet; /* Don't actually output anything */
324 BOOL in_passthrough; /* In PASSTHROUGH mode */
325 BOOL had_passthrough_rect; /* See the comment in PSDRV_Rectangle */
326 } JOB;
328 typedef struct {
329 HDC hdc;
330 PSFONT font; /* Current PS font */
331 DOWNLOAD *downloaded_fonts;
332 PSPEN pen;
333 PSBRUSH brush;
334 PSCOLOR bkColor;
335 PSCOLOR inkColor; /* Last colour set */
336 JOB job;
337 PSDRV_DEVMODEA *Devmode;
338 PRINTERINFO *pi;
339 SIZE PageSize; /* Physical page size in device units */
340 RECT ImageableArea; /* Imageable area in device units */
341 /* NB both PageSize and ImageableArea
342 are not rotated in landscape mode,
343 so PageSize.cx is generally
344 < PageSize.cy */
345 int horzRes; /* device caps */
346 int vertRes;
347 int horzSize;
348 int vertSize;
349 int logPixelsX;
350 int logPixelsY;
352 int pathdepth;
353 } PSDRV_PDEVICE;
355 typedef struct {
356 PRINTERINFO *pi;
357 PSDRV_DEVMODEA *dlgdm;
358 } PSDRV_DLGINFO;
362 * Every glyph name in the Adobe Glyph List and the 35 core PostScript fonts
365 extern const INT PSDRV_AGLGlyphNamesSize;
366 extern GLYPHNAME PSDRV_AGLGlyphNames[];
370 * The AGL encoding vector
373 extern const INT PSDRV_AGLbyNameSize; /* sorted by name - */
374 extern const UNICODEGLYPH PSDRV_AGLbyName[]; /* duplicates omitted */
376 extern const INT PSDRV_AGLbyUVSize; /* sorted by UV - */
377 extern const UNICODEGLYPH PSDRV_AGLbyUV[]; /* duplicates included */
380 extern INT16 WINAPI PSDRV_ExtDeviceMode16(HWND16 hwnd, HANDLE16 hDriver,
381 LPDEVMODEA lpdmOutput, LPSTR lpszDevice, LPSTR lpszPort,
382 LPDEVMODEA lpdmInput, LPSTR lpszProfile, WORD fwMode);
384 extern HINSTANCE PSDRV_hInstance;
385 extern HANDLE PSDRV_Heap;
386 extern char *PSDRV_ANSIVector[256];
388 extern void PSDRV_MergeDevmodes(PSDRV_DEVMODEA *dm1, PSDRV_DEVMODEA *dm2,
389 PRINTERINFO *pi);
390 extern BOOL PSDRV_GetFontMetrics(void);
391 extern PPD *PSDRV_ParsePPD(char *fname);
392 extern PRINTERINFO *PSDRV_FindPrinterInfo(LPCSTR name);
393 extern const AFM *PSDRV_FindAFMinList(FONTFAMILY *head, LPCSTR name);
394 extern BOOL PSDRV_AddAFMtoList(FONTFAMILY **head, const AFM *afm,
395 BOOL *p_added);
396 extern void PSDRV_FreeAFMList( FONTFAMILY *head );
398 extern INT PSDRV_XWStoDS( PSDRV_PDEVICE *physDev, INT width );
399 extern INT PSDRV_YWStoDS( PSDRV_PDEVICE *physDev, INT height );
401 extern BOOL PSDRV_Brush(PSDRV_PDEVICE *physDev, BOOL EO);
402 extern BOOL PSDRV_SetFont( PSDRV_PDEVICE *physDev );
403 extern BOOL PSDRV_SetPen( PSDRV_PDEVICE *physDev );
405 extern void PSDRV_SetClip(PSDRV_PDEVICE* phyDev);
406 extern void PSDRV_ResetClip(PSDRV_PDEVICE* phyDev);
408 extern BOOL PSDRV_CmpColor(PSCOLOR *col1, PSCOLOR *col2);
409 extern BOOL PSDRV_CopyColor(PSCOLOR *col1, PSCOLOR *col2);
410 extern void PSDRV_CreateColor( PSDRV_PDEVICE *physDev, PSCOLOR *pscolor,
411 COLORREF wincolor );
412 extern char PSDRV_UnicodeToANSI(int u);
414 extern INT PSDRV_WriteHeader( PSDRV_PDEVICE *physDev, LPCSTR title );
415 extern INT PSDRV_WriteFooter( PSDRV_PDEVICE *physDev );
416 extern INT PSDRV_WriteNewPage( PSDRV_PDEVICE *physDev );
417 extern INT PSDRV_WriteEndPage( PSDRV_PDEVICE *physDev );
418 extern BOOL PSDRV_WriteMoveTo(PSDRV_PDEVICE *physDev, INT x, INT y);
419 extern BOOL PSDRV_WriteLineTo(PSDRV_PDEVICE *physDev, INT x, INT y);
420 extern BOOL PSDRV_WriteStroke(PSDRV_PDEVICE *physDev);
421 extern BOOL PSDRV_WriteRectangle(PSDRV_PDEVICE *physDev, INT x, INT y, INT width,
422 INT height);
423 extern BOOL PSDRV_WriteRRectangle(PSDRV_PDEVICE *physDev, INT x, INT y, INT width,
424 INT height);
425 extern BOOL PSDRV_WriteSetFont(PSDRV_PDEVICE *physDev, const char *name, INT size,
426 INT escapement);
427 extern BOOL PSDRV_WriteGlyphShow(PSDRV_PDEVICE *physDev, LPCSTR g_name);
428 extern BOOL PSDRV_WriteSetPen(PSDRV_PDEVICE *physDev);
429 extern BOOL PSDRV_WriteArc(PSDRV_PDEVICE *physDev, INT x, INT y, INT w, INT h,
430 double ang1, double ang2);
431 extern BOOL PSDRV_WriteSetColor(PSDRV_PDEVICE *physDev, PSCOLOR *color);
432 extern BOOL PSDRV_WriteSetBrush(PSDRV_PDEVICE *physDev);
433 extern BOOL PSDRV_WriteFill(PSDRV_PDEVICE *physDev);
434 extern BOOL PSDRV_WriteEOFill(PSDRV_PDEVICE *physDev);
435 extern BOOL PSDRV_WriteGSave(PSDRV_PDEVICE *physDev);
436 extern BOOL PSDRV_WriteGRestore(PSDRV_PDEVICE *physDev);
437 extern BOOL PSDRV_WriteNewPath(PSDRV_PDEVICE *physDev);
438 extern BOOL PSDRV_WriteClosePath(PSDRV_PDEVICE *physDev);
439 extern BOOL PSDRV_WriteInitClip(PSDRV_PDEVICE *physDev);
440 extern BOOL PSDRV_WriteClip(PSDRV_PDEVICE *physDev);
441 extern BOOL PSDRV_WriteRectClip(PSDRV_PDEVICE *physDev, INT x, INT y, INT w, INT h);
442 extern BOOL PSDRV_WriteRectClip2(PSDRV_PDEVICE *physDev, CHAR *pszArrayName);
443 extern BOOL PSDRV_WriteEOClip(PSDRV_PDEVICE *physDev);
444 extern BOOL PSDRV_WriteHatch(PSDRV_PDEVICE *physDev);
445 extern BOOL PSDRV_WriteRotate(PSDRV_PDEVICE *physDev, float ang);
446 extern BOOL PSDRV_WriteIndexColorSpaceBegin(PSDRV_PDEVICE *physDev, int size);
447 extern BOOL PSDRV_WriteIndexColorSpaceEnd(PSDRV_PDEVICE *physDev);
448 extern BOOL PSDRV_WriteRGB(PSDRV_PDEVICE *physDev, COLORREF *map, int number);
449 extern BOOL PSDRV_WriteImage(PSDRV_PDEVICE *physDev, WORD depth, INT xDst, INT yDst,
450 INT widthDst, INT heightDst, INT widthSrc,
451 INT heightSrc, BOOL mask);
452 extern BOOL PSDRV_WriteBytes(PSDRV_PDEVICE *physDev, const BYTE *bytes, DWORD number);
453 extern BOOL PSDRV_WriteData(PSDRV_PDEVICE *physDev, const BYTE *byte, DWORD number);
454 extern DWORD PSDRV_WriteSpool(PSDRV_PDEVICE *physDev, LPCSTR lpData, DWORD cch);
455 extern BOOL PSDRV_WritePatternDict(PSDRV_PDEVICE *physDev, BITMAP *bm, BYTE *bits);
456 extern BOOL PSDRV_WriteDIBPatternDict(PSDRV_PDEVICE *physDev, BITMAPINFO *bmi, UINT usage);
457 extern BOOL PSDRV_WriteArrayPut(PSDRV_PDEVICE *physDev, CHAR *pszArrayName, INT nIndex, LONG lCoord);
458 extern BOOL PSDRV_WriteArrayDef(PSDRV_PDEVICE *physDev, CHAR *pszArrayName, INT nSize);
460 extern BOOL PSDRV_Arc( PSDRV_PDEVICE *physDev, INT left, INT top, INT right,
461 INT bottom, INT xstart, INT ystart,
462 INT xend, INT yend );
463 extern BOOL PSDRV_Chord( PSDRV_PDEVICE *physDev, INT left, INT top, INT right,
464 INT bottom, INT xstart, INT ystart,
465 INT xend, INT yend );
466 extern BOOL PSDRV_Ellipse( PSDRV_PDEVICE *physDev, INT left, INT top, INT right,
467 INT bottom );
468 extern INT PSDRV_EndDoc( PSDRV_PDEVICE *physDev );
469 extern INT PSDRV_EndPage( PSDRV_PDEVICE *physDev );
470 extern BOOL PSDRV_ExtTextOut( PSDRV_PDEVICE *physDev, INT x, INT y, UINT flags,
471 const RECT *lprect, LPCWSTR str, UINT count,
472 const INT *lpDx, INT breakExtra );
473 extern BOOL PSDRV_GetCharWidth( PSDRV_PDEVICE *physDev, UINT firstChar, UINT lastChar,
474 LPINT buffer );
475 extern BOOL PSDRV_GetTextExtentPoint( PSDRV_PDEVICE *physDev, LPCWSTR str, INT count,
476 LPSIZE size );
477 extern BOOL PSDRV_GetTextMetrics( PSDRV_PDEVICE *physDev, TEXTMETRICW *metrics );
478 extern BOOL PSDRV_LineTo( PSDRV_PDEVICE *physDev, INT x, INT y );
479 extern BOOL PSDRV_PatBlt( PSDRV_PDEVICE *physDev, INT x, INT y, INT width, INT height, DWORD
480 dwRop);
481 extern BOOL PSDRV_Pie( PSDRV_PDEVICE *physDev, INT left, INT top, INT right,
482 INT bottom, INT xstart, INT ystart,
483 INT xend, INT yend );
484 extern BOOL PSDRV_Polygon( PSDRV_PDEVICE *physDev, const POINT* pt, INT count );
485 extern BOOL PSDRV_Polyline( PSDRV_PDEVICE *physDev, const POINT* pt, INT count );
486 extern BOOL PSDRV_PolyPolygon( PSDRV_PDEVICE *physDev, const POINT* pts, const INT* counts,
487 UINT polygons );
488 extern BOOL PSDRV_PolyPolyline( PSDRV_PDEVICE *physDev, const POINT* pts, const DWORD* counts,
489 DWORD polylines );
490 extern BOOL PSDRV_Rectangle( PSDRV_PDEVICE *physDev, INT left, INT top, INT right,
491 INT bottom );
492 extern BOOL PSDRV_RoundRect(PSDRV_PDEVICE *physDev, INT left, INT top, INT right,
493 INT bottom, INT ell_width, INT ell_height);
494 extern COLORREF PSDRV_SetBkColor( PSDRV_PDEVICE *physDev, COLORREF color );
495 extern COLORREF PSDRV_SetPixel( PSDRV_PDEVICE *physDev, INT x, INT y, COLORREF color );
496 extern COLORREF PSDRV_SetTextColor( PSDRV_PDEVICE *physDev, COLORREF color );
497 extern INT PSDRV_StartDoc( PSDRV_PDEVICE *physDev, const DOCINFOW *doc );
498 extern INT PSDRV_StartPage( PSDRV_PDEVICE *physDev );
499 extern INT PSDRV_StretchDIBits( PSDRV_PDEVICE *physDev, INT xDst, INT yDst,
500 INT widthDst, INT heightDst, INT xSrc,
501 INT ySrc, INT widthSrc, INT heightSrc,
502 const void *bits, const BITMAPINFO *info,
503 UINT wUsage, DWORD dwRop );
505 extern INT PSDRV_ExtDeviceMode(LPSTR lpszDriver, HWND hwnd,
506 LPDEVMODEA lpdmOutput,
507 LPSTR lpszDevice, LPSTR lpszPort,
508 LPDEVMODEA lpdmInput, LPSTR lpszProfile,
509 DWORD dwMode);
510 extern DWORD PSDRV_DeviceCapabilities(LPSTR lpszDriver, LPCSTR lpszDevice,
511 LPCSTR lpszPort,
512 WORD fwCapability, LPSTR lpszOutput,
513 LPDEVMODEA lpdm);
514 INT PSDRV_GlyphListInit(void);
515 const GLYPHNAME *PSDRV_GlyphName(LPCSTR szName);
516 VOID PSDRV_IndexGlyphList(void);
517 BOOL PSDRV_GetTrueTypeMetrics(void);
518 BOOL PSDRV_GetType1Metrics(void);
519 const AFMMETRICS *PSDRV_UVMetrics(LONG UV, const AFM *afm);
520 SHORT PSDRV_CalcAvgCharWidth(const AFM *afm);
522 extern BOOL PSDRV_SelectBuiltinFont(PSDRV_PDEVICE *physDev, HFONT hfont,
523 LOGFONTW *plf, LPSTR FaceName);
524 extern BOOL PSDRV_WriteSetBuiltinFont(PSDRV_PDEVICE *physDev);
525 extern BOOL PSDRV_WriteBuiltinGlyphShow(PSDRV_PDEVICE *physDev, LPCWSTR str, INT count);
527 extern BOOL PSDRV_SelectDownloadFont(PSDRV_PDEVICE *physDev);
528 extern BOOL PSDRV_WriteSetDownloadFont(PSDRV_PDEVICE *physDev);
529 extern BOOL PSDRV_WriteDownloadGlyphShow(PSDRV_PDEVICE *physDev, WORD *glpyhs,
530 UINT count);
531 extern BOOL PSDRV_EmptyDownloadList(PSDRV_PDEVICE *physDev, BOOL write_undef);
533 #define MAX_G_NAME 31 /* max length of PS glyph name */
534 extern void get_glyph_name(HDC hdc, WORD index, char *name);
536 extern TYPE1 *T1_download_header(PSDRV_PDEVICE *physDev, char *ps_name,
537 RECT *bbox, UINT emsize);
538 extern BOOL T1_download_glyph(PSDRV_PDEVICE *physDev, DOWNLOAD *pdl,
539 DWORD index, char *glyph_name);
540 extern void T1_free(TYPE1 *t1);
542 extern TYPE42 *T42_download_header(PSDRV_PDEVICE *physDev, char *ps_name,
543 RECT *bbox, UINT emsize);
544 extern BOOL T42_download_glyph(PSDRV_PDEVICE *physDev, DOWNLOAD *pdl,
545 DWORD index, char *glyph_name);
546 extern void T42_free(TYPE42 *t42);
548 extern DWORD RLE_encode(BYTE *in_buf, DWORD len, BYTE *out_buf);
549 extern DWORD ASCII85_encode(BYTE *in_buf, DWORD len, BYTE *out_buf);
551 #define push_lc_numeric(x) do { \
552 const char *tmplocale = setlocale(LC_NUMERIC,NULL); \
553 setlocale(LC_NUMERIC,x);
555 #define pop_lc_numeric() \
556 setlocale(LC_NUMERIC,tmplocale); \
557 } while (0)
560 #endif