NMLVCUSTOMDRAW Structure
NMLVCUSTOMDRAW Structure

Contains information specific to an NM_CUSTOMDRAW (list view) notification message sent by a list-view control.

Syntax

typedef struct tagNMLVCUSTOMDRAW {
    NMCUSTOMDRAW nmcd;
    COLORREF clrText;
    COLORREF clrTextBk;
#if (_WIN32_IE >= 0x0400)
    int iSubItem;
#endif
#if (_WIN32_IE >= 0x560)
    DWORD dwItemType;
    // Item Custom Draw	
    COLORREF clrFace;
    int iIconEffect;
    int iIconPhase;
    int iPartId;
    int iStateId:
    // Group Custom Draw
    RECT rcText;
    UINT uAlign;
#endif
} NMLVCUSTOMDRAW, *LPNMLVCUSTOMDRAW;

Members

nmcd
NMCUSTOMDRAW structure that contains general custom draw information.
clrText
COLORREF value representing the color that will be used to display text foreground in the list-view control.
clrTextBk
COLORREF value representing the color that will be used to display text background in the list-view control. In Version 6.0., this member is ignored if the background image is set with the LVM_SETBKIMAGE message.
iSubItem
Version 4.71. Index of the subitem that is being drawn. If the main item is being drawn, this member will be zero.
dwItemType
Version 6.0. DWORD that contains the type of the item to draw. This member can be one of the following values.
LVCDI_ITEM
An item is to be drawn.
LVCDI_GROUP
A group is to be drawn.
LVCDI_ITEMSLIST
Every item is to be drawn.
clrFace
Version 6.0. COLORREF value representing the color that will be used to display the face of an item.
iIconEffect
Version 6.0.  Value of type int that specifies the effect that is applied to an icon, such as Glow, Shadow, or Pulse.
iIconPhase
Version 6.0.  Value of type int that specifies the phase of an icon.
iPartId
Version 6.0.  Value of type int that specifies the ID of the part of an item to draw.
iStateId
Version 6.0.  Value of type int that specifies the ID of the state of an item to draw.
rcText
Version 6.0. RECT that specifies the rectangle in which the text is to be drawn.
uAlign
Version 6.0. UINT that specifies how a group should be aligned. This member can be one of the following values.
LVGA_HEADER_CENTER
Center the group.
LVGA_HEADER_LEFT
Align the group on the left.
LVGA_HEADER_RIGHT
Align the group on the right.

Remarks

Note  Comctl32.dll version 6 is not redistributable but it is included in Windows XP or later. To use Comctl32.dll version 6, specify it in a manifest. For more information on manifests, see Enabling Visual Styles.

Structure Information

Minimum DLL Versioncomctl32.dll version 4.70 or later
Headercommctrl.h
Minimum operating systems Windows 2000, Windows NT 4.0 with Internet Explorer 3.0, Windows 98, Windows 95 with Internet Explorer 3.0
Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Processing
Page view tracker