Skip to main content

TreeList.Painter Property

Gets an object that provides the painting functionality of the TreeList control.

Namespace: DevExpress.XtraTreeList

Assembly: DevExpress.XtraTreeList.v24.2.dll

Declaration

[Browsable(false)]
public TreeListPainter Painter { get; }

Property Value

Type Description
DevExpress.XtraTreeList.Painter.TreeListPainter

A TreeListPainter object implementing the control’s painting functionality.

Remarks

The TreeList control delegates its painting functionality to a specially designed TreeListPainter object. This object is accessed via the Painter property. The TreeListPainter object, in turn, partially delegates its functionality concerned with control element painting to an object accessed via its DefaultPaintHelper property. This object must implement the ITreeListPaintHelper interface.

There are two paint helpers provided by the TreeList control. These are used to paint control elements in standard and XP style. You can also declare a paint helper object implementing the ITreeListPaintHelper interface. If you assign this object to the DefaultPaintHelper property of the TreeListPainter object, control elements will be painted in a custom manner.

Implementing a custom paint helper object is similar to handling custom draw events. However, providing a paint helper object increases the painting speed as compared to painting via event handlers.

Refer to the Painters topic for more information.

See Also