ICONINFO

typedef struct _ICONINFO { /* ii */

BOOL fIcon;

DWORD xHotspot;

DWORD yHotspot;

HBITMAP hbmMask;

HBITMAP hbmColor;

} ICONINFO;

The ICONINFO structure contains information about an icon or a cursor.

Members

fIcon

Specifies whether this is an icon or a cursor. A value of TRUE specifies an icon, FALSE a cursor.

xHotspot

Specifies the x, or horizontal, coordinate of a cursor's hotspot. If this is a icon, the hotspot is always in the center of the icon, and this field is ignored.

yHotspot

Specifies the y, or vertical, coordinate of the cursors's hotspot. If this is a icon, the hotspot is always in the center of the icon, and this field is ignored.

hbmMask

Specifies the icon mask bitmap. If this is a black and white icon, this mask is formatted so that the upper half is the icon AND mask, and the lower half is the icon XOR mask. Under this condition, the height should be an even multiple of two. If this is a color icon, this mask defines the AND mask of the icon ONLY.

hbmColor

Specifies the icon color bitmap. This field can be optional if this is a black and white icon. After the AND mask of hbmMask is applied with SRCAND to the destination, the color bitmap is XORed onto the destination with SRCINVERT.

Comments

Two API functions that make use of the ICONINFO data structure are CreateIconIndirect and GetIconInfo.

See Also

CreateIconIndirect, GetIconInfo