Skip to main content

BaseListBoxControl.ItemHeight Property

Gets or sets an item’s height.

Namespace: DevExpress.XtraEditors

Assembly: DevExpress.XtraEditors.v23.2.dll

NuGet Package: DevExpress.Win.Navigation

Declaration

[DefaultValue(0)]
[DXCategory("Appearance")]
public virtual int ItemHeight { get; set; }

Property Value

Type Default Description
Int32 0

An integer value representing an item’s height in pixels.

Remarks

If this property is set to 0, an item’s height is the height of its font plus a small margin to provide some clearance around the items. Use the ItemHeight property to specify a custom item height.

To enable automatic height calculation, follow the instructions in the BaseListBoxControl.ItemAutoHeight topic.

The BaseListBoxControl.MeasureItem event allows you to dynamically set the height for each item. This can be useful, for instance, when you need to change the height of a specific item while other items within the collection retain the default height.

See Also