Vcl.StdCtrls.TListBox.OnMeasureItem
Delphi
property OnMeasureItem;
C++
__property OnMeasureItem;
Properties
Type | Visibility | Source | Unit | Parent |
---|---|---|---|---|
event | published | Vcl.StdCtrls.pas Vcl.StdCtrls.hpp |
Vcl.StdCtrls | TListBox |
Description
Occurs when the application needs to redisplay an item in a variable height owner-draw list box.
Vcl.StdCtrls.TListBox.OnMeasureItem inherits from Vcl.StdCtrls.TCustomListBox.OnMeasureItem. All content below this line refers to Vcl.StdCtrls.TCustomListBox.OnMeasureItem.
Occurs when the application needs to redisplay an item in a variable height owner-draw list box.
Use OnMeasureItem to write a handler to measure items to be drawn in a list box with a Style property value of lbOwnerDrawVariable.
OnMeasureItem is of type Vcl.StdCtrls.TMeasureItemEvent which contains three parameters describing the item to measure.
After the OnMeasureItem event occurs, the OnDrawItem event occurs, rendering the item with the measured size.
See Also
Code Examples