Skip to content

SetCustomDraw Method

Description

The SetCustomDraw method is used to specify which of the three custom draw events should be executed when the rows and items are drawn.

Syntax

Public Sub SetCustomDraw( _
    ByVal [Flags](#) As [XTPGridCustomDraw](XtremeGridControl~Enumerations~XTPGridCustomDraw_EN.md) _
)

Parameters

Flags
Indicates which events to enable. The following events can be specified:

  • xtpCustomDrawItem: MeasurePreviewItemDrawItem event.
  • xtpCustomMeasureRow: MeasureRow event.
  • xtpCustomBeforeDrawRow: BeforeDrawRow event.
  • xtpCustomDrawPreviewItem: DrawPreviewItem event.
  • xtpCustomMeasurePreviewItem: MeasurePreviewItem event.
Value Description

Remarks

The SetCustomDraw method is used to enable or disable the DrawItem, MeasureRow, and BeforeDrawRow events.

Any combination of the events can be enabled at the same time. Custom drawing can be accomplished by enabling these events.

By default, all three events are disabled. If all three events are enabled, the drawing of the items can be considerably slower depending on what operations are done in the events.

Note: When using Virtual Mode, it is required that the SetCustomDraw method is used to specify that the xtpCustomBeforeDrawRow event is called.

See Also


Copyright (c) 1998-2024 Codejock Technologies. All rights reserved.