BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

item font and color of listbox

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> C++ Builder (VCL Components Usage)
View previous topic :: View next topic  
Author Message
Adam
Guest





PostPosted: Fri Apr 14, 2006 1:03 am    Post subject: item font and color of listbox Reply with quote



How to make items of a listbox has different fonts and colors? thanks
Back to top
JD
Guest





PostPosted: Fri Apr 14, 2006 3:03 am    Post subject: Re: item font and color of listbox Reply with quote



"Adam" <support (AT) borlandBBS (DOT) cn> wrote:
Quote:

How to make items of a listbox has different fonts and colors?

You need to add an OnDrawItem event and if the fonts are
different sizes, you'll also need an OnMeasureItem event as
well.

~ JD
Back to top
Remy Lebeau (TeamB)
Guest





PostPosted: Fri Apr 14, 2006 3:03 am    Post subject: Re: item font and color of listbox Reply with quote



"Adam" <support (AT) borlandBBS (DOT) cn> wrote in message
news:443eeaf7 (AT) newsgroups (DOT) borland.com...

Quote:
How to make items of a listbox has different fonts and colors?

You need to set the ListBox's Style to lbOwnerDrawFixed or
lbOwnerDrawVariable, and then use the OnDrawItem event to draw the item text
onto the ListBox's Canvas yourself.


Gambit
Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> C++ Builder (VCL Components Usage) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.