user.odl
来自「The code for this article was written fo」· ODL 代码 · 共 2,094 行 · 第 1/5 页
ODL
2,094 行
/* Omitted
HMENU WINAPI LoadMenuIndirect(const void FAR*);
*/
[
usesgetlasterror,
entry("DestroyMenu"),
helpstring("Destroys the given menu and frees its resources"),
]
BOOL WINAPI DestroyMenu([in] HMENU hMenu);
[
usesgetlasterror,
entry("GetMenu"),
helpstring("Gets the handle of the menu of the given window"),
]
HMENU WINAPI GetMenu([in] HWND hwnd);
[
usesgetlasterror,
entry("SetMenu"),
helpstring("Sets the given window's menu to the given menu handle"),
]
BOOL WINAPI SetMenu([in] HWND hwnd, [in] HMENU hMenu);
[
usesgetlasterror,
entry("GetSystemMenu"),
helpstring("Gets handle of a copy of system menu, or restores the system menu if fRevert is true"),
]
HMENU WINAPI GetSystemMenu([in] HWND hwnd, [in] BOOL fRevert);
[
usesgetlasterror,
entry("DrawMenuBar"),
helpstring("Redraws the menu bar of the given window"),
]
void WINAPI DrawMenuBar([in] HWND hwnd);
[
usesgetlasterror,
entry("HiliteMenuItem"),
helpstring("Changes menu hilite of idHiliteItem in top level menu hMenu in hWnd window according to fuHilite flags (MF_ constant)"),
]
BOOL WINAPI HiliteMenuItem([in] HWND hwnd, [in] HMENU hMenu,
[in] UINT idHiliteItem,
[in] UINT fuHilite);
[
#if WIN32
usesgetlasterror,
entry("InsertMenuA"),
#else
entry("InsertMenu"),
#endif
helpstring("Inserts new item with ID idNewItem and content lpNewItem into menu hMenu before item idItem according to fuFlags"),
]
BOOL WINAPI InsertMenu([in] HMENU hMenu, [in] UINT idItem,
[in] UINT fuFlags, [in] UINT idNewItem,
[in] LPCSTR lpNewItem);
[
#if WIN32
usesgetlasterror,
entry("AppendMenuA"),
#else
entry("AppendMenu"),
#endif
helpstring("Appends new item with ID idNewItem and content lpNewItem to the end of menu hMenu according to fuFlags"),
]
BOOL WINAPI AppendMenu([in] HMENU hMenu, [in] UINT fuFlags,
[in] UINT idNewItem, [in] LPCSTR lpNewItem);
[
#if WIN32
usesgetlasterror,
entry("ModifyMenuA"),
#else
entry("ModifyMenu"),
#endif
helpstring("Modifies item with ID idItem of menu hMenu to ID idNewItem and content lpNewItem according to fuFlags"),
]
BOOL WINAPI ModifyMenu([in] HMENU hMenu, [in] UINT idItem,
[in] UINT fuFlags, [in] UINT idNewItem,
[in] LPCSTR lpNewItem);
[
usesgetlasterror,
entry("RemoveMenu"),
helpstring("Deletes item with ID idItem (according to fuFlags) from menu hMenu"),
]
BOOL WINAPI RemoveMenu([in] HMENU hMenu, [in] UINT idItem,
[in] UINT fuFlags);
[
usesgetlasterror,
entry("DeleteMenu"),
helpstring("Removes a popup menu item with ID idItem (according to fuFlags) from menu hMenu (should come from GetSubMenu) without deleting menu handle"),
]
BOOL WINAPI DeleteMenu([in] HMENU hMenu, [in] UINT idItem,
[in] UINT fuFlags);
/* Omit (obsolete)
BOOL WINAPI ChangeMenu([in] HMENU hMenu, UINT, LPCSTR, UINT, UINT);
*/
[
usesgetlasterror,
entry("EnableMenuItem"),
helpstring("Enables or disables item idEnableItem in hMenu according to uEnable flags"),
]
BOOL WINAPI EnableMenuItem([in] HMENU hMenu,
[in] UINT idEnableItem,
[in] UINT uEnable);
[
usesgetlasterror,
entry("CheckMenuItem"),
helpstring("Checks or unchecks item idCheckItem in hMenu according to uCheck flags"),
]
BOOL WINAPI CheckMenuItem([in] HMENU hMenu, [in] UINT idCheckItem,
[in] UINT uCheck);
[
usesgetlasterror,
entry("GetSubMenu"),
helpstring("Returns handle of handle of the submenu at position nPos in menu hMenu"),
]
HMENU WINAPI GetSubMenu([in] HMENU hMenu, [in] int nPos);
[
usesgetlasterror,
entry("GetMenuItemCount"),
helpstring("Returns the number of items in a menu"),
]
int WINAPI GetMenuItemCount([in] HMENU hMenu);
[
usesgetlasterror,
entry("GetMenuItemID"),
helpstring("Returns the ID of item as given position in a menu"),
]
UINT WINAPI GetMenuItemID([in] HMENU hMenu, [in] int pos);
[
#if WIN32
usesgetlasterror,
entry("GetMenuStringA"),
#else
entry("GetMenuString"),
#endif
helpstring("Copies the text of item idItem (according to fuFlags) in menu hMenu into the buffer lpsz"),
]
int WINAPI GetMenuString([in] HMENU hMenu, [in] UINT idItem,
[in, out] LPSTR lpsz, [in] int cbMax,
[in] UINT fuFlags);
[
usesgetlasterror,
entry("GetMenuState"),
helpstring("Returns bitflag state of item idItem in menu hMenu according to fuFlags"),
]
UINT WINAPI GetMenuState([in] HMENU hMenu, [in] UINT idItem,
[in] UINT fuFlags);
[
usesgetlasterror,
entry("SetMenuItemBitmaps"),
helpstring("Sets item idItem (according to fuFlags) of menu hMenu to the given bitmaps"),
]
BOOL WINAPI SetMenuItemBitmaps([in] HMENU hMenu, [in] UINT idItem,
[in] UINT fuFlags,
[in] HBITMAP hbmUnchecked,
[in] HBITMAP hbmChecked);
[
usesgetlasterror,
entry("GetMenuCheckMarkDimensions"),
helpstring("Returns dimensions of default checkmark bitmap with width in pixels in low word and height in high word"),
]
DWORD WINAPI GetMenuCheckMarkDimensions(VOID);
/* Omitted (can't implement)
BOOL WINAPI TrackPopupMenu([in] HMENU hMenu, [in] UINT fuFlags,
[in] int x, [in] int y,
[in] int nReserved, [in] HWND hwnd,
[in, out] LONG lprc);
*/
// ****** Scroll bar support ***
[
usesgetlasterror,
entry("SetScrollPos"),
helpstring("Sets the scroll box position and optionally redraws the scroll bar (see SB_ constants)"),
]
int WINAPI SetScrollPos([in] HWND hwnd, [in] int fnBar,
[in] int nPos, [in] BOOL fRepaint);
[
usesgetlasterror,
entry("GetScrollPos"),
helpstring("Gets the scroll box position (see SB_ constants)"),
]
int WINAPI GetScrollPos([in] HWND hwnd, [in] int fnBar);
[
usesgetlasterror,
entry("SetScrollRange"),
helpstring("Sets the minimum and maximum positions of a scroll bar and optionally redraws it (see SB_ constants)"),
]
void WINAPI SetScrollRange([in] HWND hwnd, [in] int fnBar,
[in] int nMin, [in] int nMax,
[in] BOOL fRedraw);
//@B GetScrollRange
[
usesgetlasterror,
entry("GetScrollRange"),
helpstring("Gets the minimum and maximum positions of a scroll bar"),
]
void WINAPI GetScrollRange([in] HWND hwnd, [in] int fnBar,
[out] int FAR * lpnMinPos,
[out] int FAR * lpnMaxPos);
//@E GetScrollRange
[
usesgetlasterror,
entry("ShowScrollBar"),
helpstring("Shows or hides a scroll bar (see SB_ constants)"),
]
void WINAPI ShowScrollBar([in] HWND hwnd, [in] int fnBar,
[in] BOOL fShow);
[
usesgetlasterror,
entry("EnableScrollBar"),
helpstring("Enables or disables scroll bar arrows (see SB_ and ESB_ constants)"),
]
BOOL WINAPI EnableScrollBar([in] HWND hwnd, [in] int fnSBFlags,
[in] UINT fuArrowFlags);
// ******* Clipboard manager ******
/*
// Clipboard Manager Functions
BOOL WINAPI OpenClipboard([in] HWND hwnd);
BOOL WINAPI CloseClipboard(void);
BOOL WINAPI EmptyClipboard(void);
HWND WINAPI GetOpenClipboardWindow(void);
HWND WINAPI GetClipboardOwner(void);
HWND WINAPI SetClipboardViewer(HWND);
HWND WINAPI GetClipboardViewer(void);
HANDLE WINAPI SetClipboardData(UINT, HANDLE);
HANDLE WINAPI GetClipboardData(UINT);
BOOL WINAPI IsClipboardFormatAvailable(UINT);
int WINAPI GetPriorityClipboardFormat(UINT FAR*, int);
UINT WINAPI RegisterClipboardFormat(LPCSTR);
int WINAPI CountClipboardFormats(void);
UINT WINAPI EnumClipboardFormats(UINT);
int WINAPI GetClipboardFormatName(UINT, LPSTR, int);
BOOL WINAPI ChangeClipboardChain([in] HWND hwnd, [in] HWND hwnd);
*/
// ****** Mouse cursor support **
[
#ifdef WIN32
usesgetlasterror,
entry("LoadCursorA"),
#else
entry("LoadCursor"),
#endif
helpstring("Load a cursor given by ID number from resource and return the cursor handle"),
]
HCURSOR WINAPI LoadCursorAsId([in] HINSTANCE hInst, [in] LONG idCursor);
[
#ifdef WIN32
usesgetlasterror,
entry("LoadCursorA"),
#else
entry("LoadCursor"),
#endif
helpstring("Load a cursor given by string name from resource and return the cursor handle"),
]
HCURSOR WINAPI LoadCursor([in] HINSTANCE hInst, [in] LPSTR pszCursor);
[
#ifdef WIN32
usesgetlasterror,
entry("LoadCursorA"),
#else
entry("LoadCursor"),
#endif
helpstring("Load a cursor given by string name from resource and return the cursor handle"),
]
HCURSOR WINAPI LoadCursorAsStr([in] HINSTANCE hInst, [in] LPSTR pszCursor);
[
usesgetlasterror,
entry("DestroyCursor"),
helpstring("Destroys a cursor previously created with CreateCursor or LoadCursor and frees its memory"),
]
BOOL WINAPI DestroyCursor([in] HCURSOR hcur);
[
usesgetlasterror,
entry("SetCursor"),
helpstring("Changes the current cursor to the given cursor or removes the cursor if NULL is passed (returns previous)"),
]
HCURSOR WINAPI SetCursor([in] HCURSOR hcur);
[
usesgetlasterror,
entry("GetCursor"),
helpstring("Gets the handle of the current cursor"),
]
HCURSOR WINAPI GetCursor(void);
/*
HCURSOR WINAPI CreateCursor([in] HINSTANCE hInst, int, int, int, int, const void FAR*, const void FAR*);
HCURSOR WINAPI CopyCursor([in] HINSTANCE hInst, [in] HCURSOR hcur);
*/
[
usesgetlasterror,
entry("ShowCursor"),
helpstring("Show or hide the mouse cursor"),
]
int WINAPI ShowCursor([in] BOOL bShow);
[
usesgetlasterror,
entry("SetCursorPos"),
helpstring("Sets the mouse cursor position"),
]
void WINAPI SetCursorPos([in] int x, [in] int y);
[
usesgetlasterror,
entry("GetCursorPos"),
helpstring("Gets the mouse cursor position"),
]
void WINAPI GetCursorPos([in, out] int FAR * lpPoint);
[
usesgetlasterror,
entry("ClipCursor"),
helpstring("Confines the mouse cursor to a given rectangle"),
]
void WINAPI ClipCursor([in] int FAR * lpRect);
[
usesgetlasterror,
entry("GetClipCursor"),
helpstring("Gets the rectangle where the mouse cursor is confined"),
]
void WINAPI GetClipCursor([in, out] int FAR * lpRect);
// ****** Bitmap resource **********
[
#ifdef WIN32
usesgetlasterror,
entry("LoadBitmapA"),
#else
entry("LoadBitmap"),
#endif
helpstring("Load a bitmap given by ID number from resource and return bitmap handle"),
]
HBITMAP WINAPI LoadBitmapAsId([in] HINSTANCE hInst, [in] LONG idBitmap);
[
#ifdef WIN32
usesgetlasterror,
entry("LoadBitmapA"),
#else
entry("LoadBitmap"),
#endif
helpstring("Load a bitmap given by string name from resource and return bitmap handle"),
]
HBITMAP WINAPI LoadBitmap([in] HINSTANCE hInst, [in] LPSTR pszBitmap);
[
#ifdef WIN32
usesgetlasterror,
entry("LoadBitmapA"),
#else
entry("LoadBitmap"),
#endif
helpstring("Load a bitmap given by string name from resource and return bitmap handle"),
]
HBITMAP WINAPI LoadBitmapAsStr([in] HINSTANCE hInst, [in] LPSTR pszBitmap);
// ****** String resource **********
[
#ifdef WIN32
usesgetlasterror,
entry("LoadStringA"),
#else
entry("LoadString"),
#endif
helpstring("Load a string given by ID number from resource into string buffer and return string length"),
]
int WINAPI LoadString([in] HINSTANCE hInst, [in] UINT idResource,
[in] LPCSTR lpszBuffer, [in] int cbBuffer);
// ****** Icon support **********
[
#ifdef WIN32
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?