The MENUITEMINFO structure contains information about a menu item.
typedef struct tagMENUITEMINFO {
UINT cbSize; UINT fMask; UINT fType; UINT fState; UINT wID; HMENU hSubMenu; HBITMAP hbmpChecked; HBITMAP hbmpUnchecked; DWORD dwItemData; LPTSTR dwTypeData; UINT cch; } MENUITEMINFO, FAR *LPMENUITEMINFO;
Value |
Meaning |
MIIM_CHECKMARKS |
Retrieves or sets the hbmpChecked and hbmpUnchecked members. |
MIIM_DATA |
Retrieves or sets the dwItemData member. |
MIIM_ID |
Retrieves or sets the wID member. |
MIIM_STATE |
Retrieves or sets the fState member. |
MIIM_SUBMENU |
Retrieves or sets the hSubMenu member. |
MIIM_TYPE |
Retrieves or sets the fType and dwTypeData members. |
Value |
Meaning |
MFT_BITMAP |
Displays the menu item using a bitmap. The low-order word of the dwTypeData member is the bitmap handle, and the cch member is ignored. |
MFT_MENUBARBREAK |
Places the menu item on a new line (for a menu bar) or in a new column (for a drop-down menu, submenu, or shortcut menu). For a drop-down menu, submenu, or shortcut menu, a vertical line separates the new column from the old. |
MFT_MENUBREAK |
Places the menu item on a new line (for a menu bar) or in a new column (for a drop-down menu, submenu, or shortcut menu). For a drop-down menu, submenu, or shortcut menu, the columns are not separated by a vertical line. |
MFT_OWNERDRAW |
Assigns responsibility for drawing the menu item to the window that owns the menu. The window receives a WM_MEASUREITEM message before the menu is displayed for the first time, and a WM_DRAWITEM message whenever the appearance of the menu item must be updated. If this value is specified, the dwTypeData member contains an application-defined 32-bit value. |
MFT_RADIOCHECK |
Displays checked menu items using a radio-button mark instead of a check mark if the hbmpChecked member is NULL. |
MFT_RIGHTJUSTIFY |
Right-justifies the menu item and any subsequent items. This value is valid only if the menu item is in a menu bar. |
MFT_SEPARATOR |
Specifies that the menu item is a separator. A menu item separator appears as a horizontal dividing line. The dwTypeData and cch members are ignored. This value is valid only in a drop-down menu, submenu, or shortcut menu. |
MFT_STRING |
Displays the menu item using a text string. The dwTypeData member is the pointer to a null-terminated string, and the cch member is the length of the string. |
The MFT_BITMAP, MFT_SEPARATOR, and MFT_STRING values cannot be combined with
one another.
Value |
Meaning |
MFS_CHECKED |
Checks the menu item. For more information about checked menu items, see the hbmpChecked member. |
MFS_DEFAULT |
Specifies that the menu item is the default. A menu can contain only one default menu item, which is displayed in bold. |
MFS_DISABLED |
Disables the menu item so that it cannot be selected, but does not gray it. |
MFS_ENABLED |
Enables the menu item so that it can be selected. This is the default state. |
MFS_GRAYED |
Disables the menu item and grays it so that it cannot be selected. |
MFS_HILITE |
Highlights the menu item. |
MFS_UNCHECKED |
Unchecks the menu item. For more information about unchecked menu items, see the hbmpUnchecked member. |
MFS_UNHILITE |
Removes the highlight from the menu item. This is the default state. |
The MENUITEMINFO structure is used with the GetMenuItemInfo, InsertMenuItem, and SetMenuItemInfo functions.
GetMenuItemInfo, InsertMenuItem, SetMenuItemInfo, WM_DRAWITEM, WM_MEASUREITEM
file: /Techref/os/win/api/win32/struc/src/str11_5.htm, 9KB, , updated: 2000/4/7 11:20, local time: 2024/11/9 04:19,
3.147.80.249:LOG IN ©2024 PLEASE DON'T RIP! THIS SITE CLOSES OCT 28, 2024 SO LONG AND THANKS FOR ALL THE FISH!
|
©2024 These pages are served without commercial sponsorship. (No popup ads, etc...).Bandwidth abuse increases hosting cost forcing sponsorship or shutdown. This server aggressively defends against automated copying for any reason including offline viewing, duplication, etc... Please respect this requirement and DO NOT RIP THIS SITE. Questions? <A HREF="http://sxlist.com/techref/os/win/api/win32/struc/src/str11_5.htm"> MENUITEMINFO</A> |
Did you find what you needed? |
Welcome to sxlist.com!sales, advertizing, & kind contributors just like you! Please don't rip/copy (here's why Copies of the site on CD are available at minimal cost. |
Welcome to sxlist.com! |
.