print.h
来自「用于查询PC机上的USB端口是否有设备挂接上」· C头文件 代码 · 共 550 行 · 第 1/2 页
H
550 行
#define DMPAPER_PENV_4 99 /* PRC Envelope #4 110 x 208 mm */
#define DMPAPER_PENV_5 100 /* PRC Envelope #5 110 x 220 mm */
#define DMPAPER_PENV_6 101 /* PRC Envelope #6 120 x 230 mm */
#define DMPAPER_PENV_7 102 /* PRC Envelope #7 160 x 230 mm */
#define DMPAPER_PENV_8 103 /* PRC Envelope #8 120 x 309 mm */
#define DMPAPER_PENV_9 104 /* PRC Envelope #9 229 x 324 mm */
#define DMPAPER_PENV_10 105 /* PRC Envelope #10 324 x 458 mm */
#define DMPAPER_P16K_ROTATED 106 /* PRC 16K Rotated */
#define DMPAPER_P32K_ROTATED 107 /* PRC 32K Rotated */
#define DMPAPER_P32KBIG_ROTATED 108 /* PRC 32K(Big) Rotated */
#define DMPAPER_PENV_1_ROTATED 109 /* PRC Envelope #1 Rotated 165 x 102 mm*/
#define DMPAPER_PENV_2_ROTATED 110 /* PRC Envelope #2 Rotated 176 x 102 mm*/
#define DMPAPER_PENV_3_ROTATED 111 /* PRC Envelope #3 Rotated 176 x 125 mm*/
#define DMPAPER_PENV_4_ROTATED 112 /* PRC Envelope #4 Rotated 208 x 110 mm*/
#define DMPAPER_PENV_5_ROTATED 113 /* PRC Envelope #5 Rotated 220 x 110 mm*/
#define DMPAPER_PENV_6_ROTATED 114 /* PRC Envelope #6 Rotated 230 x 120 mm*/
#define DMPAPER_PENV_7_ROTATED 115 /* PRC Envelope #7 Rotated 230 x 160 mm*/
#define DMPAPER_PENV_8_ROTATED 116 /* PRC Envelope #8 Rotated 309 x 120 mm*/
#define DMPAPER_PENV_9_ROTATED 117 /* PRC Envelope #9 Rotated 324 x 229 mm*/
#define DMPAPER_PENV_10_ROTATED 118 /* PRC Envelope #10 Rotated 458 x 324 mm */
#define DMPAPER_LAST DMPAPER_PENV_10_ROTATED
#define DMPAPER_USER 256
/* bin selections */
#define DMBIN_FIRST DMBIN_UPPER
#define DMBIN_UPPER 1
#define DMBIN_ONLYONE 1
#define DMBIN_LOWER 2
#define DMBIN_MIDDLE 3
#define DMBIN_MANUAL 4
#define DMBIN_ENVELOPE 5
#define DMBIN_ENVMANUAL 6
#define DMBIN_AUTO 7
#define DMBIN_TRACTOR 8
#define DMBIN_SMALLFMT 9
#define DMBIN_LARGEFMT 10
#define DMBIN_LARGECAPACITY 11
#define DMBIN_CASSETTE 14
#define DMBIN_FORMSOURCE 15 /* not supported under windows 95 */
#define DMBIN_LAST DMBIN_FORMSOURCE
#define DMBIN_USER 256 /* device specific bins start here */
/* print qualities */
#define DMRES_DRAFT (-1)
#define DMRES_LOW (-2)
#define DMRES_MEDIUM (-3)
#define DMRES_HIGH (-4)
/* color enable/disable for color printers */
#define DMCOLOR_MONOCHROME 1
#define DMCOLOR_COLOR 2
/* duplex enable */
#define DMDUP_SIMPLEX 1
#define DMDUP_VERTICAL 2
#define DMDUP_HORIZONTAL 3
#define DMDUP_LAST DMDUP_HORIZONTAL
/* TrueType options */
#define DMTT_BITMAP 1 /* print TT fonts as graphics */
#define DMTT_DOWNLOAD 2 /* download TT fonts as soft fonts */
#define DMTT_SUBDEV 3 /* substitute device fonts for TT fonts */
#define DMTT_DOWNLOAD_OUTLINE 4 /* download TT fonts as outline soft fonts */
#define DMTT_LAST DMTT_DOWNLOAD_OUTLINE
/* Collation selections */
#define DMCOLLATE_TRUE 1 /* Collate multiple output pages */
#define DMCOLLATE_FALSE 0 /* Do not collate multiple output pages */
/* DEVMODE dmDisplayFlags flags */
#define DM_GRAYSCALE 0x00000001L /* Device is non-color */
#define DM_INTERLACED 0x00000002L /* device is interlaced */
/* ICM methods */
#define DMICMMETHOD_NONE 1 /* ICM disabled */
#define DMICMMETHOD_SYSTEM 2 /* ICM handled by system */
#define DMICMMETHOD_DRIVER 3 /* ICM handled by driver */
#define DMICMMETHOD_DEVICE 4 /* ICM handled by device */
#define DMICMMETHOD_LAST DMICMMETHOD_DEVICE
#define DMICMMETHOD_USER 256 /* Device-specific methods start here */
/* ICM Intents */
#define DMICM_SATURATE 1 /* Maximize color saturation */
#define DMICM_CONTRAST 2 /* Maximize color contrast */
#define DMICM_COLORMETRIC 3 /* Use specific color metric */
#define DMICM_LAST DMICM_COLORMETRIC
#define DMICM_USER 256 /* Device-specific intents start here */
/* Media types */
#define DMMEDIA_STANDARD 1 /* Standard paper */
#define DMMEDIA_TRANSPARENCY 2 /* Transparency */
#define DMMEDIA_GLOSSY 3 /* Glossy paper */
#define DMMEDIA_LAST DMMEDIA_GLOSSY
#define DMMEDIA_USER 256 /* Device-specific media start here */
/* Dither types */
#define DMDITHER_NONE 1 /* No dithering */
#define DMDITHER_COARSE 2 /* Dither with a coarse brush */
#define DMDITHER_FINE 3 /* Dither with a fine brush */
#define DMDITHER_LINEART 4 /* LineArt dithering */
#define DMDITHER_ERRORDIFFUSION 5 /* Error Diffusion */
/* id 6-9 are reserved for future use */
#define DMDITHER_GRAYSCALE 10 /* Device does grayscaling */
#define DMDITHER_LAST DMDITHER_GRAYSCALE
#define DMDITHER_USER 256 /* Device-specific dithers start here */
typedef struct tagDEVMODE
{
char dmDeviceName[CCHDEVICENAME];
UINT dmSpecVersion;
UINT dmDriverVersion;
UINT dmSize;
UINT dmDriverExtra;
DWORD dmFields;
int dmOrientation;
int dmPaperSize;
int dmPaperLength;
int dmPaperWidth;
int dmScale;
int dmCopies;
int dmDefaultSource;
int dmPrintQuality;
int dmColor;
int dmDuplex;
int dmYResolution;
int dmTTOption;
int dmCollate;
char dmFormName[CCHFORMNAME];
WORD dmLogPixels;
DWORD dmBitsPerPel;
DWORD dmPelsWidth;
DWORD dmPelsHeight;
DWORD dmDisplayFlags;
DWORD dmDisplayFrequency;
DWORD dmICMMethod;
DWORD dmICMIntent;
DWORD dmMediaType;
DWORD dmDitherType;
DWORD dmReserved1;
DWORD dmReserved2;
} DEVMODE;
typedef DEVMODE* PDEVMODE, NEAR* NPDEVMODE, FAR* LPDEVMODE;
/* mode selections for the device mode function */
#define DM_UPDATE 1
#define DM_COPY 2
#define DM_PROMPT 4
#define DM_MODIFY 8
#define DM_IN_BUFFER DM_MODIFY
#define DM_IN_PROMPT DM_PROMPT
#define DM_OUT_BUFFER DM_COPY
#define DM_OUT_DEFAULT DM_UPDATE
/* device capabilities indices */
#define DC_FIELDS 1
#define DC_PAPERS 2
#define DC_PAPERSIZE 3
#define DC_MINEXTENT 4
#define DC_MAXEXTENT 5
#define DC_BINS 6
#define DC_DUPLEX 7
#define DC_SIZE 8
#define DC_EXTRA 9
#define DC_VERSION 10
#define DC_DRIVER 11
#define DC_BINNAMES 12
#define DC_ENUMRESOLUTIONS 13
#define DC_FILEDEPENDENCIES 14
#define DC_TRUETYPE 15
#define DC_PAPERNAMES 16
#define DC_ORIENTATION 17
#define DC_COPIES 18
#define DC_BINADJUST 19
#define DC_EMF_COMPLIANT 20
#define DC_DATATYPE_PRODUCED 21
#define DC_ICC_MANUFACTURER 23
#define DC_ICC_MODEL 24
/* bit fields of the return value (DWORD) for DC_TRUETYPE */
#define DCTT_BITMAP 0x0000001L
#define DCTT_DOWNLOAD 0x0000002L
#define DCTT_SUBDEV 0x0000004L
#define DCTT_DOWNLOAD_OUTLINE 0x0000008L
/* return values for DC_BINADJUST */
#define DCBA_FACEUPNONE 0x0000
#define DCBA_FACEUPCENTER 0x0001
#define DCBA_FACEUPLEFT 0x0002
#define DCBA_FACEUPRIGHT 0x0003
#define DCBA_FACEDOWNNONE 0x0100
#define DCBA_FACEDOWNCENTER 0x0101
#define DCBA_FACEDOWNLEFT 0x0102
#define DCBA_FACEDOWNRIGHT 0x0103
/* export ordinal definitions */
#define PROC_EXTDEVICEMODE MAKEINTRESOURCE(90)
#define PROC_DEVICECAPABILITIES MAKEINTRESOURCE(91)
#define PROC_OLDDEVICEMODE MAKEINTRESOURCE(13)
/* define types of pointers to ExtDeviceMode() and DeviceCapabilities()
* functions
*/
/* BUGBUG, many of these params are const */
typedef UINT (CALLBACK* LPFNDEVMODE)(HWND, HMODULE, LPDEVMODE,
LPSTR, LPSTR, LPDEVMODE, LPSTR, UINT);
typedef DWORD (CALLBACK* LPFNDEVCAPS)(LPSTR, LPSTR, UINT, LPSTR, LPDEVMODE);
#ifndef NOEXTDEVMODEPROPSHEET
#include <prsht.h> /* for EXTDEVMODEPROPSHEET */
/* these are the names of the exports from the printer drivers */
#define PROCNAME_EXTDEVICEMODE "EXTDEVICEMODE"
#define PROCNAME_EXTDEVMODEPROPSHEET "EXTDEVICEMODEPROPSHEET"
/* this function is similar to ExtDeviceMode(), with the following
** changes:
**
** 1) No lpdmIn or lpdmOut. Changes are global
** 2) UI always displays, changes always saved (wMode is always
** DM_PROMPT | DM_UPDATE)
** 3) Driver enumerates property pages back to the caller via
** lpfnAddPage and lParam.
** lpfnAddPage is called by the driver to enumerate each HPROPSHEETPAGE
** lParam is passed back to lpfnAddPage.
*/
typedef int (WINAPI *LPFNEXTDEVICEMODEPROPSHEET)(
HWND hWnd,
HINSTANCE hinstDriver,
LPCSTR lpszDevice,
LPCSTR lpszPort,
DWORD dwReserved,
LPFNADDPROPSHEETPAGE lpfnAddPage, LPARAM lParam);
/* Ordinal for new entry point */
#define PROC_EXTDEVICEMODEPROPSHEET MAKEINTRESOURCE(95)
#endif /* NOEXTDEVMODEPROPSHEET */
HDC WINAPI ResetDC(HDC, const DEVMODE FAR*);
/* this structure is used by the GETSETSCREENPARAMS escape */
typedef struct tagSCREENPARAMS
{
int angle;
int frequency;
} SCREENPARAMS;
#ifdef __cplusplus
}
#endif /* __cplusplus */
#ifndef RC_INVOKED
#pragma pack()
#endif /* !RC_INVOKED */
#endif /* !_INC_PRINT */
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?