|
-
Sep 15th, 2002, 04:40 AM
#1
Thread Starter
Addicted Member
Drawing colored text
Hi,
In a program of mine, i'm using the DrawText api to draw text. But.. i can only draw black text. I can draw colored text by setting the forecolor property, but i dont want to do that. Anyone knows how to do this?
Thanks in advance,
Shell
-
Sep 16th, 2002, 08:53 AM
#2
Frenzied Member
There is an API named setTextColor it needs the DC of the window you are drawing the text on. under is it's declaration
VB Code:
Public Declare Function SetTextColor Lib "gdi32" Alias "SetTextColor" (ByVal hdc As Long, ByVal crColor As Long) As Long
Call this API before calling DrawText
-
Sep 16th, 2002, 09:00 AM
#3
Thread Starter
Addicted Member
Argh!! It's that easy! Thanks
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|