CustomDrawNodeImagesEventArgs.StateImageLocation Property

Gets the location of the state image’s top-left corner.

Namespace: DevExpress.XtraTreeList

Assembly: DevExpress.XtraTreeList.v21.1.dll

Declaration

public Point StateImageLocation { get; }

Property Value

Type Description
Point

A System.Drawing.Point structure specifying the top-left corner of the state image.

Remarks

The bounding rectangle of the state image can be obtained via the CustomDrawNodeImagesEventArgs.StateRect property. The bounding rectangle’s height is always equal to the corresponding node’s height, while the state image’s height is specified by the height of images from the TreeList.StateImageList image list. Note that images are vertically centered within their bounding rectangles. Thus the StateImageLocation property value doesn’t necessarily coincide with the bounding rectangle’s top-left corner.

The StateImageLocation property returns Point.Empty if state images are not supposed to be painted (if the TreeList.StateImageList property value is null (Nothing in Visual Basic)).

Note: node height is calculated as the maximum of the font size applied to the node, its node button height and its images height.

See Also