fa03a2acfbb6752e8fbfb635691a18dd5ee13ac7
[reactos.git] / sdk / include / psdk / winspool.h
1 /**
2 * This file has no copyright assigned and is placed in the Public Domain.
3 * This file is part of the mingw-w64 runtime package.
4 * No warranty is given; refer to the file DISCLAIMER.PD within this package.
5 */
6 #ifndef _WINSPOOL_
7 #define _WINSPOOL_
8
9 #include <_mingw_unicode.h>
10
11 #ifdef _WINUSER_
12 #include <prsht.h>
13 #endif
14
15 #ifdef __cplusplus
16 extern "C" {
17 #endif
18
19 typedef struct _PRINTER_INFO_1A {
20 DWORD Flags;
21 LPSTR pDescription;
22 LPSTR pName;
23 LPSTR pComment;
24 } PRINTER_INFO_1A,*PPRINTER_INFO_1A,*LPPRINTER_INFO_1A;
25
26 typedef struct _PRINTER_INFO_1W {
27 DWORD Flags;
28 LPWSTR pDescription;
29 LPWSTR pName;
30 LPWSTR pComment;
31 } PRINTER_INFO_1W,*PPRINTER_INFO_1W,*LPPRINTER_INFO_1W;
32
33 __MINGW_TYPEDEF_AW(PRINTER_INFO_1)
34 __MINGW_TYPEDEF_AW(PPRINTER_INFO_1)
35 __MINGW_TYPEDEF_AW(LPPRINTER_INFO_1)
36
37 typedef struct _PRINTER_INFO_2A {
38 LPSTR pServerName;
39 LPSTR pPrinterName;
40 LPSTR pShareName;
41 LPSTR pPortName;
42 LPSTR pDriverName;
43 LPSTR pComment;
44 LPSTR pLocation;
45 LPDEVMODEA pDevMode;
46 LPSTR pSepFile;
47 LPSTR pPrintProcessor;
48 LPSTR pDatatype;
49 LPSTR pParameters;
50 PSECURITY_DESCRIPTOR pSecurityDescriptor;
51 DWORD Attributes;
52 DWORD Priority;
53 DWORD DefaultPriority;
54 DWORD StartTime;
55 DWORD UntilTime;
56 DWORD Status;
57 DWORD cJobs;
58 DWORD AveragePPM;
59 } PRINTER_INFO_2A,*PPRINTER_INFO_2A,*LPPRINTER_INFO_2A;
60
61 typedef struct _PRINTER_INFO_2W {
62 LPWSTR pServerName;
63 LPWSTR pPrinterName;
64 LPWSTR pShareName;
65 LPWSTR pPortName;
66 LPWSTR pDriverName;
67 LPWSTR pComment;
68 LPWSTR pLocation;
69 LPDEVMODEW pDevMode;
70 LPWSTR pSepFile;
71 LPWSTR pPrintProcessor;
72 LPWSTR pDatatype;
73 LPWSTR pParameters;
74 PSECURITY_DESCRIPTOR pSecurityDescriptor;
75 DWORD Attributes;
76 DWORD Priority;
77 DWORD DefaultPriority;
78 DWORD StartTime;
79 DWORD UntilTime;
80 DWORD Status;
81 DWORD cJobs;
82 DWORD AveragePPM;
83 } PRINTER_INFO_2W,*PPRINTER_INFO_2W,*LPPRINTER_INFO_2W;
84
85 __MINGW_TYPEDEF_AW(PRINTER_INFO_2)
86 __MINGW_TYPEDEF_AW(PPRINTER_INFO_2)
87 __MINGW_TYPEDEF_AW(LPPRINTER_INFO_2)
88
89 typedef struct _PRINTER_INFO_3 {
90 PSECURITY_DESCRIPTOR pSecurityDescriptor;
91 } PRINTER_INFO_3,*PPRINTER_INFO_3,*LPPRINTER_INFO_3;
92
93 typedef struct _PRINTER_INFO_4A {
94 LPSTR pPrinterName;
95 LPSTR pServerName;
96 DWORD Attributes;
97 } PRINTER_INFO_4A,*PPRINTER_INFO_4A,*LPPRINTER_INFO_4A;
98
99 typedef struct _PRINTER_INFO_4W {
100 LPWSTR pPrinterName;
101 LPWSTR pServerName;
102 DWORD Attributes;
103 } PRINTER_INFO_4W,*PPRINTER_INFO_4W,*LPPRINTER_INFO_4W;
104
105 __MINGW_TYPEDEF_AW(PRINTER_INFO_4)
106 __MINGW_TYPEDEF_AW(PPRINTER_INFO_4)
107 __MINGW_TYPEDEF_AW(LPPRINTER_INFO_4)
108
109 typedef struct _PRINTER_INFO_5A {
110 LPSTR pPrinterName;
111 LPSTR pPortName;
112 DWORD Attributes;
113 DWORD DeviceNotSelectedTimeout;
114 DWORD TransmissionRetryTimeout;
115 } PRINTER_INFO_5A,*PPRINTER_INFO_5A,*LPPRINTER_INFO_5A;
116
117 typedef struct _PRINTER_INFO_5W {
118 LPWSTR pPrinterName;
119 LPWSTR pPortName;
120 DWORD Attributes;
121 DWORD DeviceNotSelectedTimeout;
122 DWORD TransmissionRetryTimeout;
123 } PRINTER_INFO_5W,*PPRINTER_INFO_5W,*LPPRINTER_INFO_5W;
124
125 __MINGW_TYPEDEF_AW(PRINTER_INFO_5)
126 __MINGW_TYPEDEF_AW(PPRINTER_INFO_5)
127 __MINGW_TYPEDEF_AW(LPPRINTER_INFO_5)
128
129 typedef struct _PRINTER_INFO_6 {
130 DWORD dwStatus;
131 } PRINTER_INFO_6,*PPRINTER_INFO_6,*LPPRINTER_INFO_6;
132
133 typedef struct _PRINTER_INFO_7A {
134 LPSTR pszObjectGUID;
135 DWORD dwAction;
136 } PRINTER_INFO_7A,*PPRINTER_INFO_7A,*LPPRINTER_INFO_7A;
137
138 typedef struct _PRINTER_INFO_7W {
139 LPWSTR pszObjectGUID;
140 DWORD dwAction;
141 } PRINTER_INFO_7W,*PPRINTER_INFO_7W,*LPPRINTER_INFO_7W;
142
143 __MINGW_TYPEDEF_AW(PRINTER_INFO_7)
144 __MINGW_TYPEDEF_AW(PPRINTER_INFO_7)
145 __MINGW_TYPEDEF_AW(LPPRINTER_INFO_7)
146
147 #define DSPRINT_PUBLISH 0x00000001
148 #define DSPRINT_UPDATE 0x00000002
149 #define DSPRINT_UNPUBLISH 0x00000004
150 #define DSPRINT_REPUBLISH 0x00000008
151 #define DSPRINT_PENDING 0x80000000
152
153 typedef struct _PRINTER_INFO_8A {
154 LPDEVMODEA pDevMode;
155 } PRINTER_INFO_8A,*PPRINTER_INFO_8A,*LPPRINTER_INFO_8A;
156
157 typedef struct _PRINTER_INFO_8W {
158 LPDEVMODEW pDevMode;
159 } PRINTER_INFO_8W,*PPRINTER_INFO_8W,*LPPRINTER_INFO_8W;
160
161 __MINGW_TYPEDEF_AW(PRINTER_INFO_8)
162 __MINGW_TYPEDEF_AW(PPRINTER_INFO_8)
163 __MINGW_TYPEDEF_AW(LPPRINTER_INFO_8)
164
165 typedef struct _PRINTER_INFO_9A {
166 LPDEVMODEA pDevMode;
167 } PRINTER_INFO_9A,*PPRINTER_INFO_9A,*LPPRINTER_INFO_9A;
168
169 typedef struct _PRINTER_INFO_9W {
170 LPDEVMODEW pDevMode;
171 } PRINTER_INFO_9W,*PPRINTER_INFO_9W,*LPPRINTER_INFO_9W;
172
173 __MINGW_TYPEDEF_AW(PRINTER_INFO_9)
174 __MINGW_TYPEDEF_AW(PPRINTER_INFO_9)
175 __MINGW_TYPEDEF_AW(LPPRINTER_INFO_9)
176
177 #define PRINTER_CONTROL_PAUSE 1
178 #define PRINTER_CONTROL_RESUME 2
179 #define PRINTER_CONTROL_PURGE 3
180 #define PRINTER_CONTROL_SET_STATUS 4
181
182 #define PRINTER_STATUS_PAUSED 0x00000001
183 #define PRINTER_STATUS_ERROR 0x00000002
184 #define PRINTER_STATUS_PENDING_DELETION 0x00000004
185 #define PRINTER_STATUS_PAPER_JAM 0x00000008
186 #define PRINTER_STATUS_PAPER_OUT 0x00000010
187 #define PRINTER_STATUS_MANUAL_FEED 0x00000020
188 #define PRINTER_STATUS_PAPER_PROBLEM 0x00000040
189 #define PRINTER_STATUS_OFFLINE 0x00000080
190 #define PRINTER_STATUS_IO_ACTIVE 0x00000100
191 #define PRINTER_STATUS_BUSY 0x00000200
192 #define PRINTER_STATUS_PRINTING 0x00000400
193 #define PRINTER_STATUS_OUTPUT_BIN_FULL 0x00000800
194 #define PRINTER_STATUS_NOT_AVAILABLE 0x00001000
195 #define PRINTER_STATUS_WAITING 0x00002000
196 #define PRINTER_STATUS_PROCESSING 0x00004000
197 #define PRINTER_STATUS_INITIALIZING 0x00008000
198 #define PRINTER_STATUS_WARMING_UP 0x00010000
199 #define PRINTER_STATUS_TONER_LOW 0x00020000
200 #define PRINTER_STATUS_NO_TONER 0x00040000
201 #define PRINTER_STATUS_PAGE_PUNT 0x00080000
202 #define PRINTER_STATUS_USER_INTERVENTION 0x00100000
203 #define PRINTER_STATUS_OUT_OF_MEMORY 0x00200000
204 #define PRINTER_STATUS_DOOR_OPEN 0x00400000
205 #define PRINTER_STATUS_SERVER_UNKNOWN 0x00800000
206 #define PRINTER_STATUS_POWER_SAVE 0x01000000
207
208 #define PRINTER_ATTRIBUTE_QUEUED 0x00000001
209 #define PRINTER_ATTRIBUTE_DIRECT 0x00000002
210 #define PRINTER_ATTRIBUTE_DEFAULT 0x00000004
211 #define PRINTER_ATTRIBUTE_SHARED 0x00000008
212 #define PRINTER_ATTRIBUTE_NETWORK 0x00000010
213 #define PRINTER_ATTRIBUTE_HIDDEN 0x00000020
214 #define PRINTER_ATTRIBUTE_LOCAL 0x00000040
215
216 #define PRINTER_ATTRIBUTE_ENABLE_DEVQ 0x00000080
217 #define PRINTER_ATTRIBUTE_KEEPPRINTEDJOBS 0x00000100
218 #define PRINTER_ATTRIBUTE_DO_COMPLETE_FIRST 0x00000200
219
220 #define PRINTER_ATTRIBUTE_WORK_OFFLINE 0x00000400
221 #define PRINTER_ATTRIBUTE_ENABLE_BIDI 0x00000800
222 #define PRINTER_ATTRIBUTE_RAW_ONLY 0x00001000
223 #define PRINTER_ATTRIBUTE_PUBLISHED 0x00002000
224 #define PRINTER_ATTRIBUTE_FAX 0x00004000
225 #define PRINTER_ATTRIBUTE_TS 0x00008000
226
227 #define NO_PRIORITY 0
228 #define MAX_PRIORITY 99
229 #define MIN_PRIORITY 1
230 #define DEF_PRIORITY 1
231
232 typedef struct _JOB_INFO_1A {
233 DWORD JobId;
234 LPSTR pPrinterName;
235 LPSTR pMachineName;
236 LPSTR pUserName;
237 LPSTR pDocument;
238 LPSTR pDatatype;
239 LPSTR pStatus;
240 DWORD Status;
241 DWORD Priority;
242 DWORD Position;
243 DWORD TotalPages;
244 DWORD PagesPrinted;
245 SYSTEMTIME Submitted;
246 } JOB_INFO_1A,*PJOB_INFO_1A,*LPJOB_INFO_1A;
247
248 typedef struct _JOB_INFO_1W {
249 DWORD JobId;
250 LPWSTR pPrinterName;
251 LPWSTR pMachineName;
252 LPWSTR pUserName;
253 LPWSTR pDocument;
254 LPWSTR pDatatype;
255 LPWSTR pStatus;
256 DWORD Status;
257 DWORD Priority;
258 DWORD Position;
259 DWORD TotalPages;
260 DWORD PagesPrinted;
261 SYSTEMTIME Submitted;
262 } JOB_INFO_1W,*PJOB_INFO_1W,*LPJOB_INFO_1W;
263
264 __MINGW_TYPEDEF_AW(JOB_INFO_1)
265 __MINGW_TYPEDEF_AW(PJOB_INFO_1)
266 __MINGW_TYPEDEF_AW(LPJOB_INFO_1)
267
268 typedef struct _JOB_INFO_2A {
269 DWORD JobId;
270 LPSTR pPrinterName;
271 LPSTR pMachineName;
272 LPSTR pUserName;
273 LPSTR pDocument;
274 LPSTR pNotifyName;
275 LPSTR pDatatype;
276 LPSTR pPrintProcessor;
277 LPSTR pParameters;
278 LPSTR pDriverName;
279 LPDEVMODEA pDevMode;
280 LPSTR pStatus;
281 PSECURITY_DESCRIPTOR pSecurityDescriptor;
282 DWORD Status;
283 DWORD Priority;
284 DWORD Position;
285 DWORD StartTime;
286 DWORD UntilTime;
287 DWORD TotalPages;
288 DWORD Size;
289 SYSTEMTIME Submitted;
290 DWORD Time;
291 DWORD PagesPrinted;
292 } JOB_INFO_2A,*PJOB_INFO_2A,*LPJOB_INFO_2A;
293
294 typedef struct _JOB_INFO_2W {
295 DWORD JobId;
296 LPWSTR pPrinterName;
297 LPWSTR pMachineName;
298 LPWSTR pUserName;
299 LPWSTR pDocument;
300 LPWSTR pNotifyName;
301 LPWSTR pDatatype;
302 LPWSTR pPrintProcessor;
303 LPWSTR pParameters;
304 LPWSTR pDriverName;
305 LPDEVMODEW pDevMode;
306 LPWSTR pStatus;
307 PSECURITY_DESCRIPTOR pSecurityDescriptor;
308 DWORD Status;
309 DWORD Priority;
310 DWORD Position;
311 DWORD StartTime;
312 DWORD UntilTime;
313 DWORD TotalPages;
314 DWORD Size;
315 SYSTEMTIME Submitted;
316 DWORD Time;
317 DWORD PagesPrinted;
318 } JOB_INFO_2W,*PJOB_INFO_2W,*LPJOB_INFO_2W;
319
320 __MINGW_TYPEDEF_AW(JOB_INFO_2)
321 __MINGW_TYPEDEF_AW(PJOB_INFO_2)
322 __MINGW_TYPEDEF_AW(LPJOB_INFO_2)
323
324 typedef struct _JOB_INFO_3 {
325 DWORD JobId;
326 DWORD NextJobId;
327 DWORD Reserved;
328 } JOB_INFO_3,*PJOB_INFO_3,*LPJOB_INFO_3;
329
330 #define JOB_CONTROL_PAUSE 1
331 #define JOB_CONTROL_RESUME 2
332 #define JOB_CONTROL_CANCEL 3
333 #define JOB_CONTROL_RESTART 4
334 #define JOB_CONTROL_DELETE 5
335 #define JOB_CONTROL_SENT_TO_PRINTER 6
336 #define JOB_CONTROL_LAST_PAGE_EJECTED 7
337
338 #define JOB_STATUS_PAUSED 0x00000001
339 #define JOB_STATUS_ERROR 0x00000002
340 #define JOB_STATUS_DELETING 0x00000004
341 #define JOB_STATUS_SPOOLING 0x00000008
342 #define JOB_STATUS_PRINTING 0x00000010
343 #define JOB_STATUS_OFFLINE 0x00000020
344 #define JOB_STATUS_PAPEROUT 0x00000040
345 #define JOB_STATUS_PRINTED 0x00000080
346 #define JOB_STATUS_DELETED 0x00000100
347 #define JOB_STATUS_BLOCKED_DEVQ 0x00000200
348 #define JOB_STATUS_USER_INTERVENTION 0x00000400
349 #define JOB_STATUS_RESTART 0x00000800
350 #define JOB_STATUS_COMPLETE 0x00001000
351
352 #define JOB_POSITION_UNSPECIFIED 0
353
354 typedef struct _ADDJOB_INFO_1A {
355 LPSTR Path;
356 DWORD JobId;
357 } ADDJOB_INFO_1A,*PADDJOB_INFO_1A,*LPADDJOB_INFO_1A;
358
359 typedef struct _ADDJOB_INFO_1W {
360 LPWSTR Path;
361 DWORD JobId;
362 } ADDJOB_INFO_1W,*PADDJOB_INFO_1W,*LPADDJOB_INFO_1W;
363
364 __MINGW_TYPEDEF_AW(ADDJOB_INFO_1)
365 __MINGW_TYPEDEF_AW(PADDJOB_INFO_1)
366 __MINGW_TYPEDEF_AW(LPADDJOB_INFO_1)
367
368 typedef struct _DRIVER_INFO_1A {
369 LPSTR pName;
370 } DRIVER_INFO_1A,*PDRIVER_INFO_1A,*LPDRIVER_INFO_1A;
371
372 typedef struct _DRIVER_INFO_1W {
373 LPWSTR pName;
374 } DRIVER_INFO_1W,*PDRIVER_INFO_1W,*LPDRIVER_INFO_1W;
375
376 __MINGW_TYPEDEF_AW(DRIVER_INFO_1)
377 __MINGW_TYPEDEF_AW(PDRIVER_INFO_1)
378 __MINGW_TYPEDEF_AW(LPDRIVER_INFO_1)
379
380 typedef struct _DRIVER_INFO_2A {
381 DWORD cVersion;
382 LPSTR pName;
383 LPSTR pEnvironment;
384 LPSTR pDriverPath;
385 LPSTR pDataFile;
386 LPSTR pConfigFile;
387 } DRIVER_INFO_2A,*PDRIVER_INFO_2A,*LPDRIVER_INFO_2A;
388
389 typedef struct _DRIVER_INFO_2W {
390 DWORD cVersion;
391 LPWSTR pName;
392 LPWSTR pEnvironment;
393 LPWSTR pDriverPath;
394 LPWSTR pDataFile;
395 LPWSTR pConfigFile;
396 } DRIVER_INFO_2W,*PDRIVER_INFO_2W,*LPDRIVER_INFO_2W;
397
398 __MINGW_TYPEDEF_AW(DRIVER_INFO_2)
399 __MINGW_TYPEDEF_AW(PDRIVER_INFO_2)
400 __MINGW_TYPEDEF_AW(LPDRIVER_INFO_2)
401
402 typedef struct _DRIVER_INFO_3A {
403 DWORD cVersion;
404 LPSTR pName;
405 LPSTR pEnvironment;
406 LPSTR pDriverPath;
407 LPSTR pDataFile;
408 LPSTR pConfigFile;
409 LPSTR pHelpFile;
410 LPSTR pDependentFiles;
411 LPSTR pMonitorName;
412 LPSTR pDefaultDataType;
413 } DRIVER_INFO_3A,*PDRIVER_INFO_3A,*LPDRIVER_INFO_3A;
414
415 typedef struct _DRIVER_INFO_3W {
416 DWORD cVersion;
417 LPWSTR pName;
418 LPWSTR pEnvironment;
419 LPWSTR pDriverPath;
420 LPWSTR pDataFile;
421 LPWSTR pConfigFile;
422 LPWSTR pHelpFile;
423 LPWSTR pDependentFiles;
424 LPWSTR pMonitorName;
425 LPWSTR pDefaultDataType;
426 } DRIVER_INFO_3W,*PDRIVER_INFO_3W,*LPDRIVER_INFO_3W;
427
428 __MINGW_TYPEDEF_AW(DRIVER_INFO_3)
429 __MINGW_TYPEDEF_AW(PDRIVER_INFO_3)
430 __MINGW_TYPEDEF_AW(LPDRIVER_INFO_3)
431
432 typedef struct _DRIVER_INFO_4A {
433 DWORD cVersion;
434 LPSTR pName;
435 LPSTR pEnvironment;
436 LPSTR pDriverPath;
437 LPSTR pDataFile;
438 LPSTR pConfigFile;
439 LPSTR pHelpFile;
440 LPSTR pDependentFiles;
441 LPSTR pMonitorName;
442 LPSTR pDefaultDataType;
443 LPSTR pszzPreviousNames;
444 } DRIVER_INFO_4A,*PDRIVER_INFO_4A,*LPDRIVER_INFO_4A;
445
446 typedef struct _DRIVER_INFO_4W {
447 DWORD cVersion;
448 LPWSTR pName;
449 LPWSTR pEnvironment;
450 LPWSTR pDriverPath;
451 LPWSTR pDataFile;
452 LPWSTR pConfigFile;
453 LPWSTR pHelpFile;
454 LPWSTR pDependentFiles;
455 LPWSTR pMonitorName;
456 LPWSTR pDefaultDataType;
457 LPWSTR pszzPreviousNames;
458 } DRIVER_INFO_4W,*PDRIVER_INFO_4W,*LPDRIVER_INFO_4W;
459
460 __MINGW_TYPEDEF_AW(DRIVER_INFO_4)
461 __MINGW_TYPEDEF_AW(PDRIVER_INFO_4)
462 __MINGW_TYPEDEF_AW(LPDRIVER_INFO_4)
463
464 typedef struct _DRIVER_INFO_5A {
465 DWORD cVersion;
466 LPSTR pName;
467 LPSTR pEnvironment;
468 LPSTR pDriverPath;
469 LPSTR pDataFile;
470 LPSTR pConfigFile;
471 DWORD dwDriverAttributes;
472 DWORD dwConfigVersion;
473 DWORD dwDriverVersion;
474 } DRIVER_INFO_5A,*PDRIVER_INFO_5A,*LPDRIVER_INFO_5A;
475
476 typedef struct _DRIVER_INFO_5W {
477 DWORD cVersion;
478 LPWSTR pName;
479 LPWSTR pEnvironment;
480 LPWSTR pDriverPath;
481 LPWSTR pDataFile;
482 LPWSTR pConfigFile;
483 DWORD dwDriverAttributes;
484 DWORD dwConfigVersion;
485 DWORD dwDriverVersion;
486 } DRIVER_INFO_5W,*PDRIVER_INFO_5W,*LPDRIVER_INFO_5W;
487
488 __MINGW_TYPEDEF_AW(DRIVER_INFO_5)
489 __MINGW_TYPEDEF_AW(PDRIVER_INFO_5)
490 __MINGW_TYPEDEF_AW(LPDRIVER_INFO_5)
491
492 typedef struct _DRIVER_INFO_6A {
493 DWORD cVersion;
494 LPSTR pName;
495 LPSTR pEnvironment;
496 LPSTR pDriverPath;
497 LPSTR pDataFile;
498 LPSTR pConfigFile;
499 LPSTR pHelpFile;
500 LPSTR pDependentFiles;
501 LPSTR pMonitorName;
502 LPSTR pDefaultDataType;
503 LPSTR pszzPreviousNames;
504 FILETIME ftDriverDate;
505 DWORDLONG dwlDriverVersion;
506 LPSTR pszMfgName;
507 LPSTR pszOEMUrl;
508 LPSTR pszHardwareID;
509 LPSTR pszProvider;
510 } DRIVER_INFO_6A,*PDRIVER_INFO_6A,*LPDRIVER_INFO_6A;
511
512 typedef struct _DRIVER_INFO_6W {
513 DWORD cVersion;
514 LPWSTR pName;
515 LPWSTR pEnvironment;
516 LPWSTR pDriverPath;
517 LPWSTR pDataFile;
518 LPWSTR pConfigFile;
519 LPWSTR pHelpFile;
520 LPWSTR pDependentFiles;
521 LPWSTR pMonitorName;
522 LPWSTR pDefaultDataType;
523 LPWSTR pszzPreviousNames;
524 FILETIME ftDriverDate;
525 DWORDLONG dwlDriverVersion;
526 LPWSTR pszMfgName;
527 LPWSTR pszOEMUrl;
528 LPWSTR pszHardwareID;
529 LPWSTR pszProvider;
530 } DRIVER_INFO_6W,*PDRIVER_INFO_6W,*LPDRIVER_INFO_6W;
531
532 __MINGW_TYPEDEF_AW(DRIVER_INFO_6)
533 __MINGW_TYPEDEF_AW(PDRIVER_INFO_6)
534 __MINGW_TYPEDEF_AW(LPDRIVER_INFO_6)
535
536 typedef struct _DRIVER_INFO_8W {
537 DWORD cVersion;
538 LPWSTR pName;
539 LPWSTR pEnvironment;
540 LPWSTR pDriverPath;
541 LPWSTR pDataFile;
542 LPWSTR pConfigFile;
543 LPWSTR pHelpFile;
544 LPWSTR pDependentFiles;
545 LPWSTR pMonitorName;
546 LPWSTR pDefaultDataType;
547 LPWSTR pszzPreviousNames;
548 FILETIME ftDriverDate;
549 DWORDLONG dwlDriverVersion;
550 LPWSTR pszMfgName;
551 LPWSTR pszOEMUrl;
552 LPWSTR pszHardwareID;
553 LPWSTR pszProvider;
554 LPWSTR pszPrintProcessor;
555 LPWSTR pszVendorSetup;
556 LPWSTR pszzColorProfiles;
557 LPWSTR pszInfPath;
558 DWORD dwPrinterDriverAttributes;
559 LPWSTR pszzCoreDriverDependencies;
560 FILETIME ftMinInboxDriverVerDate;
561 DWORDLONG dwlMinInboxDriverVerVersion;
562 } DRIVER_INFO_8W, *PDRIVER_INFO_8W, *LPDRIVER_INFO_8W;
563
564 typedef struct _DRIVER_INFO_8A {
565 DWORD cVersion;
566 LPSTR pName;
567 LPSTR pEnvironment;
568 LPSTR pDriverPath;
569 LPSTR pDataFile;
570 LPSTR pConfigFile;
571 LPSTR pHelpFile;
572 LPSTR pDependentFiles;
573 LPSTR pMonitorName;
574 LPSTR pDefaultDataType;
575 LPSTR pszzPreviousNames;
576 FILETIME ftDriverDate;
577 DWORDLONG dwlDriverVersion;
578 LPSTR pszMfgName;
579 LPSTR pszOEMUrl;
580 LPSTR pszHardwareID;
581 LPSTR pszProvider;
582 LPSTR pszPrintProcessor;
583 LPSTR pszVendorSetup;
584 LPSTR pszzColorProfiles;
585 LPSTR pszInfPath;
586 DWORD dwPrinterDriverAttributes;
587 LPSTR pszzCoreDriverDependencies;
588 FILETIME ftMinInboxDriverVerDate;
589 DWORDLONG dwlMinInboxDriverVerVersion;
590 } DRIVER_INFO_8A, *PDRIVER_INFO_8A, *LPDRIVER_INFO_8A;
591
592 __MINGW_TYPEDEF_AW(DRIVER_INFO_8)
593 __MINGW_TYPEDEF_AW(PDRIVER_INFO_8)
594 __MINGW_TYPEDEF_AW(LPDRIVER_INFO_8)
595
596 #define DRIVER_KERNELMODE 0x00000001
597 #define DRIVER_USERMODE 0x00000002
598
599 #define DPD_DELETE_UNUSED_FILES 0x00000001
600 #define DPD_DELETE_SPECIFIC_VERSION 0x00000002
601 #define DPD_DELETE_ALL_FILES 0x00000004
602
603 #define APD_STRICT_UPGRADE 0x00000001
604 #define APD_STRICT_DOWNGRADE 0x00000002
605 #define APD_COPY_ALL_FILES 0x00000004
606 #define APD_COPY_NEW_FILES 0x00000008
607 #define APD_COPY_FROM_DIRECTORY 0x00000010
608
609 typedef struct _DOC_INFO_1A {
610 LPSTR pDocName;
611 LPSTR pOutputFile;
612 LPSTR pDatatype;
613 } DOC_INFO_1A,*PDOC_INFO_1A,*LPDOC_INFO_1A;
614
615 typedef struct _DOC_INFO_1W {
616 LPWSTR pDocName;
617 LPWSTR pOutputFile;
618 LPWSTR pDatatype;
619 } DOC_INFO_1W,*PDOC_INFO_1W,*LPDOC_INFO_1W;
620
621 __MINGW_TYPEDEF_AW(DOC_INFO_1)
622 __MINGW_TYPEDEF_AW(PDOC_INFO_1)
623 __MINGW_TYPEDEF_AW(LPDOC_INFO_1)
624
625 typedef struct _FORM_INFO_1A {
626 DWORD Flags;
627 LPSTR pName;
628 SIZEL Size;
629 RECTL ImageableArea;
630 } FORM_INFO_1A,*PFORM_INFO_1A,*LPFORM_INFO_1A;
631
632 typedef struct _FORM_INFO_1W {
633 DWORD Flags;
634 LPWSTR pName;
635 SIZEL Size;
636 RECTL ImageableArea;
637 } FORM_INFO_1W,*PFORM_INFO_1W,*LPFORM_INFO_1W;
638
639 __MINGW_TYPEDEF_AW(FORM_INFO_1)
640 __MINGW_TYPEDEF_AW(PFORM_INFO_1)
641 __MINGW_TYPEDEF_AW(LPFORM_INFO_1)
642
643 typedef struct _DOC_INFO_2A {
644 LPSTR pDocName;
645 LPSTR pOutputFile;
646 LPSTR pDatatype;
647 DWORD dwMode;
648 DWORD JobId;
649 } DOC_INFO_2A,*PDOC_INFO_2A,*LPDOC_INFO_2A;
650
651 typedef struct _DOC_INFO_2W {
652 LPWSTR pDocName;
653 LPWSTR pOutputFile;
654 LPWSTR pDatatype;
655 DWORD dwMode;
656 DWORD JobId;
657 } DOC_INFO_2W,*PDOC_INFO_2W,*LPDOC_INFO_2W;
658
659 __MINGW_TYPEDEF_AW(DOC_INFO_2)
660 __MINGW_TYPEDEF_AW(PDOC_INFO_2)
661 __MINGW_TYPEDEF_AW(LPDOC_INFO_2)
662
663 #define DI_CHANNEL 1
664 #define DI_READ_SPOOL_JOB 3
665
666 typedef struct _DOC_INFO_3A {
667 LPSTR pDocName;
668 LPSTR pOutputFile;
669 LPSTR pDatatype;
670 DWORD dwFlags;
671 } DOC_INFO_3A,*PDOC_INFO_3A,*LPDOC_INFO_3A;
672
673 typedef struct _DOC_INFO_3W {
674 LPWSTR pDocName;
675 LPWSTR pOutputFile;
676 LPWSTR pDatatype;
677 DWORD dwFlags;
678 } DOC_INFO_3W,*PDOC_INFO_3W,*LPDOC_INFO_3W;
679
680 __MINGW_TYPEDEF_AW(DOC_INFO_3)
681 __MINGW_TYPEDEF_AW(PDOC_INFO_3)
682 __MINGW_TYPEDEF_AW(LPDOC_INFO_3)
683
684 #define DI_MEMORYMAP_WRITE 0x00000001
685
686 #define FORM_USER 0x00000000
687 #define FORM_BUILTIN 0x00000001
688 #define FORM_PRINTER 0x00000002
689
690 typedef struct _PRINTPROCESSOR_INFO_1A {
691 LPSTR pName;
692 } PRINTPROCESSOR_INFO_1A,*PPRINTPROCESSOR_INFO_1A,*LPPRINTPROCESSOR_INFO_1A;
693
694 typedef struct _PRINTPROCESSOR_INFO_1W {
695 LPWSTR pName;
696 } PRINTPROCESSOR_INFO_1W,*PPRINTPROCESSOR_INFO_1W,*LPPRINTPROCESSOR_INFO_1W;
697
698 __MINGW_TYPEDEF_AW(PRINTPROCESSOR_INFO_1)
699 __MINGW_TYPEDEF_AW(PPRINTPROCESSOR_INFO_1)
700 __MINGW_TYPEDEF_AW(LPPRINTPROCESSOR_INFO_1)
701
702 typedef struct _PRINTPROCESSOR_CAPS_1 {
703 DWORD dwLevel;
704 DWORD dwNupOptions;
705 DWORD dwPageOrderFlags;
706 DWORD dwNumberOfCopies;
707 } PRINTPROCESSOR_CAPS_1,*PPRINTPROCESSOR_CAPS_1;
708
709 #define NORMAL_PRINT 0x00000000
710 #define REVERSE_PRINT 0x00000001
711
712 typedef struct _PORT_INFO_1A {
713 LPSTR pName;
714 } PORT_INFO_1A,*PPORT_INFO_1A,*LPPORT_INFO_1A;
715 typedef struct _PORT_INFO_1W {
716 LPWSTR pName;
717 } PORT_INFO_1W,*PPORT_INFO_1W,*LPPORT_INFO_1W;
718
719 __MINGW_TYPEDEF_AW(PORT_INFO_1)
720 __MINGW_TYPEDEF_AW(PPORT_INFO_1)
721 __MINGW_TYPEDEF_AW(LPPORT_INFO_1)
722
723 typedef struct _PORT_INFO_2A {
724 LPSTR pPortName;
725 LPSTR pMonitorName;
726 LPSTR pDescription;
727 DWORD fPortType;
728 DWORD Reserved;
729 } PORT_INFO_2A,*PPORT_INFO_2A,*LPPORT_INFO_2A;
730
731 typedef struct _PORT_INFO_2W {
732 LPWSTR pPortName;
733 LPWSTR pMonitorName;
734 LPWSTR pDescription;
735 DWORD fPortType;
736 DWORD Reserved;
737 } PORT_INFO_2W,*PPORT_INFO_2W,*LPPORT_INFO_2W;
738
739 __MINGW_TYPEDEF_AW(PORT_INFO_2)
740 __MINGW_TYPEDEF_AW(PPORT_INFO_2)
741 __MINGW_TYPEDEF_AW(LPPORT_INFO_2)
742
743 #define PORT_TYPE_WRITE 0x0001
744 #define PORT_TYPE_READ 0x0002
745 #define PORT_TYPE_REDIRECTED 0x0004
746 #define PORT_TYPE_NET_ATTACHED 0x0008
747
748 typedef struct _PORT_INFO_3A {
749 DWORD dwStatus;
750 LPSTR pszStatus;
751 DWORD dwSeverity;
752 } PORT_INFO_3A,*PPORT_INFO_3A,*LPPORT_INFO_3A;
753
754 typedef struct _PORT_INFO_3W {
755 DWORD dwStatus;
756 LPWSTR pszStatus;
757 DWORD dwSeverity;
758 } PORT_INFO_3W,*PPORT_INFO_3W,*LPPORT_INFO_3W;
759
760 __MINGW_TYPEDEF_AW(PORT_INFO_3)
761 __MINGW_TYPEDEF_AW(PPORT_INFO_3)
762 __MINGW_TYPEDEF_AW(LPPORT_INFO_3)
763
764 #define PORT_STATUS_TYPE_ERROR 1
765 #define PORT_STATUS_TYPE_WARNING 2
766 #define PORT_STATUS_TYPE_INFO 3
767
768 #define PORT_STATUS_OFFLINE 1
769 #define PORT_STATUS_PAPER_JAM 2
770 #define PORT_STATUS_PAPER_OUT 3
771 #define PORT_STATUS_OUTPUT_BIN_FULL 4
772 #define PORT_STATUS_PAPER_PROBLEM 5
773 #define PORT_STATUS_NO_TONER 6
774 #define PORT_STATUS_DOOR_OPEN 7
775 #define PORT_STATUS_USER_INTERVENTION 8
776 #define PORT_STATUS_OUT_OF_MEMORY 9
777 #define PORT_STATUS_TONER_LOW 10
778 #define PORT_STATUS_WARMING_UP 11
779 #define PORT_STATUS_POWER_SAVE 12
780
781 typedef struct _MONITOR_INFO_1A{
782 LPSTR pName;
783 } MONITOR_INFO_1A,*PMONITOR_INFO_1A,*LPMONITOR_INFO_1A;
784
785 typedef struct _MONITOR_INFO_1W{
786 LPWSTR pName;
787 } MONITOR_INFO_1W,*PMONITOR_INFO_1W,*LPMONITOR_INFO_1W;
788
789 __MINGW_TYPEDEF_AW(MONITOR_INFO_1)
790 __MINGW_TYPEDEF_AW(PMONITOR_INFO_1)
791 __MINGW_TYPEDEF_AW(LPMONITOR_INFO_1)
792
793 typedef struct _MONITOR_INFO_2A {
794 LPSTR pName;
795 LPSTR pEnvironment;
796 LPSTR pDLLName;
797 } MONITOR_INFO_2A,*PMONITOR_INFO_2A,*LPMONITOR_INFO_2A;
798
799 typedef struct _MONITOR_INFO_2W {
800 LPWSTR pName;
801 LPWSTR pEnvironment;
802 LPWSTR pDLLName;
803 } MONITOR_INFO_2W,*PMONITOR_INFO_2W,*LPMONITOR_INFO_2W;
804
805 __MINGW_TYPEDEF_AW(MONITOR_INFO_2)
806 __MINGW_TYPEDEF_AW(PMONITOR_INFO_2)
807 __MINGW_TYPEDEF_AW(LPMONITOR_INFO_2)
808
809 typedef struct _DATATYPES_INFO_1A {
810 LPSTR pName;
811 } DATATYPES_INFO_1A,*PDATATYPES_INFO_1A,*LPDATATYPES_INFO_1A;
812
813 typedef struct _DATATYPES_INFO_1W {
814 LPWSTR pName;
815 } DATATYPES_INFO_1W,*PDATATYPES_INFO_1W,*LPDATATYPES_INFO_1W;
816
817 __MINGW_TYPEDEF_AW(DATATYPES_INFO_1)
818 __MINGW_TYPEDEF_AW(PDATATYPES_INFO_1)
819 __MINGW_TYPEDEF_AW(LPDATATYPES_INFO_1)
820
821 typedef struct _PRINTER_DEFAULTSA {
822 LPSTR pDatatype;
823 LPDEVMODEA pDevMode;
824 ACCESS_MASK DesiredAccess;
825 } PRINTER_DEFAULTSA,*PPRINTER_DEFAULTSA,*LPPRINTER_DEFAULTSA;
826
827 typedef struct _PRINTER_DEFAULTSW {
828 LPWSTR pDatatype;
829 LPDEVMODEW pDevMode;
830 ACCESS_MASK DesiredAccess;
831 } PRINTER_DEFAULTSW,*PPRINTER_DEFAULTSW,*LPPRINTER_DEFAULTSW;
832
833 __MINGW_TYPEDEF_AW(PRINTER_DEFAULTS)
834 __MINGW_TYPEDEF_AW(PPRINTER_DEFAULTS)
835 __MINGW_TYPEDEF_AW(LPPRINTER_DEFAULTS)
836
837 typedef struct _PRINTER_ENUM_VALUESA {
838 LPSTR pValueName;
839 DWORD cbValueName;
840 DWORD dwType;
841 LPBYTE pData;
842 DWORD cbData;
843 } PRINTER_ENUM_VALUESA,*PPRINTER_ENUM_VALUESA,*LPPRINTER_ENUM_VALUESA;
844
845 typedef struct _PRINTER_ENUM_VALUESW {
846 LPWSTR pValueName;
847 DWORD cbValueName;
848 DWORD dwType;
849 LPBYTE pData;
850 DWORD cbData;
851 } PRINTER_ENUM_VALUESW,*PPRINTER_ENUM_VALUESW,*LPPRINTER_ENUM_VALUESW;
852
853 __MINGW_TYPEDEF_AW(PRINTER_ENUM_VALUES)
854 __MINGW_TYPEDEF_AW(PPRINTER_ENUM_VALUES)
855 __MINGW_TYPEDEF_AW(LPPRINTER_ENUM_VALUES)
856
857 #define EnumPrinters __MINGW_NAME_AW(EnumPrinters)
858
859 WINBOOL WINAPI EnumPrintersA(DWORD Flags,LPSTR Name,DWORD Level,LPBYTE pPrinterEnum,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
860 WINBOOL WINAPI EnumPrintersW(DWORD Flags,LPWSTR Name,DWORD Level,LPBYTE pPrinterEnum,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
861
862 #define PRINTER_ENUM_DEFAULT 0x00000001
863 #define PRINTER_ENUM_LOCAL 0x00000002
864 #define PRINTER_ENUM_CONNECTIONS 0x00000004
865 #define PRINTER_ENUM_FAVORITE 0x00000004
866 #define PRINTER_ENUM_NAME 0x00000008
867 #define PRINTER_ENUM_REMOTE 0x00000010
868 #define PRINTER_ENUM_SHARED 0x00000020
869 #define PRINTER_ENUM_NETWORK 0x00000040
870
871 #define PRINTER_ENUM_EXPAND 0x00004000
872 #define PRINTER_ENUM_CONTAINER 0x00008000
873
874 #define PRINTER_ENUM_ICONMASK 0x00ff0000
875 #define PRINTER_ENUM_ICON1 0x00010000
876 #define PRINTER_ENUM_ICON2 0x00020000
877 #define PRINTER_ENUM_ICON3 0x00040000
878 #define PRINTER_ENUM_ICON4 0x00080000
879 #define PRINTER_ENUM_ICON5 0x00100000
880 #define PRINTER_ENUM_ICON6 0x00200000
881 #define PRINTER_ENUM_ICON7 0x00400000
882 #define PRINTER_ENUM_ICON8 0x00800000
883 #define PRINTER_ENUM_HIDE 0x01000000
884
885 #define SPOOL_FILE_PERSISTENT 0x00000001
886 #define SPOOL_FILE_TEMPORARY 0x00000002
887
888 #define OpenPrinter __MINGW_NAME_AW(OpenPrinter)
889 #define ResetPrinter __MINGW_NAME_AW(ResetPrinter)
890 #define SetJob __MINGW_NAME_AW(SetJob)
891 #define GetJob __MINGW_NAME_AW(GetJob)
892 #define EnumJobs __MINGW_NAME_AW(EnumJobs)
893 #define AddPrinter __MINGW_NAME_AW(AddPrinter)
894 #define SetPrinter __MINGW_NAME_AW(SetPrinter)
895 #define GetPrinter __MINGW_NAME_AW(GetPrinter)
896 #define AddPrinterDriver __MINGW_NAME_AW(AddPrinterDriver)
897 #define AddPrinterDriverEx __MINGW_NAME_AW(AddPrinterDriverEx)
898 #define EnumPrinterDrivers __MINGW_NAME_AW(EnumPrinterDrivers)
899 #define GetPrinterDriver __MINGW_NAME_AW(GetPrinterDriver)
900 #define GetPrinterDriverDirectory __MINGW_NAME_AW(GetPrinterDriverDirectory)
901 #define DeletePrinterDriver __MINGW_NAME_AW(DeletePrinterDriver)
902 #define DeletePrinterDriverEx __MINGW_NAME_AW(DeletePrinterDriverEx)
903 #define AddPrintProcessor __MINGW_NAME_AW(AddPrintProcessor)
904 #define EnumPrintProcessors __MINGW_NAME_AW(EnumPrintProcessors)
905 #define GetPrintProcessorDirectory __MINGW_NAME_AW(GetPrintProcessorDirectory)
906 #define EnumPrintProcessorDatatypes __MINGW_NAME_AW(EnumPrintProcessorDatatypes)
907 #define DeletePrintProcessor __MINGW_NAME_AW(DeletePrintProcessor)
908 #define StartDocPrinter __MINGW_NAME_AW(StartDocPrinter)
909 #define AddJob __MINGW_NAME_AW(AddJob)
910 #define DocumentProperties __MINGW_NAME_AW(DocumentProperties)
911 #define AdvancedDocumentProperties __MINGW_NAME_AW(AdvancedDocumentProperties)
912 #define GetPrinterData __MINGW_NAME_AW(GetPrinterData)
913 #define GetPrinterDataEx __MINGW_NAME_AW(GetPrinterDataEx)
914 #define EnumPrinterData __MINGW_NAME_AW(EnumPrinterData)
915 #define EnumPrinterDataEx __MINGW_NAME_AW(EnumPrinterDataEx)
916 #define EnumPrinterKey __MINGW_NAME_AW(EnumPrinterKey)
917 #define SetPrinterData __MINGW_NAME_AW(SetPrinterData)
918 #define SetPrinterDataEx __MINGW_NAME_AW(SetPrinterDataEx)
919 #define DeletePrinterData __MINGW_NAME_AW(DeletePrinterData)
920 #define DeletePrinterDataEx __MINGW_NAME_AW(DeletePrinterDataEx)
921 #define DeletePrinterKey __MINGW_NAME_AW(DeletePrinterKey)
922
923 WINBOOL WINAPI OpenPrinterA(LPSTR pPrinterName,LPHANDLE phPrinter,LPPRINTER_DEFAULTSA pDefault);
924 WINBOOL WINAPI OpenPrinterW(LPWSTR pPrinterName,LPHANDLE phPrinter,LPPRINTER_DEFAULTSW pDefault);
925 WINBOOL WINAPI ResetPrinterA(HANDLE hPrinter,LPPRINTER_DEFAULTSA pDefault);
926 WINBOOL WINAPI ResetPrinterW(HANDLE hPrinter,LPPRINTER_DEFAULTSW pDefault);
927 WINBOOL WINAPI SetJobA(HANDLE hPrinter,DWORD JobId,DWORD Level,LPBYTE pJob,DWORD Command);
928 WINBOOL WINAPI SetJobW(HANDLE hPrinter,DWORD JobId,DWORD Level,LPBYTE pJob,DWORD Command);
929 WINBOOL WINAPI GetJobA(HANDLE hPrinter,DWORD JobId,DWORD Level,LPBYTE pJob,DWORD cbBuf,LPDWORD pcbNeeded);
930 WINBOOL WINAPI GetJobW(HANDLE hPrinter,DWORD JobId,DWORD Level,LPBYTE pJob,DWORD cbBuf,LPDWORD pcbNeeded);
931 WINBOOL WINAPI EnumJobsA(HANDLE hPrinter,DWORD FirstJob,DWORD NoJobs,DWORD Level,LPBYTE pJob,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
932 WINBOOL WINAPI EnumJobsW(HANDLE hPrinter,DWORD FirstJob,DWORD NoJobs,DWORD Level,LPBYTE pJob,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
933 HANDLE WINAPI AddPrinterA(LPSTR pName,DWORD Level,LPBYTE pPrinter);
934 HANDLE WINAPI AddPrinterW(LPWSTR pName,DWORD Level,LPBYTE pPrinter);
935 WINBOOL WINAPI DeletePrinter(HANDLE hPrinter);
936 WINBOOL WINAPI SetPrinterA(HANDLE hPrinter,DWORD Level,LPBYTE pPrinter,DWORD Command);
937 WINBOOL WINAPI SetPrinterW(HANDLE hPrinter,DWORD Level,LPBYTE pPrinter,DWORD Command);
938 WINBOOL WINAPI GetPrinterA(HANDLE hPrinter,DWORD Level,LPBYTE pPrinter,DWORD cbBuf,LPDWORD pcbNeeded);
939 WINBOOL WINAPI GetPrinterW(HANDLE hPrinter,DWORD Level,LPBYTE pPrinter,DWORD cbBuf,LPDWORD pcbNeeded);
940 WINBOOL WINAPI AddPrinterDriverA(LPSTR pName,DWORD Level,LPBYTE pDriverInfo);
941 WINBOOL WINAPI AddPrinterDriverW(LPWSTR pName,DWORD Level,LPBYTE pDriverInfo);
942 WINBOOL WINAPI AddPrinterDriverExA(LPSTR pName,DWORD Level,LPBYTE pDriverInfo,DWORD dwFileCopyFlags);
943 WINBOOL WINAPI AddPrinterDriverExW(LPWSTR pName,DWORD Level,LPBYTE pDriverInfo,DWORD dwFileCopyFlags);
944 WINBOOL WINAPI EnumPrinterDriversA(LPSTR pName,LPSTR pEnvironment,DWORD Level,LPBYTE pDriverInfo,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
945 WINBOOL WINAPI EnumPrinterDriversW(LPWSTR pName,LPWSTR pEnvironment,DWORD Level,LPBYTE pDriverInfo,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
946 WINBOOL WINAPI GetPrinterDriverA(HANDLE hPrinter,LPSTR pEnvironment,DWORD Level,LPBYTE pDriverInfo,DWORD cbBuf,LPDWORD pcbNeeded);
947 WINBOOL WINAPI GetPrinterDriverW(HANDLE hPrinter,LPWSTR pEnvironment,DWORD Level,LPBYTE pDriverInfo,DWORD cbBuf,LPDWORD pcbNeeded);
948 WINBOOL WINAPI GetPrinterDriverDirectoryA(LPSTR pName,LPSTR pEnvironment,DWORD Level,LPBYTE pDriverDirectory,DWORD cbBuf,LPDWORD pcbNeeded);
949 WINBOOL WINAPI GetPrinterDriverDirectoryW(LPWSTR pName,LPWSTR pEnvironment,DWORD Level,LPBYTE pDriverDirectory,DWORD cbBuf,LPDWORD pcbNeeded);
950 WINBOOL WINAPI DeletePrinterDriverA(LPSTR pName,LPSTR pEnvironment,LPSTR pDriverName);
951 WINBOOL WINAPI DeletePrinterDriverW(LPWSTR pName,LPWSTR pEnvironment,LPWSTR pDriverName);
952 WINBOOL WINAPI DeletePrinterDriverExA(LPSTR pName,LPSTR pEnvironment,LPSTR pDriverName,DWORD dwDeleteFlag,DWORD dwVersionFlag);
953 WINBOOL WINAPI DeletePrinterDriverExW(LPWSTR pName,LPWSTR pEnvironment,LPWSTR pDriverName,DWORD dwDeleteFlag,DWORD dwVersionFlag);
954 WINBOOL WINAPI AddPrintProcessorA(LPSTR pName,LPSTR pEnvironment,LPSTR pPathName,LPSTR pPrintProcessorName);
955 WINBOOL WINAPI AddPrintProcessorW(LPWSTR pName,LPWSTR pEnvironment,LPWSTR pPathName,LPWSTR pPrintProcessorName);
956 WINBOOL WINAPI EnumPrintProcessorsA(LPSTR pName,LPSTR pEnvironment,DWORD Level,LPBYTE pPrintProcessorInfo,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
957 WINBOOL WINAPI EnumPrintProcessorsW(LPWSTR pName,LPWSTR pEnvironment,DWORD Level,LPBYTE pPrintProcessorInfo,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
958 WINBOOL WINAPI GetPrintProcessorDirectoryA(LPSTR pName,LPSTR pEnvironment,DWORD Level,LPBYTE pPrintProcessorInfo,DWORD cbBuf,LPDWORD pcbNeeded);
959 WINBOOL WINAPI GetPrintProcessorDirectoryW(LPWSTR pName,LPWSTR pEnvironment,DWORD Level,LPBYTE pPrintProcessorInfo,DWORD cbBuf,LPDWORD pcbNeeded);
960 WINBOOL WINAPI EnumPrintProcessorDatatypesA(LPSTR pName,LPSTR pPrintProcessorName,DWORD Level,LPBYTE pDatatypes,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
961 WINBOOL WINAPI EnumPrintProcessorDatatypesW(LPWSTR pName,LPWSTR pPrintProcessorName,DWORD Level,LPBYTE pDatatypes,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
962 WINBOOL WINAPI DeletePrintProcessorA(LPSTR pName,LPSTR pEnvironment,LPSTR pPrintProcessorName);
963 WINBOOL WINAPI DeletePrintProcessorW(LPWSTR pName,LPWSTR pEnvironment,LPWSTR pPrintProcessorName);
964 DWORD WINAPI StartDocPrinterA(HANDLE hPrinter,DWORD Level,LPBYTE pDocInfo);
965 DWORD WINAPI StartDocPrinterW(HANDLE hPrinter,DWORD Level,LPBYTE pDocInfo);
966 WINBOOL WINAPI StartPagePrinter(HANDLE hPrinter);
967 WINBOOL WINAPI WritePrinter(HANDLE hPrinter,LPVOID pBuf,DWORD cbBuf,LPDWORD pcWritten);
968 WINBOOL WINAPI FlushPrinter(HANDLE hPrinter,LPVOID pBuf,DWORD cbBuf,LPDWORD pcWritten,DWORD cSleep);
969 WINBOOL WINAPI EndPagePrinter(HANDLE hPrinter);
970 WINBOOL WINAPI AbortPrinter(HANDLE hPrinter);
971 WINBOOL WINAPI ReadPrinter(HANDLE hPrinter,LPVOID pBuf,DWORD cbBuf,LPDWORD pNoBytesRead);
972 WINBOOL WINAPI EndDocPrinter(HANDLE hPrinter);
973 WINBOOL WINAPI AddJobA(HANDLE hPrinter,DWORD Level,LPBYTE pData,DWORD cbBuf,LPDWORD pcbNeeded);
974 WINBOOL WINAPI AddJobW(HANDLE hPrinter,DWORD Level,LPBYTE pData,DWORD cbBuf,LPDWORD pcbNeeded);
975 WINBOOL WINAPI ScheduleJob(HANDLE hPrinter,DWORD JobId);
976 WINBOOL WINAPI PrinterProperties(HWND hWnd,HANDLE hPrinter);
977 LONG WINAPI DocumentPropertiesA(HWND hWnd,HANDLE hPrinter,LPSTR pDeviceName,PDEVMODEA pDevModeOutput,PDEVMODEA pDevModeInput,DWORD fMode);
978 LONG WINAPI DocumentPropertiesW(HWND hWnd,HANDLE hPrinter,LPWSTR pDeviceName,PDEVMODEW pDevModeOutput,PDEVMODEW pDevModeInput,DWORD fMode);
979 LONG WINAPI AdvancedDocumentPropertiesA(HWND hWnd,HANDLE hPrinter,LPSTR pDeviceName,PDEVMODEA pDevModeOutput,PDEVMODEA pDevModeInput);
980 LONG WINAPI AdvancedDocumentPropertiesW(HWND hWnd,HANDLE hPrinter,LPWSTR pDeviceName,PDEVMODEW pDevModeOutput,PDEVMODEW pDevModeInput);
981 LONG ExtDeviceMode(HWND hWnd,HANDLE hInst,LPDEVMODEA pDevModeOutput,LPSTR pDeviceName,LPSTR pPort,LPDEVMODEA pDevModeInput,LPSTR pProfile,DWORD fMode);
982 DWORD WINAPI GetPrinterDataA(HANDLE hPrinter,LPSTR pValueName,LPDWORD pType,LPBYTE pData,DWORD nSize,LPDWORD pcbNeeded);
983 DWORD WINAPI GetPrinterDataW(HANDLE hPrinter,LPWSTR pValueName,LPDWORD pType,LPBYTE pData,DWORD nSize,LPDWORD pcbNeeded);
984 DWORD WINAPI GetPrinterDataExA(HANDLE hPrinter,LPCSTR pKeyName,LPCSTR pValueName,LPDWORD pType,LPBYTE pData,DWORD nSize,LPDWORD pcbNeeded);
985 DWORD WINAPI GetPrinterDataExW(HANDLE hPrinter,LPCWSTR pKeyName,LPCWSTR pValueName,LPDWORD pType,LPBYTE pData,DWORD nSize,LPDWORD pcbNeeded);
986 DWORD WINAPI EnumPrinterDataA(HANDLE hPrinter,DWORD dwIndex,LPSTR pValueName,DWORD cbValueName,LPDWORD pcbValueName,LPDWORD pType,LPBYTE pData,DWORD cbData,LPDWORD pcbData);
987 DWORD WINAPI EnumPrinterDataW(HANDLE hPrinter,DWORD dwIndex,LPWSTR pValueName,DWORD cbValueName,LPDWORD pcbValueName,LPDWORD pType,LPBYTE pData,DWORD cbData,LPDWORD pcbData);
988 DWORD WINAPI EnumPrinterDataExA(HANDLE hPrinter,LPCSTR pKeyName,LPBYTE pEnumValues,DWORD cbEnumValues,LPDWORD pcbEnumValues,LPDWORD pnEnumValues);
989 DWORD WINAPI EnumPrinterDataExW(HANDLE hPrinter,LPCWSTR pKeyName,LPBYTE pEnumValues,DWORD cbEnumValues,LPDWORD pcbEnumValues,LPDWORD pnEnumValues);
990 DWORD WINAPI EnumPrinterKeyA(HANDLE hPrinter,LPCSTR pKeyName,LPSTR pSubkey,DWORD cbSubkey,LPDWORD pcbSubkey);
991 DWORD WINAPI EnumPrinterKeyW(HANDLE hPrinter,LPCWSTR pKeyName,LPWSTR pSubkey,DWORD cbSubkey,LPDWORD pcbSubkey);
992 DWORD WINAPI SetPrinterDataA(HANDLE hPrinter,LPSTR pValueName,DWORD Type,LPBYTE pData,DWORD cbData);
993 DWORD WINAPI SetPrinterDataW(HANDLE hPrinter,LPWSTR pValueName,DWORD Type,LPBYTE pData,DWORD cbData);
994 DWORD WINAPI SetPrinterDataExA(HANDLE hPrinter,LPCSTR pKeyName,LPCSTR pValueName,DWORD Type,LPBYTE pData,DWORD cbData);
995 DWORD WINAPI SetPrinterDataExW(HANDLE hPrinter,LPCWSTR pKeyName,LPCWSTR pValueName,DWORD Type,LPBYTE pData,DWORD cbData);
996 DWORD WINAPI DeletePrinterDataA(HANDLE hPrinter,LPSTR pValueName);
997 DWORD WINAPI DeletePrinterDataW(HANDLE hPrinter,LPWSTR pValueName);
998 DWORD WINAPI DeletePrinterDataExA(HANDLE hPrinter,LPCSTR pKeyName,LPCSTR pValueName);
999 DWORD WINAPI DeletePrinterDataExW(HANDLE hPrinter,LPCWSTR pKeyName,LPCWSTR pValueName);
1000 DWORD WINAPI DeletePrinterKeyA(HANDLE hPrinter,LPCSTR pKeyName);
1001 DWORD WINAPI DeletePrinterKeyW(HANDLE hPrinter,LPCWSTR pKeyName);
1002
1003 #define PRINTER_NOTIFY_TYPE 0x00
1004 #define JOB_NOTIFY_TYPE 0x01
1005
1006 #define PRINTER_NOTIFY_FIELD_SERVER_NAME 0x00
1007 #define PRINTER_NOTIFY_FIELD_PRINTER_NAME 0x01
1008 #define PRINTER_NOTIFY_FIELD_SHARE_NAME 0x02
1009 #define PRINTER_NOTIFY_FIELD_PORT_NAME 0x03
1010 #define PRINTER_NOTIFY_FIELD_DRIVER_NAME 0x04
1011 #define PRINTER_NOTIFY_FIELD_COMMENT 0x05
1012 #define PRINTER_NOTIFY_FIELD_LOCATION 0x06
1013 #define PRINTER_NOTIFY_FIELD_DEVMODE 0x07
1014 #define PRINTER_NOTIFY_FIELD_SEPFILE 0x08
1015 #define PRINTER_NOTIFY_FIELD_PRINT_PROCESSOR 0x09
1016 #define PRINTER_NOTIFY_FIELD_PARAMETERS 0x0A
1017 #define PRINTER_NOTIFY_FIELD_DATATYPE 0x0B
1018 #define PRINTER_NOTIFY_FIELD_SECURITY_DESCRIPTOR 0x0C
1019 #define PRINTER_NOTIFY_FIELD_ATTRIBUTES 0x0D
1020 #define PRINTER_NOTIFY_FIELD_PRIORITY 0x0E
1021 #define PRINTER_NOTIFY_FIELD_DEFAULT_PRIORITY 0x0F
1022 #define PRINTER_NOTIFY_FIELD_START_TIME 0x10
1023 #define PRINTER_NOTIFY_FIELD_UNTIL_TIME 0x11
1024 #define PRINTER_NOTIFY_FIELD_STATUS 0x12
1025 #define PRINTER_NOTIFY_FIELD_STATUS_STRING 0x13
1026 #define PRINTER_NOTIFY_FIELD_CJOBS 0x14
1027 #define PRINTER_NOTIFY_FIELD_AVERAGE_PPM 0x15
1028 #define PRINTER_NOTIFY_FIELD_TOTAL_PAGES 0x16
1029 #define PRINTER_NOTIFY_FIELD_PAGES_PRINTED 0x17
1030 #define PRINTER_NOTIFY_FIELD_TOTAL_BYTES 0x18
1031 #define PRINTER_NOTIFY_FIELD_BYTES_PRINTED 0x19
1032 #define PRINTER_NOTIFY_FIELD_OBJECT_GUID 0x1A
1033
1034 #define JOB_NOTIFY_FIELD_PRINTER_NAME 0x00
1035 #define JOB_NOTIFY_FIELD_MACHINE_NAME 0x01
1036 #define JOB_NOTIFY_FIELD_PORT_NAME 0x02
1037 #define JOB_NOTIFY_FIELD_USER_NAME 0x03
1038 #define JOB_NOTIFY_FIELD_NOTIFY_NAME 0x04
1039 #define JOB_NOTIFY_FIELD_DATATYPE 0x05
1040 #define JOB_NOTIFY_FIELD_PRINT_PROCESSOR 0x06
1041 #define JOB_NOTIFY_FIELD_PARAMETERS 0x07
1042 #define JOB_NOTIFY_FIELD_DRIVER_NAME 0x08
1043 #define JOB_NOTIFY_FIELD_DEVMODE 0x09
1044 #define JOB_NOTIFY_FIELD_STATUS 0x0A
1045 #define JOB_NOTIFY_FIELD_STATUS_STRING 0x0B
1046 #define JOB_NOTIFY_FIELD_SECURITY_DESCRIPTOR 0x0C
1047 #define JOB_NOTIFY_FIELD_DOCUMENT 0x0D
1048 #define JOB_NOTIFY_FIELD_PRIORITY 0x0E
1049 #define JOB_NOTIFY_FIELD_POSITION 0x0F
1050 #define JOB_NOTIFY_FIELD_SUBMITTED 0x10
1051 #define JOB_NOTIFY_FIELD_START_TIME 0x11
1052 #define JOB_NOTIFY_FIELD_UNTIL_TIME 0x12
1053 #define JOB_NOTIFY_FIELD_TIME 0x13
1054 #define JOB_NOTIFY_FIELD_TOTAL_PAGES 0x14
1055 #define JOB_NOTIFY_FIELD_PAGES_PRINTED 0x15
1056 #define JOB_NOTIFY_FIELD_TOTAL_BYTES 0x16
1057 #define JOB_NOTIFY_FIELD_BYTES_PRINTED 0x17
1058
1059 typedef struct _PRINTER_NOTIFY_OPTIONS_TYPE {
1060 WORD Type;
1061 WORD Reserved0;
1062 DWORD Reserved1;
1063 DWORD Reserved2;
1064 DWORD Count;
1065 PWORD pFields;
1066 } PRINTER_NOTIFY_OPTIONS_TYPE,*PPRINTER_NOTIFY_OPTIONS_TYPE,*LPPRINTER_NOTIFY_OPTIONS_TYPE;
1067
1068 #define PRINTER_NOTIFY_OPTIONS_REFRESH 0x01
1069
1070 typedef struct _PRINTER_NOTIFY_OPTIONS {
1071 DWORD Version;
1072 DWORD Flags;
1073 DWORD Count;
1074 PPRINTER_NOTIFY_OPTIONS_TYPE pTypes;
1075 } PRINTER_NOTIFY_OPTIONS,*PPRINTER_NOTIFY_OPTIONS,*LPPRINTER_NOTIFY_OPTIONS;
1076
1077 #define PRINTER_NOTIFY_INFO_DISCARDED 0x01
1078
1079 typedef struct _PRINTER_NOTIFY_INFO_DATA {
1080 WORD Type;
1081 WORD Field;
1082 DWORD Reserved;
1083 DWORD Id;
1084 union {
1085 DWORD adwData[2];
1086 struct {
1087 DWORD cbBuf;
1088 LPVOID pBuf;
1089 } Data;
1090 } NotifyData;
1091 } PRINTER_NOTIFY_INFO_DATA,*PPRINTER_NOTIFY_INFO_DATA,*LPPRINTER_NOTIFY_INFO_DATA;
1092
1093 typedef struct _PRINTER_NOTIFY_INFO {
1094 DWORD Version;
1095 DWORD Flags;
1096 DWORD Count;
1097 PRINTER_NOTIFY_INFO_DATA aData[1];
1098 } PRINTER_NOTIFY_INFO,*PPRINTER_NOTIFY_INFO,*LPPRINTER_NOTIFY_INFO;
1099
1100 typedef struct _BINARY_CONTAINER{
1101 DWORD cbBuf;
1102 LPBYTE pData;
1103 } BINARY_CONTAINER,*PBINARY_CONTAINER;
1104
1105 typedef struct _BIDI_DATA{
1106 DWORD dwBidiType;
1107 union {
1108 WINBOOL bData;
1109 LONG iData;
1110 LPWSTR sData;
1111 FLOAT fData;
1112 BINARY_CONTAINER biData;
1113 } u;
1114 } BIDI_DATA,*PBIDI_DATA,*LPBIDI_DATA;
1115
1116 typedef struct _BIDI_REQUEST_DATA{
1117 DWORD dwReqNumber;
1118 LPWSTR pSchema;
1119 BIDI_DATA data;
1120 } BIDI_REQUEST_DATA ,*PBIDI_REQUEST_DATA ,*LPBIDI_REQUEST_DATA;
1121
1122 typedef struct _BIDI_REQUEST_CONTAINER{
1123 DWORD Version;
1124 DWORD Flags;
1125 DWORD Count;
1126 BIDI_REQUEST_DATA aData[1 ];
1127 }BIDI_REQUEST_CONTAINER,*PBIDI_REQUEST_CONTAINER,*LPBIDI_REQUEST_CONTAINER;
1128
1129 typedef struct _BIDI_RESPONSE_DATA{
1130 DWORD dwResult;
1131 DWORD dwReqNumber;
1132 LPWSTR pSchema;
1133 BIDI_DATA data;
1134 } BIDI_RESPONSE_DATA,*PBIDI_RESPONSE_DATA,*LPBIDI_RESPONSE_DATA;
1135
1136 typedef struct _BIDI_RESPONSE_CONTAINER{
1137 DWORD Version;
1138 DWORD Flags;
1139 DWORD Count;
1140 BIDI_RESPONSE_DATA aData[1 ];
1141 } BIDI_RESPONSE_CONTAINER,*PBIDI_RESPONSE_CONTAINER,*LPBIDI_RESPONSE_CONTAINER;
1142
1143 #define BIDI_ACTION_ENUM_SCHEMA L"EnumSchema"
1144 #define BIDI_ACTION_GET L"Get"
1145 #define BIDI_ACTION_SET L"Set"
1146 #define BIDI_ACTION_GET_ALL L"GetAll"
1147
1148 typedef enum {
1149 BIDI_NULL = 0,BIDI_INT = 1,BIDI_FLOAT = 2,BIDI_BOOL = 3,BIDI_STRING = 4,BIDI_TEXT = 5,BIDI_ENUM = 6,BIDI_BLOB = 7
1150 } BIDI_TYPE;
1151
1152 #define BIDI_ACCESS_ADMINISTRATOR 0x1
1153 #define BIDI_ACCESS_USER 0x2
1154
1155 #define ERROR_BIDI_STATUS_OK 0
1156 #define ERROR_BIDI_NOT_SUPPORTED ERROR_NOT_SUPPORTED
1157
1158 #define ERROR_BIDI_ERROR_BASE 13000
1159 #define ERROR_BIDI_STATUS_WARNING (ERROR_BIDI_ERROR_BASE + 1)
1160 #define ERROR_BIDI_SCHEMA_READ_ONLY (ERROR_BIDI_ERROR_BASE + 2)
1161 #define ERROR_BIDI_SERVER_OFFLINE (ERROR_BIDI_ERROR_BASE + 3)
1162 #define ERROR_BIDI_DEVICE_OFFLINE (ERROR_BIDI_ERROR_BASE + 4)
1163 #define ERROR_BIDI_SCHEMA_NOT_SUPPORTED (ERROR_BIDI_ERROR_BASE + 5)
1164
1165 DWORD WINAPI WaitForPrinterChange(HANDLE hPrinter,DWORD Flags);
1166 HANDLE WINAPI FindFirstPrinterChangeNotification(HANDLE hPrinter,DWORD fdwFlags,DWORD fdwOptions,LPVOID pPrinterNotifyOptions);
1167 WINBOOL WINAPI FindNextPrinterChangeNotification(HANDLE hChange,PDWORD pdwChange,LPVOID pPrinterNotifyOptions,LPVOID *ppPrinterNotifyInfo);
1168 WINBOOL WINAPI FreePrinterNotifyInfo (PPRINTER_NOTIFY_INFO pPrinterNotifyInfo);
1169 WINBOOL WINAPI FindClosePrinterChangeNotification(HANDLE hChange);
1170
1171 #define PRINTER_CHANGE_ADD_PRINTER 0x00000001
1172 #define PRINTER_CHANGE_SET_PRINTER 0x00000002
1173 #define PRINTER_CHANGE_DELETE_PRINTER 0x00000004
1174 #define PRINTER_CHANGE_FAILED_CONNECTION_PRINTER 0x00000008
1175 #define PRINTER_CHANGE_PRINTER 0x000000FF
1176 #define PRINTER_CHANGE_ADD_JOB 0x00000100
1177 #define PRINTER_CHANGE_SET_JOB 0x00000200
1178 #define PRINTER_CHANGE_DELETE_JOB 0x00000400
1179 #define PRINTER_CHANGE_WRITE_JOB 0x00000800
1180 #define PRINTER_CHANGE_JOB 0x0000FF00
1181 #define PRINTER_CHANGE_ADD_FORM 0x00010000
1182 #define PRINTER_CHANGE_SET_FORM 0x00020000
1183 #define PRINTER_CHANGE_DELETE_FORM 0x00040000
1184 #define PRINTER_CHANGE_FORM 0x00070000
1185 #define PRINTER_CHANGE_ADD_PORT 0x00100000
1186 #define PRINTER_CHANGE_CONFIGURE_PORT 0x00200000
1187 #define PRINTER_CHANGE_DELETE_PORT 0x00400000
1188 #define PRINTER_CHANGE_PORT 0x00700000
1189 #define PRINTER_CHANGE_ADD_PRINT_PROCESSOR 0x01000000
1190 #define PRINTER_CHANGE_DELETE_PRINT_PROCESSOR 0x04000000
1191 #define PRINTER_CHANGE_PRINT_PROCESSOR 0x07000000
1192 #define PRINTER_CHANGE_ADD_PRINTER_DRIVER 0x10000000
1193 #define PRINTER_CHANGE_SET_PRINTER_DRIVER 0x20000000
1194 #define PRINTER_CHANGE_DELETE_PRINTER_DRIVER 0x40000000
1195 #define PRINTER_CHANGE_PRINTER_DRIVER 0x70000000
1196 #define PRINTER_CHANGE_TIMEOUT 0x80000000
1197 #define PRINTER_CHANGE_ALL 0x7777FFFF
1198
1199 #define PrinterMessageBox __MINGW_NAME_AW(PrinterMessageBox)
1200 #define AddForm __MINGW_NAME_AW(AddForm)
1201 #define DeleteForm __MINGW_NAME_AW(DeleteForm)
1202 #define GetForm __MINGW_NAME_AW(GetForm)
1203 #define SetForm __MINGW_NAME_AW(SetForm)
1204 #define EnumForms __MINGW_NAME_AW(EnumForms)
1205 #define EnumMonitors __MINGW_NAME_AW(EnumMonitors)
1206 #define AddMonitor __MINGW_NAME_AW(AddMonitor)
1207 #define DeleteMonitor __MINGW_NAME_AW(DeleteMonitor)
1208 #define EnumPorts __MINGW_NAME_AW(EnumPorts)
1209 #define AddPort __MINGW_NAME_AW(AddPort)
1210 #define ConfigurePort __MINGW_NAME_AW(ConfigurePort)
1211 #define DeletePort __MINGW_NAME_AW(DeletePort)
1212 #define GetDefaultPrinter __MINGW_NAME_AW(GetDefaultPrinter)
1213 #define SetDefaultPrinter __MINGW_NAME_AW(SetDefaultPrinter)
1214 #define SetPort __MINGW_NAME_AW(SetPort)
1215 #define AddPrinterConnection __MINGW_NAME_AW(AddPrinterConnection)
1216 #define DeletePrinterConnection __MINGW_NAME_AW(DeletePrinterConnection)
1217
1218 DWORD WINAPI PrinterMessageBoxA(HANDLE hPrinter,DWORD Error,HWND hWnd,LPSTR pText,LPSTR pCaption,DWORD dwType);
1219 DWORD WINAPI PrinterMessageBoxW(HANDLE hPrinter,DWORD Error,HWND hWnd,LPWSTR pText,LPWSTR pCaption,DWORD dwType);
1220
1221 #define PRINTER_ERROR_INFORMATION 0x80000000
1222 #define PRINTER_ERROR_WARNING 0x40000000
1223 #define PRINTER_ERROR_SEVERE 0x20000000
1224
1225 #define PRINTER_ERROR_OUTOFPAPER 0x00000001
1226 #define PRINTER_ERROR_JAM 0x00000002
1227 #define PRINTER_ERROR_OUTOFTONER 0x00000004
1228
1229 WINBOOL WINAPI ClosePrinter(HANDLE hPrinter);
1230 WINBOOL WINAPI AddFormA(HANDLE hPrinter,DWORD Level,LPBYTE pForm);
1231 WINBOOL WINAPI AddFormW(HANDLE hPrinter,DWORD Level,LPBYTE pForm);
1232 WINBOOL WINAPI DeleteFormA(HANDLE hPrinter,LPSTR pFormName);
1233 WINBOOL WINAPI DeleteFormW(HANDLE hPrinter,LPWSTR pFormName);
1234 WINBOOL WINAPI GetFormA(HANDLE hPrinter,LPSTR pFormName,DWORD Level,LPBYTE pForm,DWORD cbBuf,LPDWORD pcbNeeded);
1235 WINBOOL WINAPI GetFormW(HANDLE hPrinter,LPWSTR pFormName,DWORD Level,LPBYTE pForm,DWORD cbBuf,LPDWORD pcbNeeded);
1236 WINBOOL WINAPI SetFormA(HANDLE hPrinter,LPSTR pFormName,DWORD Level,LPBYTE pForm);
1237 WINBOOL WINAPI SetFormW(HANDLE hPrinter,LPWSTR pFormName,DWORD Level,LPBYTE pForm);
1238 WINBOOL WINAPI EnumFormsA(HANDLE hPrinter,DWORD Level,LPBYTE pForm,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
1239 WINBOOL WINAPI EnumFormsW(HANDLE hPrinter,DWORD Level,LPBYTE pForm,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
1240 WINBOOL WINAPI EnumMonitorsA(LPSTR pName,DWORD Level,LPBYTE pMonitor,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
1241 WINBOOL WINAPI EnumMonitorsW(LPWSTR pName,DWORD Level,LPBYTE pMonitor,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
1242 WINBOOL WINAPI AddMonitorA(LPSTR pName,DWORD Level,LPBYTE pMonitorInfo);
1243 WINBOOL WINAPI AddMonitorW(LPWSTR pName,DWORD Level,LPBYTE pMonitorInfo);
1244 WINBOOL WINAPI DeleteMonitorA(LPSTR pName,LPSTR pEnvironment,LPSTR pMonitorName);
1245 WINBOOL WINAPI DeleteMonitorW(LPWSTR pName,LPWSTR pEnvironment,LPWSTR pMonitorName);
1246 WINBOOL WINAPI EnumPortsA(LPSTR pName,DWORD Level,LPBYTE pPorts,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
1247 WINBOOL WINAPI EnumPortsW(LPWSTR pName,DWORD Level,LPBYTE pPorts,DWORD cbBuf,LPDWORD pcbNeeded,LPDWORD pcReturned);
1248 WINBOOL WINAPI AddPortA(LPSTR pName,HWND hWnd,LPSTR pMonitorName);
1249 WINBOOL WINAPI AddPortW(LPWSTR pName,HWND hWnd,LPWSTR pMonitorName);
1250 WINBOOL WINAPI ConfigurePortA(LPSTR pName,HWND hWnd,LPSTR pPortName);
1251 WINBOOL WINAPI ConfigurePortW(LPWSTR pName,HWND hWnd,LPWSTR pPortName);
1252 WINBOOL WINAPI DeletePortA(LPSTR pName,HWND hWnd,LPSTR pPortName);
1253 WINBOOL WINAPI DeletePortW(LPWSTR pName,HWND hWnd,LPWSTR pPortName);
1254 WINBOOL WINAPI XcvDataW(HANDLE hXcv,PCWSTR pszDataName,PBYTE pInputData,DWORD cbInputData,PBYTE pOutputData,DWORD cbOutputData,PDWORD pcbOutputNeeded,PDWORD pdwStatus);
1255
1256 #define XcvData XcvDataW
1257
1258 WINBOOL WINAPI GetDefaultPrinterA(LPSTR pszBuffer,LPDWORD pcchBuffer);
1259 WINBOOL WINAPI GetDefaultPrinterW(LPWSTR pszBuffer,LPDWORD pcchBuffer);
1260 WINBOOL WINAPI SetDefaultPrinterA(LPCSTR pszPrinter);
1261 WINBOOL WINAPI SetDefaultPrinterW(LPCWSTR pszPrinter);
1262 WINBOOL WINAPI SetPortA(LPSTR pName,LPSTR pPortName,DWORD dwLevel,LPBYTE pPortInfo);
1263 WINBOOL WINAPI SetPortW(LPWSTR pName,LPWSTR pPortName,DWORD dwLevel,LPBYTE pPortInfo);
1264 WINBOOL WINAPI AddPrinterConnectionA(LPSTR pName);
1265 WINBOOL WINAPI AddPrinterConnectionW(LPWSTR pName);
1266 WINBOOL WINAPI DeletePrinterConnectionA(LPSTR pName);
1267 WINBOOL WINAPI DeletePrinterConnectionW(LPWSTR pName);
1268 HANDLE WINAPI ConnectToPrinterDlg(HWND hwnd,DWORD Flags);
1269
1270 typedef struct _PROVIDOR_INFO_1A{
1271 LPSTR pName;
1272 LPSTR pEnvironment;
1273 LPSTR pDLLName;
1274 } PROVIDOR_INFO_1A,*PPROVIDOR_INFO_1A,*LPPROVIDOR_INFO_1A;
1275
1276 typedef struct _PROVIDOR_INFO_1W{
1277 LPWSTR pName;
1278 LPWSTR pEnvironment;
1279 LPWSTR pDLLName;
1280 } PROVIDOR_INFO_1W,*PPROVIDOR_INFO_1W,*LPPROVIDOR_INFO_1W;
1281
1282 __MINGW_TYPEDEF_AW(PROVIDOR_INFO_1)
1283 __MINGW_TYPEDEF_AW(PPROVIDOR_INFO_1)
1284 __MINGW_TYPEDEF_AW(LPPROVIDOR_INFO_1)
1285
1286 typedef struct _PROVIDOR_INFO_2A{
1287 LPSTR pOrder;
1288 } PROVIDOR_INFO_2A,*PPROVIDOR_INFO_2A,*LPPROVIDOR_INFO_2A;
1289
1290 typedef struct _PROVIDOR_INFO_2W{
1291 LPWSTR pOrder;
1292 } PROVIDOR_INFO_2W,*PPROVIDOR_INFO_2W,*LPPROVIDOR_INFO_2W;
1293
1294 __MINGW_TYPEDEF_AW(PROVIDOR_INFO_2)
1295 __MINGW_TYPEDEF_AW(PPROVIDOR_INFO_2)
1296 __MINGW_TYPEDEF_AW(LPPROVIDOR_INFO_2)
1297
1298 #define AddPrintProvidor __MINGW_NAME_AW(AddPrintProvidor)
1299 #define DeletePrintProvidor __MINGW_NAME_AW(DeletePrintProvidor)
1300 #define IsValidDevmode __MINGW_NAME_AW(IsValidDevmode)
1301
1302 WINBOOL WINAPI AddPrintProvidorA(LPSTR pName,DWORD level,LPBYTE pProvidorInfo);
1303 WINBOOL WINAPI AddPrintProvidorW(LPWSTR pName,DWORD level,LPBYTE pProvidorInfo);
1304 WINBOOL WINAPI DeletePrintProvidorA(LPSTR pName,LPSTR pEnvironment,LPSTR pPrintProvidorName);
1305 WINBOOL WINAPI DeletePrintProvidorW(LPWSTR pName,LPWSTR pEnvironment,LPWSTR pPrintProvidorName);
1306 WINBOOL WINAPI IsValidDevmodeA (PDEVMODEA pDevmode,size_t DevmodeSize);
1307 WINBOOL WINAPI IsValidDevmodeW (PDEVMODEW pDevmode,size_t DevmodeSize);
1308
1309 #define SPLREG_DEFAULT_SPOOL_DIRECTORY TEXT("DefaultSpoolDirectory")
1310 #define SPLREG_PORT_THREAD_PRIORITY_DEFAULT TEXT("PortThreadPriorityDefault")
1311 #define SPLREG_PORT_THREAD_PRIORITY TEXT("PortThreadPriority")
1312 #define SPLREG_SCHEDULER_THREAD_PRIORITY_DEFAULT TEXT("SchedulerThreadPriorityDefault")
1313 #define SPLREG_SCHEDULER_THREAD_PRIORITY TEXT("SchedulerThreadPriority")
1314 #define SPLREG_BEEP_ENABLED TEXT("BeepEnabled")
1315 #define SPLREG_NET_POPUP TEXT("NetPopup")
1316 #define SPLREG_RETRY_POPUP TEXT("RetryPopup")
1317 #define SPLREG_NET_POPUP_TO_COMPUTER TEXT("NetPopupToComputer")
1318 #define SPLREG_EVENT_LOG TEXT("EventLog")
1319 #define SPLREG_MAJOR_VERSION TEXT("MajorVersion")
1320 #define SPLREG_MINOR_VERSION TEXT("MinorVersion")
1321 #define SPLREG_ARCHITECTURE TEXT("Architecture")
1322 #define SPLREG_OS_VERSION TEXT("OSVersion")
1323 #define SPLREG_OS_VERSIONEX TEXT("OSVersionEx")
1324 #define SPLREG_DS_PRESENT TEXT("DsPresent")
1325 #define SPLREG_DS_PRESENT_FOR_USER TEXT("DsPresentForUser")
1326 #define SPLREG_REMOTE_FAX TEXT("RemoteFax")
1327 #define SPLREG_RESTART_JOB_ON_POOL_ERROR TEXT("RestartJobOnPoolError")
1328 #define SPLREG_RESTART_JOB_ON_POOL_ENABLED TEXT("RestartJobOnPoolEnabled")
1329 #define SPLREG_DNS_MACHINE_NAME TEXT("DNSMachineName")
1330 #define SPLREG_ALLOW_USER_MANAGEFORMS TEXT("AllowUserManageForms")
1331 #define SPLREG_WEBSHAREMGMT TEXT("WebShareMgmt")
1332
1333 #define SERVER_ACCESS_ADMINISTER 0x00000001
1334 #define SERVER_ACCESS_ENUMERATE 0x00000002
1335
1336 #define PRINTER_ACCESS_ADMINISTER 0x00000004
1337 #define PRINTER_ACCESS_USE 0x00000008
1338
1339 #define JOB_ACCESS_ADMINISTER 0x00000010
1340 #define JOB_ACCESS_READ 0x00000020
1341
1342 #define SERVER_ALL_ACCESS (STANDARD_RIGHTS_REQUIRED | SERVER_ACCESS_ADMINISTER | SERVER_ACCESS_ENUMERATE)
1343 #define SERVER_READ (STANDARD_RIGHTS_READ | SERVER_ACCESS_ENUMERATE)
1344 #define SERVER_WRITE (STANDARD_RIGHTS_WRITE | SERVER_ACCESS_ADMINISTER | SERVER_ACCESS_ENUMERATE)
1345 #define SERVER_EXECUTE (STANDARD_RIGHTS_EXECUTE | SERVER_ACCESS_ENUMERATE)
1346 #define PRINTER_ALL_ACCESS (STANDARD_RIGHTS_REQUIRED | PRINTER_ACCESS_ADMINISTER | PRINTER_ACCESS_USE)
1347 #define PRINTER_READ (STANDARD_RIGHTS_READ | PRINTER_ACCESS_USE)
1348 #define PRINTER_WRITE (STANDARD_RIGHTS_WRITE | PRINTER_ACCESS_USE)
1349 #define PRINTER_EXECUTE (STANDARD_RIGHTS_EXECUTE | PRINTER_ACCESS_USE)
1350 #define JOB_ALL_ACCESS (STANDARD_RIGHTS_REQUIRED | JOB_ACCESS_ADMINISTER | JOB_ACCESS_READ)
1351 #define JOB_READ (STANDARD_RIGHTS_READ | JOB_ACCESS_READ)
1352 #define JOB_WRITE (STANDARD_RIGHTS_WRITE | JOB_ACCESS_ADMINISTER)
1353 #define JOB_EXECUTE (STANDARD_RIGHTS_EXECUTE | JOB_ACCESS_ADMINISTER)
1354
1355 #define SPLDS_SPOOLER_KEY TEXT("DsSpooler")
1356 #define SPLDS_DRIVER_KEY TEXT("DsDriver")
1357 #define SPLDS_USER_KEY TEXT("DsUser")
1358
1359 #define SPLDS_ASSET_NUMBER TEXT("assetNumber")
1360 #define SPLDS_BYTES_PER_MINUTE TEXT("bytesPerMinute")
1361 #define SPLDS_DESCRIPTION TEXT("description")
1362 #define SPLDS_DRIVER_NAME TEXT("driverName")
1363 #define SPLDS_DRIVER_VERSION TEXT("driverVersion")
1364 #define SPLDS_LOCATION TEXT("location")
1365 #define SPLDS_PORT_NAME TEXT("portName")
1366 #define SPLDS_PRINT_ATTRIBUTES TEXT("printAttributes")
1367 #define SPLDS_PRINT_BIN_NAMES TEXT("printBinNames")
1368 #define SPLDS_PRINT_COLLATE TEXT("printCollate")
1369 #define SPLDS_PRINT_COLOR TEXT("printColor")
1370 #define SPLDS_PRINT_DUPLEX_SUPPORTED TEXT("printDuplexSupported")
1371 #define SPLDS_PRINT_END_TIME TEXT("printEndTime")
1372 #define SPLDS_PRINTER_CLASS TEXT("printQueue")
1373 #define SPLDS_PRINTER_NAME TEXT("printerName")
1374 #define SPLDS_PRINT_KEEP_PRINTED_JOBS TEXT("printKeepPrintedJobs")
1375 #define SPLDS_PRINT_LANGUAGE TEXT("printLanguage")
1376 #define SPLDS_PRINT_MAC_ADDRESS TEXT("printMACAddress")
1377 #define SPLDS_PRINT_MAX_X_EXTENT TEXT("printMaxXExtent")
1378 #define SPLDS_PRINT_MAX_Y_EXTENT TEXT("printMaxYExtent")
1379 #define SPLDS_PRINT_MAX_RESOLUTION_SUPPORTED TEXT("printMaxResolutionSupported")
1380 #define SPLDS_PRINT_MEDIA_READY TEXT("printMediaReady")
1381 #define SPLDS_PRINT_MEDIA_SUPPORTED TEXT("printMediaSupported")
1382 #define SPLDS_PRINT_MEMORY TEXT("printMemory")
1383 #define SPLDS_PRINT_MIN_X_EXTENT TEXT("printMinXExtent")
1384 #define SPLDS_PRINT_MIN_Y_EXTENT TEXT("printMinYExtent")
1385 #define SPLDS_PRINT_NETWORK_ADDRESS TEXT("printNetworkAddress")
1386 #define SPLDS_PRINT_NOTIFY TEXT("printNotify")
1387 #define SPLDS_PRINT_NUMBER_UP TEXT("printNumberUp")
1388 #define SPLDS_PRINT_ORIENTATIONS_SUPPORTED TEXT("printOrientationsSupported")
1389 #define SPLDS_PRINT_OWNER TEXT("printOwner")
1390 #define SPLDS_PRINT_PAGES_PER_MINUTE TEXT("printPagesPerMinute")
1391 #define SPLDS_PRINT_RATE TEXT("printRate")
1392 #define SPLDS_PRINT_RATE_UNIT TEXT("printRateUnit")
1393 #define SPLDS_PRINT_SEPARATOR_FILE TEXT("printSeparatorFile")
1394 #define SPLDS_PRINT_SHARE_NAME TEXT("printShareName")
1395 #define SPLDS_PRINT_SPOOLING TEXT("printSpooling")
1396 #define SPLDS_PRINT_STAPLING_SUPPORTED TEXT("printStaplingSupported")
1397 #define SPLDS_PRINT_START_TIME TEXT("printStartTime")
1398 #define SPLDS_PRINT_STATUS TEXT("printStatus")
1399 #define SPLDS_PRIORITY TEXT("priority")
1400 #define SPLDS_SERVER_NAME TEXT("serverName")
1401 #define SPLDS_SHORT_SERVER_NAME TEXT("shortServerName")
1402 #define SPLDS_UNC_NAME TEXT("uNCName")
1403 #define SPLDS_URL TEXT("url")
1404 #define SPLDS_FLAGS TEXT("flags")
1405 #define SPLDS_VERSION_NUMBER TEXT("versionNumber")
1406
1407 #define SPLDS_PRINTER_NAME_ALIASES TEXT("printerNameAliases")
1408 #define SPLDS_PRINTER_LOCATIONS TEXT("printerLocations")
1409 #define SPLDS_PRINTER_MODEL TEXT("printerModel")
1410
1411 #if (_WIN32_WINNT >= 0x0600)
1412 #define AddPrinterConnection2 __MINGW_NAME_AW(AddPrinterConnection2)
1413 #define DeletePrinterDriverPackage __MINGW_NAME_AW(DeletePrinterDriverPackage)
1414 #define DocumentEvent __MINGW_NAME_AW(DocumentEvent)
1415
1416 #define PRINTER_CONNECTION_MISMATCH 0x00000020
1417 #define PRINTER_CONNECTION_NO_UI 0x00000040
1418
1419 typedef enum tagPRINTER_OPTION_FLAGS {
1420 PRINTER_OPTION_NO_CACHE,
1421 PRINTER_OPTION_CACHE,
1422 PRINTER_OPTION_CLIENT_CHANGE
1423 } PRINTER_OPTION_FLAGS;
1424
1425 typedef enum tagEPrintXPSJobOperation {
1426 kJobProduction,
1427 kJobConsumption
1428 } EPrintXPSJobOperation;
1429
1430 typedef enum tagEPrintXPSJobProgress {
1431 kAddingDocumentSequence,
1432 kDocumentSequenceAdded,
1433 kAddingFixedDocument,
1434 kFixedDocumentAdded,
1435 kAddingFixedPage,
1436 kFixedPageAdded,
1437 kResourceAdded,
1438 kFontAdded,
1439 kImageAdded,
1440 kXpsDocumentCommitted
1441 } EPrintXPSJobProgress;
1442
1443 typedef struct _PRINTER_CONNECTION_INFO_1 {
1444 DWORD dwFlags;
1445 LPTSTR pszDriverName;
1446 } PRINTER_CONNECTION_INFO_1, *PPRINTER_CONNECTION_INFO_1;
1447
1448 WINBOOL AddPrinterConnection2W(HWND hWnd,LPCWSTR pszName,DWORD dwLevel,PVOID pConnectionInfo);
1449 WINBOOL AddPrinterConnection2A(HWND hWnd,LPCSTR pszName,DWORD dwLevel,PVOID pConnectionInfo); /*Not supported and returns ERROR_NOT_SUPPORTED.*/
1450
1451 HRESULT WINAPI DeletePrinterDriverPackageA(
1452 LPCSTR pszServer,
1453 LPCSTR pszInfPath,
1454 LPCSTR pszEnvironment
1455 );
1456
1457 HRESULT WINAPI DeletePrinterDriverPackageW(
1458 LPCWSTR pszServer,
1459 LPCWSTR pszInfPath,
1460 LPCWSTR pszEnvironment
1461 );
1462
1463 HRESULT DocumentEventA(
1464 HANDLE hPrinter,
1465 HDC hdc,
1466 INT iEsc,
1467 ULONG cbIn,
1468 PVOID pvIn,
1469 ULONG cbOut,
1470 PVOID pvOut
1471 );
1472
1473 HRESULT DocumentEventW(
1474 HANDLE hPrinter,
1475 HDC hdc,
1476 INT iEsc,
1477 ULONG cbIn,
1478 PVOID pvIn,
1479 ULONG cbOut,
1480 PVOID pvOut
1481 );
1482
1483
1484 typedef struct _FORM_INFO_2A {
1485 DWORD Flags;
1486 LPSTR pName;
1487 SIZEL Size;
1488 RECTL ImageableArea;
1489 LPCSTR pKeyword;
1490 DWORD StringType;
1491 LPCSTR pMuiDll;
1492 DWORD dwResourceId;
1493 LPCSTR pDisplayName;
1494 LANGID wLangId;
1495 } FORM_INFO_2A, *PFORM_INFO_2A;
1496
1497 typedef struct _FORM_INFO_2W {
1498 DWORD Flags;
1499 LPWSTR pName;
1500 SIZEL Size;
1501 RECTL ImageableArea;
1502 LPCSTR pKeyword;
1503 DWORD StringType;
1504 LPCWSTR pMuiDll;
1505 DWORD dwResourceId;
1506 LPCWSTR pDisplayName;
1507 LANGID wLangId;
1508 } FORM_INFO_2W, *PFORM_INFO_2W;
1509
1510 __MINGW_TYPEDEF_AW(FORM_INFO_2)
1511 __MINGW_TYPEDEF_AW(PFORM_INFO_2)
1512
1513 typedef struct _PRINTPROCESSOR_CAPS_2 {
1514 DWORD dwLevel;
1515 DWORD dwNupOptions;
1516 DWORD dwPageOrderFlags;
1517 DWORD dwNumberOfCopies;
1518 DWORD dwNupDirectionCaps;
1519 DWORD dwNupBorderCaps;
1520 DWORD dwBookletHandlingCaps;
1521 DWORD dwDuplexHandlingCaps;
1522 DWORD dwScalingCaps;
1523 } PRINTPROCESSOR_CAPS_2, *PPRINTPROCESSOR_CAPS_2;
1524
1525 HRESULT ReportJobProcessingProgress(
1526 HANDLE printerHandle,
1527 ULONG jobId,
1528 EPrintXPSJobOperation jobOperation,
1529 EPrintXPSJobProgress jobProgress
1530 );
1531
1532 typedef struct _CORE_PRINTER_DRIVERA {
1533 GUID CoreDriverGUID;
1534 FILETIME ftDriverDate;
1535 DWORDLONG dwlDriverVersion;
1536 CHAR szPackageID[MAX_PATH];
1537 } CORE_PRINTER_DRIVERA, *PCORE_PRINTER_DRIVERA;
1538
1539 typedef struct _CORE_PRINTER_DRIVERW {
1540 GUID CoreDriverGUID;
1541 FILETIME ftDriverDate;
1542 DWORDLONG dwlDriverVersion;
1543 WCHAR szPackageID[MAX_PATH];
1544 } CORE_PRINTER_DRIVERW, *PCORE_PRINTER_DRIVERW;
1545
1546 typedef struct _PRINTER_OPTIONS {
1547 UINT cbSize;
1548 DWORD dwFlags;
1549 } PRINTER_OPTIONS, *PPRINTER_OPTIONS;
1550
1551 __MINGW_TYPEDEF_AW(CORE_PRINTER_DRIVER)
1552 __MINGW_TYPEDEF_AW(PCORE_PRINTER_DRIVER)
1553 #define GetCorePrinterDrivers __MINGW_NAME_AW(GetCorePrinterDrivers)
1554 #define GetPrinterDriver2 __MINGW_NAME_AW(GetPrinterDriver2)
1555 #define GetPrinterDriverPackagePath __MINGW_NAME_AW(GetPrinterDriverPackagePath)
1556 #define GetSpoolFileHandle __MINGW_NAME_AW(GetSpoolFileHandle)
1557
1558 HRESULT WINAPI GetCorePrinterDriversA(
1559 LPCSTR pszServer,
1560 LPCSTR pszEnvironment,
1561 LPCSTR pszzCoreDriverDependencies,
1562 DWORD cCorePrinterDrivers,
1563 PCORE_PRINTER_DRIVERA pCorePrinterDrivers
1564 );
1565
1566 HRESULT WINAPI GetCorePrinterDriversW(
1567 LPCWSTR pszServer,
1568 LPCWSTR pszEnvironment,
1569 LPCWSTR pszzCoreDriverDependencies,
1570 DWORD cCorePrinterDrivers,
1571 PCORE_PRINTER_DRIVERW pCorePrinterDrivers
1572 );
1573
1574 /*Unsupported*/
1575 WINBOOL WINAPI GetPrinterDriver2A(
1576 HWND hWnd,
1577 HANDLE hPrinter,
1578 LPSTR pEnvironment,
1579 DWORD Level,
1580 LPBYTE pDriverInfo,
1581 DWORD cbBuf,
1582 LPDWORD pcbNeeded
1583 );
1584
1585 WINBOOL WINAPI GetPrinterDriver2W(
1586 HWND hWnd,
1587 HANDLE hPrinter,
1588 LPWSTR pEnvironment,
1589 DWORD Level,
1590 LPBYTE pDriverInfo,
1591 DWORD cbBuf,
1592 LPDWORD pcbNeeded
1593 );
1594
1595 HRESULT WINAPI GetPrinterDriverPackagePathA(
1596 LPCSTR pszServer,
1597 LPCSTR pszEnvironment,
1598 LPCSTR pszLanguage,
1599 LPCSTR pszPackageID,
1600 LPSTR pszDriverPackageCab,
1601 DWORD cchDriverPackageCab,
1602 LPDWORD pcchRequiredSize
1603 );
1604
1605 HRESULT WINAPI GetPrinterDriverPackagePathW(
1606 LPCWSTR pszServer,
1607 LPCWSTR pszEnvironment,
1608 LPCWSTR pszLanguage,
1609 LPCWSTR pszPackageID,
1610 LPWSTR pszDriverPackageCab,
1611 DWORD cchDriverPackageCab,
1612 LPDWORD pcchRequiredSize
1613 );
1614
1615 HANDLE WINAPI GetSpoolFileHandleA(
1616 HANDLE hPrinter
1617 );
1618
1619 HANDLE WINAPI GetSpoolFileHandleW(
1620 HANDLE hPrinter
1621 );
1622
1623 HANDLE WINAPI CommitSpoolData(
1624 HANDLE hPrinter,
1625 HANDLE hSpoolFile,
1626 DWORD cbCommit
1627 );
1628
1629 WINBOOL WINAPI CloseSpoolFileHandle(
1630 HANDLE hPrinter,
1631 HANDLE hSpoolFile
1632 );
1633
1634 WINBOOL WINAPI OpenPrinter2A(
1635 LPCSTR pPrinterName,
1636 LPHANDLE phPrinter,
1637 LPPRINTER_DEFAULTS pDefault,
1638 PPRINTER_OPTIONS pOptions
1639 );
1640
1641 WINBOOL WINAPI OpenPrinter2W(
1642 LPCWSTR pPrinterName,
1643 LPHANDLE phPrinter,
1644 LPPRINTER_DEFAULTS pDefault,
1645 PPRINTER_OPTIONS pOptions
1646 );
1647
1648 #define OpenPrinter2 __MINGW_NAME_AW(OpenPrinter2)
1649
1650 HRESULT WINAPI UploadPrinterDriverPackageA(
1651 LPCSTR pszServer,
1652 LPCSTR pszInfPath,
1653 LPCSTR pszEnvironment,
1654 DWORD dwFlags,
1655 HWND hwnd,
1656 LPSTR pszDestInfPath,
1657 PULONG pcchDestInfPath
1658 );
1659
1660 HRESULT WINAPI UploadPrinterDriverPackageW(
1661 LPCWSTR pszServer,
1662 LPCWSTR pszInfPath,
1663 LPCWSTR pszEnvironment,
1664 DWORD dwFlags,
1665 HWND hwnd,
1666 LPWSTR pszDestInfPath,
1667 PULONG pcchDestInfPath
1668 );
1669
1670 #define UploadPrinterDriverPackage __MINGW_NAME_AW(UploadPrinterDriverPackage)
1671
1672 #endif /*(_WIN32_WINNT >= 0x0600)*/
1673
1674 #ifdef __cplusplus
1675 }
1676 #endif
1677 #endif