📄 gdi.odl
字号:
[
usesgetlasterror,
entry("SetPixel"),
helpstring("Sets pixel at (x,y) to given color"),
]
COLORREF WINAPI SetPixel([in] HDC hdc,
[in] int nXPos, [in] int nYPos,
[in] COLORREF clrref);
[
usesgetlasterror,
entry("GetPixel"),
helpstring("Returns color of pixel at (x,y)"),
]
COLORREF WINAPI GetPixel([in] HDC hdc,
[in] int nXPos, [in] int nYPos);
[
usesgetlasterror,
entry("SetStretchBltMode"),
helpstring("Sets the mode for compressing blits (see STRETCH_ANDSCANS)"),
]
int WINAPI SetStretchBltMode([in] HDC hdc, [in] int fnStretchMode);
[
usesgetlasterror,
entry("GetStretchBltMode"),
helpstring("Gets the mode for compressing blits (see STRETCH_ANDSCANS)"),
]
int WINAPI GetStretchBltMode([in] HDC hdc);
/*
DWORD WINAPI SetBitmapDimension([in] HBITMAP hbm, int, int);
DWORD WINAPI GetBitmapDimension([in] HBITMAP hbm);
BOOL WINAPI SetBitmapDimensionEx([in] HBITMAP hbm, int, int, SIZE FAR *);
BOOL WINAPI GetBitmapDimensionEx([in] HBITMAP hbm, SIZE FAR *);
int WINAPI SetROP2([in] HDC hdc, int);
int WINAPI GetROP2([in] HDC hdc);
*/
[
usesgetlasterror,
entry("SetBitmapBits"),
helpstring("Gets version numbers of Windows and MS-DOS"),
]
LONG WINAPI SetBitmapBits([in] HBITMAP hbm, [in] LONG cbBuffer, [out] BYTE FAR * lpvBits);
[
usesgetlasterror,
entry("GetBitmapBits"),
helpstring("Fills buffer with bits from the specified bitmap"),
]
LONG WINAPI GetBitmapBits([in] HBITMAP hbm, [in] LONG cbBuffer, [in] BYTE FAR * lpvBits);
/*
int WINAPI SetDIBits([in] HDC hdc, [in] HBITMAP hbm, UINT, UINT, const void FAR *, BITMAPINFO FAR *, UINT);
int WINAPI GetDIBits([in] HDC hdc, [in] HBITMAP hbm, UINT, UINT, void FAR *, BITMAPINFO FAR *, UINT);
int WINAPI SetDIBitsToDevice([in] HDC hdc, int, int, int, int, int, int, UINT, UINT,
void FAR *, BITMAPINFO FAR *, UINT);
*/
// ****** Metafile support *****
[
#if WIN32
usesgetlasterror,
entry("CreateMetaFileA"),
#else
entry("CreateMetaFile"),
#endif
helpstring("Returns a metafile HDC for lpszFile (or for a memory metafile if NULL)"),
]
HDC WINAPI CreateMetaFile([in] LPCSTR lpszFile);
[
usesgetlasterror,
entry("CloseMetaFile"),
helpstring("Closes metafile HDC and returns a metafile handle"),
]
HMETAFILE WINAPI CloseMetaFile([in] HDC hdc);
[
usesgetlasterror,
entry("DeleteMetaFile"),
helpstring("Invalidates the metafile handle"),
]
BOOL WINAPI DeleteMetaFile([in] HMETAFILE hmf);
[
usesgetlasterror,
entry("PlayMetaFile"),
helpstring("Plays hmf metafile on hdc device"),
]
BOOL WINAPI PlayMetaFile([in] HDC hdc, [in] HMETAFILE hmf);
[
#if WIN32
usesgetlasterror,
entry("GetMetaFileA"),
#else
entry("GetMetaFile"),
#endif
helpstring("Creates handle for lpszFile metafile"),
]
HMETAFILE WINAPI GetMetaFile([in] LPCSTR lpszFile);
[
#if WIN32
usesgetlasterror,
entry("CopyMetaFileA"),
#else
entry("CopyMetaFile"),
#endif
helpstring("Copies source metafile to a file and returns handle of new metafile"),
]
HMETAFILE WINAPI CopyMetaFile([in] HMETAFILE hmfSrc,
[in] LPCSTR lpszFile);
#if WIN32
[
usesgetlasterror,
entry("GetMetaFileBitsEx"),
helpstring("Returns global memory containing metafile as bits"),
]
UINT WINAPI GetMetaFileBitsEx([in] HMETAFILE hmf, [in] UINT nSize,
[in] LPVOID lpvData);
[
usesgetlasterror,
entry("SetMetaFileBitsEx"),
helpstring("Creates a metafile from global memory"),
]
HMETAFILE WINAPI SetMetaFileBitsEx([in] UINT nSize, [in] LPVOID lpData);
#else
[
usesgetlasterror,
entry("GetMetaFileBits"),
helpstring("Returns global memory handle of metafile as bits"),
]
HGLOBAL WINAPI GetMetaFileBits([in] HMETAFILE hmf);
[
usesgetlasterror,
entry("SetMetaFileBitsEx"),
helpstring("Creates a metafile from data of global memory handle"),
]
HMETAFILE WINAPI SetMetaFileBits([in] HGLOBAL hgb);
[
usesgetlasterror,
entry("SetMetaFileBitsBetter"),
helpstring("Creates a metafile from data of global memory handle owned by GDI (use for OLE)"),
]
HMETAFILE WINAPI SetMetaFileBitsBetter([in] HGLOBAL hgb);
#endif
/*
DECLARE_HANDLE(HMETAFILE);
// Clipboard Metafile Picture Structure
typedef struct tagMETAFILEPICT
{
int mm;
int xExt;
int yExt;
HMETAFILE hMF;
} METAFILEPICT;
typedef METAFILEPICT FAR * LPMETAFILEPICT;
typedef struct tagMETAHEADER
{
UINT mtType;
UINT mtHeaderSize;
UINT mtVersion;
DWORD mtSize;
UINT mtNoObjects;
DWORD mtMaxRecord;
UINT mtNoParameters;
} METAHEADER;
typedef struct tagHANDLETABLE
{
HGDIOBJ objectHandle[1];
} HANDLETABLE;
typedef HANDLETABLE* PHANDLETABLE;
typedef HANDLETABLE FAR * LPHANDLETABLE;
typedef struct tagMETARECORD
{
DWORD rdSize;
UINT rdFunction;
UINT rdParm[1];
} METARECORD;
typedef METARECORD* PMETARECORD;
typedef METARECORD FAR * LPMETARECORD;
void WINAPI PlayMetaFileRecord([in] HDC hdc, HANDLETABLE FAR *, METARECORD FAR *, UINT);
*/
/* Omitted
typedef int (CALLBACK* MFENUMPROC)([in] HDC hdc, HANDLETABLE FAR *, METARECORD FAR *, int, LPARAM);
BOOL WINAPI EnumMetaFile([in] HDC hdc, [in] HMETAFILE hmf, MFENUMPROC, LPARAM);
*/
// ****** Enhanced Metafile support *****
#if WIN32
[
usesgetlasterror,
entry("CloseEnhMetaFile"),
helpstring("Closes an enhanced-metafile device context and returns a handle to the metafile."),
]
HENHMETAFILE WINAPI CloseEnhMetaFile([in] HDC hdc);
[
usesgetlasterror,
entry("CopyEnhMetaFileA"),
helpstring("Copies contents of enhanced-format metafile to specified file."),
]
HENHMETAFILE WINAPI CopyEnhMetaFile([in] HENHMETAFILE hemf,
[in] LPCSTR lpszFile);
[
usesgetlasterror,
entry("CreateEnhMetaFileA"),
helpstring("Creates device context for enhanced-format metafile."),
]
HDC WINAPI CreateEnhMetaFile([in] HDC hdc, [in] LPCSTR lpFileName,
[in] int * lpRect,
[in] LPCSTR lpDescription);
[
usesgetlasterror,
entry("DeleteEnhMetaFile"),
helpstring("Deletes an enhanced-format metafile or metafile handle."),
]
BOOL WINAPI DeleteEnhMetaFile([in] HENHMETAFILE hemf);
/*
BOOL WINAPI EnumEnhMetaFile([in] HDC hdc, [in] HENHMETAFILE hemf, ENHMFENUMPROC,
LPVOID, CONST RECT *);
*/
[
usesgetlasterror,
entry("GetEnhMetaFileA"),
helpstring("Creates handle for given file-based enhanced-format metafile"),
]
HENHMETAFILE WINAPI GetEnhMetaFile([in] LPCSTR lpszMetaFile);
[
usesgetlasterror,
entry("GetEnhMetaFileBits"),
helpstring("Copies contents of specified enhanced-format metafile into buffer"),
]
UINT WINAPI GetEnhMetaFileBits([in] HENHMETAFILE hemf,
[in] UINT cbBuffer,
[out] BYTE * lpbBuffer);
[
usesgetlasterror,
entry("GetEnhMetaFileDescriptionA"),
helpstring("Copies optional text description from an enhanced-format metafile to a specified buffer.")
]
UINT WINAPI GetEnhMetaFileDescription([in] HENHMETAFILE hemf,
[in] UINT cchBuffer,
[out] LPSTR lpszDescription);
/*
[
usesgetlasterror,
entry("GetEnhMetaFileHeader"),
helpstring(""),
]
UINT WINAPI GetEnhMetaFileHeader([in] HENHMETAFILE hemf,
[in] UINT cbBuffer,
[in] LPENHMETAHEADER lpemnh);
[
usesgetlasterror,
entry("GetEnhMetaFilePaletteEntries"),
helpstring(""),
]
UINT WINAPI GetEnhMetaFilePaletteEntries([in] HENHMETAFILE hemf,
UINT,
LPPALETTEENTRY );
*/
[
usesgetlasterror,
entry("GetWinMetaFileBits"),
helpstring("Converts enhanced-format records from metafile into Windows-format records and copies converted records to specified buffer."),
]
UINT WINAPI GetWinMetaFileBits([in] HENHMETAFILE hemf,
[in] UINT cbBuffer,
[out] BYTE * lpbBuffer,
[in] INT fnMapMode,
[in] HDC hdc);
[
usesgetlasterror,
entry("PlayEnhMetaFile"),
helpstring("Displays the picture in specified enhanced-format metafile."),
]
BOOL WINAPI PlayEnhMetaFile([in] HDC hdc, [in] HENHMETAFILE hemf,
[in] int * lpRect);
/*
[
usesgetlasterror,
entry("PlayEnhMetaFileRecord"),
helpstring(""),
]
BOOL WINAPI PlayEnhMetaFileRecord([in] HDC hdc, LPHANDLETABLE, CONST ENHMETARECORD *, UINT);
*/
[
usesgetlasterror,
entry("SetEnhMetaFileBits"),
helpstring("Creates memory-based enhanced-format metafile from supplied data."),
]
HENHMETAFILE WINAPI SetEnhMetaFileBits([in] UINT cbBuffer,
[out] BYTE * lpData);
/*
[
usesgetlasterror,
entry("SetWinMetaFileBits"),
helpstring(""),
]
HENHMETAFILE WINAPI SetWinMetaFileBits([in] UINT cbBuffer,
[in] BYTE * lpbBuffer,
[in] HDC hdc,
[in] long * lpmfp);
*/
[
usesgetlasterror,
entry("GdiComment"),
helpstring("Copies a comment from a buffer into specified enhanced-format metafile."),
]
BOOL WINAPI GdiComment([in] HDC hdc, [in] UINT cbSize,
[in] BYTE * lpData);
#endif
// ****** Printing support ******
/*
typedef struct
{
int cbSize;
LPCSTR lpszDocName;
LPCSTR lpszOutput;
} DOCINFO;
typedef DOCINFO FAR * LPDOCINFO;
int WINAPI StartDoc([in] HDC hdc, DOCINFO FAR *);
int WINAPI StartPage([in] HDC hdc);
int WINAPI EndPage([in] HDC hdc);
int WINAPI EndDoc([in] HDC hdc);
int WINAPI AbortDoc([in] HDC hdc);
*/
/* Omitted
typedef BOOL (CALLBACK* ABORTPROC)([in] HDC hdc, int);
int WINAPI SetAbortProc([in] HDC hdc, ABORTPROC);
*/
/*
HANDLE WINAPI SpoolFile(LPSTR, LPSTR, LPSTR, LPSTR);
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -