You cannot simply change the font per line in a TListBox, without adding some additional coding.
pritaeas
Posting Expert
5,480 posts since Jul 2006
Reputation Points: 653
Solved Threads: 874
Well, if you know that already then it is relatively simple. The Items property of a TListBox has an AddObject method. You can use it when adding your string like this:
// clRed is an Integer, and you just cast it to an object
// so it can be added alongside your item text.
ListBox1.Items.AddObject('item', TObject(clRed));
// In your OnDrawItem (color is a TColor variable)
// where i is the index of your current item.
color := TColor(ListBox.Items.Objects[i]);
pritaeas
Posting Expert
5,480 posts since Jul 2006
Reputation Points: 653
Solved Threads: 874