_DrawItemEventArgs Type

Provides data for the OnDrawItem event.

Namespace: CNClrLib.Control.EventArgs
type
 _DrawItemEventArgs = CNClrLib.Windows._DrawItemEventArgs;

The OnDrawItem event is raised by owner draw controls, such as the TCnListBox and TCnComboBox controls. It contains all the information that is needed for the user to paint the specified item, including the item index, the Rectangle, and the Graphics on which the drawing should be done.

For more information, See DrawItemEventArgs in C#.

Properties
Description

BackColor

Gets the background color of the item that is being drawn.

Bounds

Gets the rectangle that represents the bounds of the item that is being drawn

Font

Gets the font that is assigned to the item being drawn.

ForeColor

Gets the foreground color of the of the item being drawn.

Graphics

Gets the graphics surface to draw the item on.

Index

Gets the index value of the item that is being drawn.

State

Gets the state of the item being drawn.

Methods
Description

DrawBackground

Draws the background within the bounds specified in the DrawItemEventArgs constructor and with the appropriate color.

DrawFocusRectangle

Draws a focus rectangle within the bounds specified in the DrawItemEventArgs constructor.