1 /****************************************************************************
2 **
3 **  grxprint.h : Output of graphics on printer from GRX graphic library
4 **  Version 0.5 (beta)   98/01/26   Andris Pavenis (pavenis@acad.latnet.lv)
5 **
6 **  Version 0.6          98/03/03   A.Pavenis
7 **                       Renamed some procedures
8 **
9 **  Version 0.66         98/05/07   H.Schirmer
10 **         - made cpp # start on first column
11 **
12 **  Version 0.67         98/05/10   H.Schirmer
13 **         - eleminated C++ style comments for better portability
14 **
15 **  Version 0.68         98/05/13   H.Schirmer
16 **         - clean source for better portability / ANSI-C conformance
17 **
18 **  This code is port of part of printer BGI driver
19 **  (C) 1990-1995 Ullrich von Bassewitz (see copying.uz).
20 **
21 **  Full version of printer BGI driver version 4.0 can be found
22 **  at URL   ftp://ftp.musoftware.com/pub/uz/
23 **  An alternate URL is http://www.lanet.lv/~pavenis/printerbgi+src.zip
24 **
25 *****************************************************************************/
26 
27 #ifndef __GRXPRINT_H
28 #define __GRXPRINT_H
29 
30   enum __grxPrintModes
31     {
32 	 FX_240x72              = 0,   /* EPSON FX (8-Nadel), 240 * 72 DPI */
33 	 FX_240x216             = 1,   /* EPSON FX (8-Nadel), 240 * 216 DPI */
34 	 LQ_180x180             = 2,   /* EPSON LQ (24-Nadel), 180 * 180 DPI */
35 	 LQ_360x180             = 3,   /* EPSON LQ (24-Nadel), 360 * 180 DPI */
36 	 LQ_360x360             = 4,   /* EPSON LQ (24-Nadel), 360 * 360 DPI */
37 
38 	 P6_360x360             = 5,   /* NEC P6, P6+, P60 (24-Nadel), 360 * 360 DPI (1) */
39 	 X24_180x180            = 6,   /* IBM Proprinter X24 (24-Nadel), 180 * 180 DPI */
40 	 X24_360x180            = 7,   /* IBM Proprinter X24 (24-Nadel), 360 * 180 DPI */
41 
42 	 LQ_P6_180x180x9        = 8,   /* EPSON LQ / NEC P6, P6+, 180 * 180 DPI, 9 Farben (6) */
43 	 LQ_P6_360x180x9        = 9,   /* EPSON LQ / NEC P6, P6+, 360 * 180 DPI, 9 Farben (6) */
44 	 LQ_P6_360x360x9        = 10,  /* EPSON LQ, 360 * 360 DPI, 9 Farben               (6) */
45 	 P6_360x360x9           = 11,  /* NEC P6, P6+, 360 * 360 DPI, 9 Farben            (6) */
46 
47 	 GRX_PRN_RESERVED_1     = 12,  /* Reserviert */
48 	 GRX_PRN_USER1          = 13,  /* Benutzerdefinierter Modus 1 (not implemented)   (2) */
49 	 GRX_PRN_USER2          = 14,  /* Benutzerdefinierter Modus 2 (not implemented)   (2) */
50 	 GRX_PRN_USER3          = 15,  /* Benutzerdefinierter Modus 3 (not implemented)   (2) */
51 
52 	 HPLJ_75x75             = 16,  /* HP LJ, 75 * 75 DPI                              (3) */
53 	 HPLJ_100x100           = 17,  /* HP LJ, 100 * 100 DPI                            (3) */
54 	 HPLJ_150x150           = 18,  /* HP LJ, 150 * 150 DPI                            (3) */
55 	 HPLJ_300x300           = 19,  /* HP LJ, 300 * 300 DPI                            (3) */
56 	 HPLJ_75x75_NC          = 20,  /* HP LJ, 75 * 75 DPI, keine Kompression           (4) */
57 	 HPLJ_100x100_NC        = 21,  /* HP LJ, 100 * 100 DPI, keine Kompression         (4) */
58 	 HPLJ_150x150_NC        = 22,  /* HP LJ, 150 * 150 DPI, keine Kompression         (4) */
59 	 HPLJ_300x300_NC        = 23,  /* HP LJ, 300 * 300 DPI, keine Kompression         (4) */
60 
61 	 HPDJ500C_75x75x8       = 24,  /* HP DJ 500C, 75 * 75 DPI, 8 Farben, A4 */
62 	 HPDJ500C_100x100x8     = 25,  /* HP DJ 500C, 100 * 100 DPI, 8 Farben, A4 */
63 	 HPDJ500C_150x150x8     = 26,  /* HP DJ 500C, 150 * 150 DPI, 8 Farben, A4 */
64 	 HPDJ500C_300x300x8     = 27,  /* HP DJ 500C, 300 * 300 DPI, 8 Farben, A4 */
65 
66 	 HPDJ500C_75x75x8_B     = 28,  /* HP DJ 550C, 75 * 75 DPI, 8 Farben, echtes Schwarz       (7) */
67 	 HPDJ500C_100x100x8_B   = 29,  /* HP DJ 550C, 100 * 100 DPI, 8 Farben, echtes Schwarz     (7) */
68 	 HPDJ500C_150x150x8_B   = 30,  /* HP DJ 550C, 150 * 150 DPI, 8 Farben, echtes Schwarz     (7) */
69 	 HPDJ500C_300x300x8_B   = 31,  /* HP DJ 550C, 300 * 300 DPI, 8 Farben, echtes Schwarz     (7) */
70 
71 	 HPLJ_600x600           = 32,  /* HP LJ IV, 600 * 600 DPI                                 (5) */
72 	 LQ_180x180_A3          = 33,  /* EPSON LQ (24-Nadel), 180 * 180 DPI, DIN A3 */
73 	 LQ_360x180_A3          = 34,  /* EPSON LQ (24-Nadel), 360 * 180 DPI, DIN A3 */
74 	 LQ_360x360_A3          = 35,  /* EPSON LQ (24-Nadel), 360 * 360 DPI, DIN A3 */
75 	 P7_360x360_A3          = 36,  /* NEC P7 (24-Nadel), 360 * 360 DPI, DIN A3                (1) */
76 	 LQ_180x180x9_A3        = 37,  /* EPSON LQ (24-Nadel), 180 * 180 DPI, DIN A3, 9 Farben    (6) */
77 	 LQ_360x180x9_A3        = 38,  /* EPSON LQ (24-Nadel), 360 * 180 DPI, DIN A3, 9 Farben    (6) */
78 	 LQ_360x360x9_A3        = 39,  /* EPSON LQ (24-Nadel), 360 * 360 DPI, DIN A3, 9 Farben    (6) */
79 	 P7_360x360x9_A3        = 40,  /* NEC P7 (24-Nadel), 360 * 360 DPI, DIN A3, 9 Farben    (1) (6) */
80 
81 	 HPDJ1200C150           = 41,  /* Deskjet 1200C, 256 Farben */
82 	 HPLJ_1200x1200         = 42   /* HP LJ4000, 1200 * 1200 DPI                              (5) */
83     };
84 
85 #ifdef __cplusplus
86   extern "C" {
87 #endif
88 
89   int   GrPrintSetMode (int mode);
90 
91   int   GrPrintToFile (const char * DestFile);
92 
93   int   GrDoPrinting (void);
94 
95   void  GrPrintGetAspectRatio ( unsigned * x , unsigned * y );
96 
97 
98   /******************************************************************************/
99   /*  Setting and quering some printer settings. These procedures               */
100   /*  are usufull only with LaserJet or DeskJet printers                        */
101   /******************************************************************************/
102 
103 
104   struct  GrPrintOptionsType
105 	  {
106 	      short Quality;    /* see enum __GrPrintQuality */
107 
108 	      short Shingling;  /* 0*   - normal       */
109 				/* 1    - 25% (2 pass) */
110 				/* 2    - 50% (4 pass) */
111 
112 	      short Depletion;  /* 0    - none */
113 				/* 1*   - 25%  */
114 				/* 2    - 50%  */
115 
116 	      short MediaType;  /* 0*   - plain paper       */
117 				/* 1    - bond paper        */
118 				/* 2    - special paper     */
119 				/* 3    - glossy film       */
120 				/* 4    - transparency film */
121 	  };
122 
123 
124   void    GrPrintGetDefaultOptions ( struct GrPrintOptionsType * opt );
125   void    GrPrintGetCurrentOptions ( struct GrPrintOptionsType * opt );
126   void    GrPrintSetOptions        ( struct GrPrintOptionsType * opt );
127 
128 #ifdef __cplusplus
129   };
130 #endif
131 
132 
133 #endif
134