Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

185 lines
3.9 KiB

  1. ////////////////////////////////////////////////////////////////////////
  2. // Copyright (c) 1999-2001 Microsoft Corporation
  3. // All rights reserved.
  4. //
  5. //Module Name:
  6. //
  7. // oemdev.h
  8. //
  9. //Abstract:
  10. //
  11. // OEM DEVMODE
  12. //
  13. //Environment:
  14. //
  15. // Windows NT printer driver
  16. //
  17. //////////////////////////////////////////////////////////////////
  18. #ifndef _INCLUDE_OEMDEV_H_
  19. #define _INCLUDE_OEMDEV_H_
  20. #ifndef WIN32
  21. #define WIN32
  22. #endif
  23. ///////////////////////////////////////////////////////////////////////////
  24. // Defines
  25. ///////////////////////////////////////////////////////////////////////////
  26. //
  27. // VERSION number
  28. //
  29. #define OEM_DEVMODE_VERSION_1_0 0x00010000
  30. #define HELPFILE_NAME_LENGTH 256
  31. //
  32. // Printer Model Defined Constants.
  33. //
  34. // Any new supported printer model needs to be added to this list.
  35. //
  36. #define HP_MODEL_NOT_SUPPORTED 0
  37. #define HP_HPCLJ5 1
  38. #define HP_HPC4500 2
  39. #ifdef PSCRIPT
  40. //
  41. // Postscript stuff
  42. //
  43. typedef struct _CMD_INJECTION {
  44. DWORD dwbSize;
  45. DWORD dwIndex;
  46. DWORD loOffset;
  47. } CMD_INJECTION;
  48. #define NUM_OF_PS_INJECTION 5
  49. typedef struct _OEMDEVMODE {
  50. OEM_DMEXTRAHEADER DMExtraHdr;
  51. CMD_INJECTION InjectCmd[NUM_OF_PS_INJECTION];
  52. } OEMDEVMODE, *POEMDEVMODE;
  53. #else
  54. typedef enum _OEMGRAPHICSMODE
  55. {
  56. // In Raster Graphics Mode, control is sent back to the Unidriver and GDI.
  57. // In HPGL2 Graphics Mode, all processing is done by the our kernel mode
  58. // dll.
  59. HPGL2,
  60. RASTER,
  61. RIP
  62. } OEMGRAPHICSMODE;
  63. typedef enum _OEMHALFTONE
  64. {
  65. // Monarch distinguishes between the Text and Graphics
  66. // halftones. So, four different halftones are needed for
  67. // Monarch.
  68. // Bedrock + does not distinguish between text and graphics.
  69. TEXT_DETAIL, /* Esc*t0J */
  70. TEXT_SMOOTH, /* Esc*t15J */
  71. GRAPHICS_DETAIL, /* Esc*t15J */
  72. GRAPHICS_SMOOTH, /* Esc*t18J */
  73. CLJ5_DETAIL, /* Esc*t0J */
  74. CLJ5_SMOOTH, /* Esc*t15J */
  75. CLJ5_BASIC, /* Esc*t18J */
  76. HALFTONE_NOT_SET
  77. } OEMHALFTONE;
  78. typedef enum _OEMCOLORCONTROL
  79. {
  80. VIVID,
  81. SCRNMATCH,
  82. CLJ5_SCRNMATCH,
  83. NOADJ,
  84. COLORCONTROL_NOT_SET
  85. } OEMCOLORCONTROL;
  86. typedef struct _OEMCOLOROPTIONS
  87. {
  88. OEMHALFTONE Halftone;
  89. OEMCOLORCONTROL ColorControl;
  90. } OEMCOLOROPTIONS, *POEMCOLOROPTIONS;
  91. typedef enum _OEMRESOLUTION
  92. {
  93. // Monarch supports both 300 and 600 dpi. Ideally monarch should only
  94. // use 600 dpi but for debugging purposes 300 dpi is used as well.
  95. // Bedrock + supports only 300 dpi.
  96. PDM_150DPI,
  97. PDM_300DPI,
  98. PDM_600DPI,
  99. PDM_1200DPI
  100. } OEMRESOLUTION;
  101. typedef enum _OEMPAPERTYPE
  102. {
  103. // All of the following paper types are supported by
  104. // the Monarch. Only PLAIN, GLOSSY, and TRANSPARENCY
  105. // are supported by Bedrock +
  106. UNSPECIFIED, // Default Paper Type
  107. PLAIN,
  108. PREPRINTED,
  109. LETTERHEAD,
  110. TRANSPARENCY,
  111. GLOSSY,
  112. PREPUNCHED,
  113. LABELS,
  114. BOND,
  115. RECYCLED,
  116. COLOR,
  117. HEAVY,
  118. CARDSTOCK
  119. } OEMPAPERTYPE;
  120. typedef enum _OEMPRINTERMODEL
  121. {
  122. HPCLJ5,
  123. HPC4500,
  124. MODEL_NOT_NEEDED
  125. } OEMPRINTERMODEL;
  126. //
  127. // Whether or not the document will print in monochrome mode or color.
  128. //
  129. typedef enum _OEMCOLORMODE
  130. {
  131. MONOCHROME_MODE,
  132. COLOR_MODE
  133. } OEMCOLORMODE;
  134. typedef struct _OEMDEVMODE
  135. {
  136. OEM_DMEXTRAHEADER DMExtraHdr;
  137. BOOL DirtyDefaults;
  138. BOOL DirtyColors;
  139. BOOL DirtyOptions;
  140. BOOL ColorTreatment;
  141. OEMCOLOROPTIONS Text;
  142. OEMCOLOROPTIONS Graphics;
  143. OEMCOLOROPTIONS Photos;
  144. OEMPAPERTYPE OemPaperType;
  145. BOOL TrueType;
  146. BOOL ListPrinterFonts;
  147. BOOL MetafileSpool;
  148. BOOL GlossFinish;
  149. OEMGRAPHICSMODE UIGraphicsMode;
  150. LONG Duplex;
  151. OEMRESOLUTION dmResolution;
  152. BOOL bFastRaster;
  153. OEMPRINTERMODEL PrinterModel;
  154. BOOL bUpdateTreeview;
  155. OEMCOLORMODE eOemColorMode;
  156. WCHAR lpwstrHelpFile[HELPFILE_NAME_LENGTH];
  157. } OEMDEVMODE, *POEMDEVMODE;
  158. #endif // PSCRIPT
  159. #endif // _INCLUDE_OEMDEV_H_