📄 wingdi.h
字号:
DWORD DataBytes; /* number of raw data bytes */
DWORD InjectionPoint; /* injection point */
DWORD Flags; /* flags */
DWORD Reserved; /* reserved field - must be 0 */
/* Followed by raw data to be injected */
} PSINJECTDATA, *PPSINJECTDATA;
/*
* Constants for PSINJECTDATA.Flags field
*/
#define PSINJECT_APPEND 0
#define PSINJECT_REPLACE 1
/*
* Constants for PSINJECTDATA.InjectionPoint field
*/
/*
* The data injected at these points coexist with the output emitted
* by the driver for the same points.
*/
#define PSINJECT_BEGINSTREAM 0
#define PSINJECT_PSADOBE 1
#define PSINJECT_COMMENTS 2
#define PSINJECT_BEGINDEFAULTS 3
#define PSINJECT_ENDDEFAULTS 4
#define PSINJECT_BEGINPROLOG 5
#define PSINJECT_ENDPROLOG 6
#define PSINJECT_BEGINSETUP 7
#define PSINJECT_ENDSETUP 8
#define PSINJECT_ENDPAGECOMMENTS 9
#define PSINJECT_BEGINPAGESETUP 10
#define PSINJECT_ENDPAGESETUP 11
#define PSINJECT_SHOWPAGE 12
#define PSINJECT_PAGETRAILER 13
#define PSINJECT_TRAILER 14
#define PSINJECT_EOF 15
#define PSINJECT_ENDSTREAM 16
#define PSINJECT_VMSAVE 17
#define PSINJECT_VMRESTORE 18
/*
* The data injected at these points are appended to the output
* emitted by the driver for the same points. It will go into
* the document trailer section. They must be in the form of:
* %%+ resource-type resource-names
*/
#define PSINJECT_DOCNEEDEDRES 19
#define PSINJECT_DOCSUPPLIEDRES 20
/*
* The data injected at these points replaces the output emitted
* by the driver for the same points.
*/
#define PSINJECT_PAGES 21
#define PSINJECT_PAGEORDER 22
#define PSINJECT_ORIENTATION 23
#define PSINJECT_BOUNDINGBOX 24
#define PSINJECT_PAGENUMBER 25
#define PSINJECT_PAGEBBOX 26
#define PSINJECT_MAX 27
/* Flag returned from QUERYDIBSUPPORT */
#define QDI_SETDIBITS 1
#define QDI_GETDIBITS 2
#define QDI_DIBTOSCREEN 4
#define QDI_STRETCHDIB 8
/* Spooler Error Codes */
#define SP_NOTREPORTED 0x4000
#define SP_ERROR (-1)
#define SP_APPABORT (-2)
#define SP_USERABORT (-3)
#define SP_OUTOFDISK (-4)
#define SP_OUTOFMEMORY (-5)
#define PR_JOBSTATUS 0x0000
/* Object Definitions for EnumObjects() */
#define OBJ_PEN 1
#define OBJ_BRUSH 2
#define OBJ_DC 3
#define OBJ_METADC 4
#define OBJ_PAL 5
#define OBJ_FONT 6
#define OBJ_BITMAP 7
#define OBJ_REGION 8
#define OBJ_METAFILE 9
#define OBJ_MEMDC 10
#define OBJ_EXTPEN 11
#define OBJ_ENHMETADC 12
#define OBJ_ENHMETAFILE 13
/* xform stuff */
#define MWT_IDENTITY 1
#define MWT_LEFTMULTIPLY 2
#define MWT_RIGHTMULTIPLY 3
#define MWT_MIN MWT_IDENTITY
#define MWT_MAX MWT_RIGHTMULTIPLY
#define _XFORM_
typedef struct tagXFORM
{
FLOAT eM11;
FLOAT eM12;
FLOAT eM21;
FLOAT eM22;
FLOAT eDx;
FLOAT eDy;
} XFORM, *PXFORM, FAR *LPXFORM;
/* Bitmap Header Definition */
typedef struct tagBITMAP
{
LONG bmType;
LONG bmWidth;
LONG bmHeight;
LONG bmWidthBytes;
WORD bmPlanes;
WORD bmBitsPixel;
LPVOID bmBits;
} BITMAP, *PBITMAP, NEAR *NPBITMAP, FAR *LPBITMAP;
#include <pshpack1.h>
typedef struct tagRGBTRIPLE {
BYTE rgbtBlue;
BYTE rgbtGreen;
BYTE rgbtRed;
} RGBTRIPLE;
#include <poppack.h>
typedef struct tagRGBQUAD {
BYTE rgbBlue;
BYTE rgbGreen;
BYTE rgbRed;
BYTE rgbReserved;
} RGBQUAD;
typedef RGBQUAD FAR* LPRGBQUAD;
#if(WINVER >= 0x0400)
/* Image Color Matching color definitions */
#define CS_ENABLE 0x00000001L
#define CS_DISABLE 0x00000002L
#define CS_DELETE_TRANSFORM 0x00000003L
/* Logcolorspace signature */
#define LCS_SIGNATURE 'PSOC'
/* Logcolorspace lcsType values */
#define LCS_sRGB 'sRGB'
#define LCS_WINDOWS_COLOR_SPACE 'Win ' // Windows default color space
typedef LONG LCSCSTYPE;
#define LCS_CALIBRATED_RGB 0x00000000L
#define LCS_DEVICE_RGB 0x00000001L
#define LCS_DEVICE_CMYK 0x00000002L
typedef LONG LCSGAMUTMATCH;
#define LCS_GM_BUSINESS 0x00000001L
#define LCS_GM_GRAPHICS 0x00000002L
#define LCS_GM_IMAGES 0x00000004L
#define LCS_GM_ABS_COLORIMETRIC 0x00000008L
/* ICM Defines for results from CheckColorInGamut() */
#define CM_OUT_OF_GAMUT 255
#define CM_IN_GAMUT 0
/* UpdateICMRegKey Constants */
#define ICM_ADDPROFILE 1
#define ICM_DELETEPROFILE 2
#define ICM_QUERYPROFILE 3
#define ICM_SETDEFAULTPROFILE 4
#define ICM_REGISTERICMATCHER 5
#define ICM_UNREGISTERICMATCHER 6
#define ICM_QUERYMATCH 7
/* Macros to retrieve CMYK values from a COLORREF */
#define GetKValue(cmyk) ((BYTE)(cmyk))
#define GetYValue(cmyk) ((BYTE)((cmyk)>> 8))
#define GetMValue(cmyk) ((BYTE)((cmyk)>>16))
#define GetCValue(cmyk) ((BYTE)((cmyk)>>24))
#define CMYK(c,m,y,k) ((COLORREF)((((BYTE)(k)|((WORD)((BYTE)(y))<<8))|(((DWORD)(BYTE)(m))<<16))|(((DWORD)(BYTE)(c))<<24)))
typedef long FXPT16DOT16, FAR *LPFXPT16DOT16;
typedef long FXPT2DOT30, FAR *LPFXPT2DOT30;
/* ICM Color Definitions */
// The following two structures are used for defining RGB's in terms of CIEXYZ.
typedef struct tagCIEXYZ
{
FXPT2DOT30 ciexyzX;
FXPT2DOT30 ciexyzY;
FXPT2DOT30 ciexyzZ;
} CIEXYZ;
typedef CIEXYZ FAR *LPCIEXYZ;
typedef struct tagICEXYZTRIPLE
{
CIEXYZ ciexyzRed;
CIEXYZ ciexyzGreen;
CIEXYZ ciexyzBlue;
} CIEXYZTRIPLE;
typedef CIEXYZTRIPLE FAR *LPCIEXYZTRIPLE;
// The next structures the logical color space. Unlike pens and brushes,
// but like palettes, there is only one way to create a LogColorSpace.
// A pointer to it must be passed, its elements can't be pushed as
// arguments.
typedef struct tagLOGCOLORSPACEA {
DWORD lcsSignature;
DWORD lcsVersion;
DWORD lcsSize;
LCSCSTYPE lcsCSType;
LCSGAMUTMATCH lcsIntent;
CIEXYZTRIPLE lcsEndpoints;
DWORD lcsGammaRed;
DWORD lcsGammaGreen;
DWORD lcsGammaBlue;
CHAR lcsFilename[MAX_PATH];
} LOGCOLORSPACEA, *LPLOGCOLORSPACEA;
typedef struct tagLOGCOLORSPACEW {
DWORD lcsSignature;
DWORD lcsVersion;
DWORD lcsSize;
LCSCSTYPE lcsCSType;
LCSGAMUTMATCH lcsIntent;
CIEXYZTRIPLE lcsEndpoints;
DWORD lcsGammaRed;
DWORD lcsGammaGreen;
DWORD lcsGammaBlue;
WCHAR lcsFilename[MAX_PATH];
} LOGCOLORSPACEW, *LPLOGCOLORSPACEW;
#ifdef UNICODE
typedef LOGCOLORSPACEW LOGCOLORSPACE;
typedef LPLOGCOLORSPACEW LPLOGCOLORSPACE;
#else
typedef LOGCOLORSPACEA LOGCOLORSPACE;
typedef LPLOGCOLORSPACEA LPLOGCOLORSPACE;
#endif // UNICODE
#endif /* WINVER >= 0x0400 */
/* structures for defining DIBs */
typedef struct tagBITMAPCOREHEADER {
DWORD bcSize; /* used to get to color table */
WORD bcWidth;
WORD bcHeight;
WORD bcPlanes;
WORD bcBitCount;
} BITMAPCOREHEADER, FAR *LPBITMAPCOREHEADER, *PBITMAPCOREHEADER;
typedef struct tagBITMAPINFOHEADER{
DWORD biSize;
LONG biWidth;
LONG biHeight;
WORD biPlanes;
WORD biBitCount;
DWORD biCompression;
DWORD biSizeImage;
LONG biXPelsPerMeter;
LONG biYPelsPerMeter;
DWORD biClrUsed;
DWORD biClrImportant;
} BITMAPINFOHEADER, FAR *LPBITMAPINFOHEADER, *PBITMAPINFOHEADER;
#if(WINVER >= 0x0400)
typedef struct {
DWORD bV4Size;
LONG bV4Width;
LONG bV4Height;
WORD bV4Planes;
WORD bV4BitCount;
DWORD bV4V4Compression;
DWORD bV4SizeImage;
LONG bV4XPelsPerMeter;
LONG bV4YPelsPerMeter;
DWORD bV4ClrUsed;
DWORD bV4ClrImportant;
DWORD bV4RedMask;
DWORD bV4GreenMask;
DWORD bV4BlueMask;
DWORD bV4AlphaMask;
DWORD bV4CSType;
CIEXYZTRIPLE bV4Endpoints;
DWORD bV4GammaRed;
DWORD bV4GammaGreen;
DWORD bV4GammaBlue;
} BITMAPV4HEADER, FAR *LPBITMAPV4HEADER, *PBITMAPV4HEADER;
#endif /* WINVER >= 0x0400 */
#if (WINVER >= 0x0500)
typedef struct {
DWORD bV5Size;
LONG bV5Width;
LONG bV5Height;
WORD bV5Planes;
WORD bV5BitCount;
DWORD bV5Compression;
DWORD bV5SizeImage;
LONG bV5XPelsPerMeter;
LONG bV5YPelsPerMeter;
DWORD bV5ClrUsed;
DWORD bV5ClrImportant;
DWORD bV5RedMask;
DWORD bV5GreenMask;
DWORD bV5BlueMask;
DWORD bV5AlphaMask;
DWORD bV5CSType;
CIEXYZTRIPLE bV5Endpoints;
DWORD bV5GammaRed;
DWORD bV5GammaGreen;
DWORD bV5GammaBlue;
DWORD bV5Intent;
DWORD bV5ProfileData;
DWORD bV5ProfileSize;
DWORD bV5Reserved;
} BITMAPV5HEADER, FAR *LPBITMAPV5HEADER, *PBITMAPV5HEADER;
// Values for bV5CSType
#define PROFILE_LINKED 'LINK'
#define PROFILE_EMBEDDED 'MBED'
#endif
/* constants for the biCompression field */
#define BI_RGB 0L
#define BI_RLE8 1L
#define BI_RLE4 2L
#define BI_BITFIELDS 3L
#if (_WIN32_WINNT >= 0x0400)
#endif
typedef struct tagBITMAPINFO {
BITMAPINFOHEADER bmiHeader;
RGBQUAD bmiColors[1];
} BITMAPINFO, FAR *LPBITMAPINFO, *PBITMAPINFO;
typedef struct tagBITMAPCOREINFO {
BITMAPCOREHEADER bmciHeader;
RGBTRIPLE bmciColors[1];
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -