A menu resource contains data for each pop-up item in a menu. The first 16 bits
indicate whether the item is grayed, inactive, checked, and so on. This data also
includes a string that appears in the rectangle corresponding to that item. A
PopupMenuItem structure has the following form:
struct PopupMenuItem {
WORD fItemFlags;
char szItemText[];
};
Following are the members in the PopupMenuItem structure:
fItemFlags
Specifies menu-item information. This member can have one or more of the following values:
Value | Meaning |
MF_GRAYED | Item is grayed. |
MF_DISABLED | Item is inactive. |
MF_CHECKED | Item can be checked. |
MF_POPUP | Item is a popup (must be specified for pop-up items). |
MF_MENUBARBREAK | Item is a menu-bar break. |
MF_MENUBREAK | Item is a menu break. |
MF_END | Item ends the menu. |
szItemText
Specifies a null-terminated string that appears in the menu and identifies the menu item. There is no fixed limit on the size of this string.