Back to Devexpress

CustomDrawNodeImagesEventArgs.StateImageIndex Property

windowsforms-devexpress-dot-xtratreelist-dot-customdrawnodeimageseventargs-c64ce093.md

latest2.5 KB
Original Source

CustomDrawNodeImagesEventArgs.StateImageIndex Property

Gets or sets the index of the state image displayed within the node.

Namespace : DevExpress.XtraTreeList

Assembly : DevExpress.XtraTreeList.v25.2.dll

NuGet Packages : DevExpress.Win.Navigation, DevExpress.Win.TreeList

Declaration

csharp
public int StateImageIndex { get; set; }
vb
Public Property StateImageIndex As Integer

Property Value

TypeDescription
Int32

An integer value representing the node’s state image’s index.

|

Remarks

Initially, the StateImageIndex property contains the zero-based index of the image specified by the node’s TreeListNode.StateImageIndex property. This property can be used in the following ways:

  • read the property value to paint the default image;
  • change the StateImageIndex property value and leave the CustomDrawEventArgs.Handled property set to false. This forces the control to paint the node’s state image using the default mechanism but with a different image.

Assigning values to this property has no effect in the following cases:

  • the control’s TreeList.StateImageList property is a null reference;
  • the assigned value is less than zero or exceeds the available image index.

See Also

SelectImageIndex

StateImageIndex

StateImageList

CustomDrawNodeImagesEventArgs Class

CustomDrawNodeImagesEventArgs Members

DevExpress.XtraTreeList Namespace