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 

Customcontrol: Canvas.Font property does not work

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi VCL Components Writing
View previous topic :: View next topic  
Author Message
Hans Peter Kunz
Guest





PostPosted: Tue May 03, 2005 8:37 pm    Post subject: Customcontrol: Canvas.Font property does not work Reply with quote



Hi,

I derive my own component from TCustomControl. In the Paint procedure
I set my own font
Canvas.Font.Assign(FFontMouseOver);
and write some text with Canvas.TextOut or the WinAPI function
DrawText. The text is always written in the default font, not with the
font FFontMouseOver.
If I change to
Font.Assign(FFontMouseOver);
then it works. But this has other problems for me. Strange behaviour,
isn't it?
Why can't I use the canvas font property like the other VCL controls?
Please help! (I use BCB5 that means D5)

Thanks,
Hans Peter
Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi VCL Components Writing 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.