📄 gdi.odl
字号:
[
uuid(54674044-3A82-101B-8181-00AA003743D3),
helpstring("Windows GDI Functions"),
#ifdef WIN32
dllname("GDI32.DLL")
#else
dllname("GDI.EXE")
#endif
]
module GDI {
// ****** DC Management *******
/*
HDC WINAPI CreateDC(LPCSTR, LPCSTR, LPCSTR, const void FAR *);
HDC WINAPI CreateIC(LPCSTR, LPCSTR, LPCSTR, const void FAR *);
*/
[
usesgetlasterror,
entry("CreateCompatibleDC"),
helpstring("Creates a memory DC compatible with a given DC"),
]
HDC WINAPI CreateCompatibleDC([in] HDC hdc);
[
usesgetlasterror,
entry("DeleteDC"),
helpstring("Deletes a given DC"),
]
BOOL WINAPI DeleteDC([in] HDC hdc);
/*
DWORD WINAPI GetDCOrg([in] HDC hdc);
int WINAPI SaveDC([in] HDC hdc);
BOOL WINAPI RestoreDC([in] HDC hdc, int);
*/
/* Omitted
int WINAPI MulDiv(int, int, int);
*/
/* Omitted
// Drawing bounds accumulation APIs
UINT WINAPI SetBoundsRect(HDC hDC, const RECT FAR * lprcBounds, UINT flags);
UINT WINAPI GetBoundsRect(HDC hDC, RECT FAR * lprcBounds, UINT flags);
*/
// ****** Device Capabilities *******
[
usesgetlasterror,
entry("GetDeviceCaps"),
helpstring("Gets the capabilitis of given DC"),
]
int WINAPI GetDeviceCaps([in] HDC hdc, [in] int iCapability);
// ****** Coordinate transformation support *********
/*
int WINAPI SetMapMode([in] HDC hdc, int);
int WINAPI GetMapMode([in] HDC hdc);
DWORD WINAPI SetWindowOrg([in] HDC hdc, int, int);
DWORD WINAPI GetWindowOrg([in] HDC hdc);
DWORD WINAPI SetWindowExt([in] HDC hdc, int, int);
DWORD WINAPI GetWindowExt([in] HDC hdc);
DWORD WINAPI OffsetWindowOrg([in] HDC hdc, int, int);
DWORD WINAPI ScaleWindowExt([in] HDC hdc, int, int, int, int);
DWORD WINAPI SetViewportOrg([in] HDC hdc, int, int);
DWORD WINAPI GetViewportOrg([in] HDC hdc);
DWORD WINAPI SetViewportExt([in] HDC hdc, int, int);
DWORD WINAPI GetViewportExt([in] HDC hdc);
DWORD WINAPI OffsetViewportOrg([in] HDC hdc, int, int);
DWORD WINAPI ScaleViewportExt([in] HDC hdc, int, int, int, int);
BOOL WINAPI SetWindowOrgEx([in] HDC hdc, int, int, POINT FAR *);
BOOL WINAPI GetWindowOrgEx([in] HDC hdc, POINT FAR *);
BOOL WINAPI SetWindowExtEx([in] HDC hdc, int, int, SIZE FAR *);
BOOL WINAPI GetWindowExtEx([in] HDC hdc, SIZE FAR *);
BOOL WINAPI OffsetWindowOrgEx([in] HDC hdc, int, int, POINT FAR *);
BOOL WINAPI ScaleWindowExtEx([in] HDC hdc, int, int, int, int, SIZE FAR *);
BOOL WINAPI SetViewportExtEx([in] HDC hdc, int, int, SIZE FAR *);
BOOL WINAPI GetViewportExtEx([in] HDC hdc, SIZE FAR *);
BOOL WINAPI SetViewportOrgEx([in] HDC hdc, int, int, POINT FAR *);
BOOL WINAPI GetViewportOrgEx([in] HDC hdc, POINT FAR *);
BOOL WINAPI OffsetViewportOrgEx([in] HDC hdc, int, int, POINT FAR *);
BOOL WINAPI ScaleViewportExtEx([in] HDC hdc, int, int, int, int, SIZE FAR *);
BOOL WINAPI DPtoLP([in] HDC hdc, POINT FAR *, int);
BOOL WINAPI LPtoDP([in] HDC hdc, POINT FAR *, int);
*/
// ****** Color support *******
[
usesgetlasterror,
entry("GetNearestColor"),
helpstring("Returns color from system palette that will be displayed when the given color value is used"),
]
COLORREF WINAPI GetNearestColor([in] HDC hdc, [in] COLORREF clrref);
// ****** GDI Object Support ********
[
usesgetlasterror,
entry("IsGDIObject"),
helpstring("Returns TRUE if argument is handle to GDI object"),
]
BOOL WINAPI IsGDIObject([in] HGDIOBJ hgidobj);
[
usesgetlasterror,
entry("GetStockObject"),
helpstring("Returns the handle of stock pen, brush or font specified by fnObject constant"),
]
HGDIOBJ WINAPI GetStockObject([in] int fnObject);
[
usesgetlasterror,
entry("DeleteObject"),
helpstring("Deletes a given GDI object"),
]
BOOL WINAPI DeleteObject([in] HGDIOBJ hgdiobj);
[
usesgetlasterror,
entry("SelectObject"),
helpstring("Selects a given GDI object into a DC, returning the previous object"),
]
HGDIOBJ WINAPI SelectObject([in] HDC hdc, [in] HGDIOBJ hgdiobj);
/*
int WINAPI GetObject(HGDIOBJ, int, void FAR *);
BOOL WINAPI UnrealizeObject(HGDIOBJ);
*/
/* Omitted
typedef (CALLBACK* GOBJENUMPROC)(void FAR *, LPARAM);
int WINAPI EnumObjects([in] HDC hdc, int, GOBJENUMPROC, LPARAM);
*/
// ****** Pen support **********
/*
// Logical Pen
typedef struct tagLOGPEN
{
UINT lopnStyle;
POINT lopnWidth;
COLORREF lopnColor;
} LOGPEN;
typedef LOGPEN* PLOGPEN;
typedef LOGPEN NEAR * NPLOGPEN;
typedef LOGPEN FAR * LPLOGPEN;
HPEN WINAPI CreatePen(int, int, [in] COLORREF clrref);
HPEN WINAPI CreatePenIndirect(LOGPEN FAR *);
*/
// ****** Brush support *********
/*
// Logical Brush (or Pattern)
typedef struct tagLOGBRUSH
{
UINT lbStyle;
COLORREF lbColor;
int lbHatch;
} LOGBRUSH;
typedef LOGBRUSH* PLOGBRUSH;
typedef LOGBRUSH NEAR * NPLOGBRUSH;
typedef LOGBRUSH FAR * LPLOGBRUSH;
typedef LOGBRUSH PATTERN;
typedef PATTERN* PPATTERN;
typedef PATTERN NEAR * NPPATTERN;
typedef PATTERN FAR * LPPATTERN;
HBRUSH WINAPI CreateSolidBrush([in] COLORREF clrref);
HBRUSH WINAPI CreateHatchBrush(int, [in] COLORREF clrref);
HBRUSH WINAPI CreatePatternBrush([in] HBITMAP hbm);
HBRUSH WINAPI CreateDIBPatternBrush(HGLOBAL, UINT);
HBRUSH WINAPI CreateBrushIndirect(LOGBRUSH FAR *);
DWORD WINAPI SetBrushOrg([in] HDC hdc, int, int);
DWORD WINAPI GetBrushOrg([in] HDC hdc);
BOOL WINAPI GetBrushOrgEx([in] HDC hdc, POINT FAR *);
*/
// ****** Region support *******
/*
HRGN WINAPI CreateRectRgn(int, int, int, int);
HRGN WINAPI CreateRectRgnIndirect(const RECT FAR *);
HRGN WINAPI CreateEllipticRgnIndirect(const RECT FAR *);
HRGN WINAPI CreateEllipticRgn(int, int, int, int);
HRGN WINAPI CreatePolygonRgn(const POINT FAR *, int, int);
HRGN WINAPI CreatePolyPolygonRgn(const POINT FAR *, const int FAR *, int, int);
HRGN WINAPI CreateRoundRectRgn(int, int, int, int, int, int);
void WINAPI SetRectRgn(HRGN, int, int, int, int);
int WINAPI CombineRgn(HRGN, HRGN, HRGN, int);
BOOL WINAPI EqualRgn(HRGN, HRGN);
int WINAPI OffsetRgn(HRGN, int, int);
int WINAPI GetRgnBox(HRGN, RECT FAR *);
BOOL WINAPI RectInRegion(HRGN, const RECT FAR *);
BOOL WINAPI PtInRegion(HRGN, int, int);
*/
// ****** Color Palette Support *********
/*
//define PALETTERGB(r,g,b) (0x02000000L | RGB(r,g,b))
//define PALETTEINDEX(i) ((COLORREF)(0x01000000L | (DWORD)(WORD)(i)))
typedef struct tagPALETTEENTRY
{
BYTE peRed;
BYTE peGreen;
BYTE peBlue;
BYTE peFlags;
} PALETTEENTRY;
typedef PALETTEENTRY FAR * LPPALETTEENTRY;
// Logical Palette
typedef struct tagLOGPALETTE
{
WORD palVersion;
WORD palNumEntries;
PALETTEENTRY palPalEntry[1];
} LOGPALETTE;
typedef LOGPALETTE* PLOGPALETTE;
typedef LOGPALETTE NEAR * NPLOGPALETTE;
typedef LOGPALETTE FAR * LPLOGPALETTE;
HPALETTE WINAPI CreatePalette(const LOGPALETTE FAR *);
HPALETTE WINAPI SelectPalette([in] HDC hdc, HPALETTE, BOOL);
UINT WINAPI RealizePalette([in] HDC hdc);
int WINAPI UpdateColors([in] HDC hdc);
void WINAPI AnimatePalette(HPALETTE, UINT, UINT, const PALETTEENTRY FAR *);
UINT WINAPI SetPaletteEntries(HPALETTE, UINT, UINT, const PALETTEENTRY FAR *);
UINT WINAPI GetPaletteEntries(HPALETTE, UINT, UINT, PALETTEENTRY FAR *);
UINT WINAPI GetNearestPaletteIndex(HPALETTE, [in] COLORREF clrref);
BOOL WINAPI ResizePalette(HPALETTE, UINT);
UINT WINAPI GetSystemPaletteEntries([in] HDC hdc, UINT, UINT, PALETTEENTRY FAR *);
UINT WINAPI GetSystemPaletteUse([in] HDC hdc);
UINT WINAPI SetSystemPaletteUse([in] HDC hdc, UINT);
*/
// ****** Clipping support ******
/*
int WINAPI SelectClipRgn([in] HDC hdc, HRGN);
int WINAPI GetClipBox([in] HDC hdc, RECT FAR *);
int WINAPI IntersectClipRect([in] HDC hdc, int, int, int, int);
int WINAPI OffsetClipRgn([in] HDC hdc, int, int);
int WINAPI ExcludeClipRect([in] HDC hdc, int, int, int, int);
BOOL WINAPI PtVisible([in] HDC hdc, int, int);
BOOL WINAPI RectVisible([in] HDC hdc, const RECT FAR *);
*/
// ****** General drawing support *******
[
usesgetlasterror,
entry("MoveToEx"),
helpstring("Moves current position to (x,y) without displaying; return last position in lpPoint"),
]
BOOL WINAPI MoveToEx([in] HDC hdc, [in] int X, [in] int Y,
[in, out] int * lpPoint);
[
usesgetlasterror,
entry("MoveToEx"),
helpstring("Moves current position to (x,y) without displaying (ignore compatibility null parameter)"),
]
BOOL WINAPI MoveToNull([in] HDC hdc, [in] int X, [in] int Y,
[in] long lpNull);
#ifndef WIN32
[
usesgetlasterror,
entry("MoveTo"),
helpstring("Moves current position to (x,y)"),
]
DWORD WINAPI MoveTo([in] HDC hdc, [in] int X, [in] int Y);
#endif
[
usesgetlasterror,
entry("LineTo"),
helpstring("Draws from current position to (x,y) with current pen"),
]
BOOL WINAPI LineTo([in] HDC hdc, [in] int X, [in] int Y);
#ifndef WIN32
[
usesgetlasterror,
entry("GetCurrentPosition"),
helpstring("Gets current position packed in a DWORD"),
]
DWORD WINAPI GetCurrentPosition([in] HDC hdc);
#endif
//@B GetCurrentPositionEx
[
usesgetlasterror,
entry("GetCurrentPositionEx"),
helpstring("Get current position in a POINT structure"),
]
BOOL WINAPI GetCurrentPositionEx([in] HDC hdc,
[in, out] int FAR * lpPoint);
//@E GetCurrentPositionEx
// BOOL WINAPI Polyline([in] HDC hdc, const POINT FAR *, int);
#ifdef WIN32
// BOOL WINAPI PolylineTo([in] HDC hdc, CONST POINT *, DWORD);
[
usesgetlasterror,
entry("PolyBezier"),
helpstring("Draws Bezier curve controlled by array of points (cPoint specified size of array)"),
]
BOOL WINAPI PolyBezier([in] HDC hdc, [in] int * lppt,
[in] DWORD cPoints);
[
usesgetlasterror,
entry("PolyBezierTo"),
helpstring("Draws Bezier curve controlled by array of points (cPoint specified size of array) and moves to last point"),
]
BOOL WINAPI PolyBezierTo([in] HDC hdc, [in] int * lppt,
[in] DWORD cPoints);
#endif
[
usesgetlasterror,
entry("Rectangle"),
helpstring("Draws rectangle around given points with current pen filled with current brush"),
]
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -