you must set a Style property of your ListBox in lbOwnerDrawVariable value and define the MeasureItem and DrawItem events:procedure TForm1.ListBox1MeasureItem(Control: TWinControl; Index: Integer; var Height: Integer); var intHeight1: Integer; begin with ListBox1.Canvas do begin Height := intHeight1; ... end; end;
and define the MeasureItem and DrawItem events:procedure TForm1.ListBox1MeasureItem(Control: TWinControl; Index: Integer;
var Height: Integer);
var intHeight1: Integer;
begin
with ListBox1.Canvas do
begin Height := intHeight1;
...
end;
end;