AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

DrawCaption problem.

 
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
jk7800



Joined: 06 Jan 2008
Posts: 40
Location: Gdi+ v1.1

PostPosted: Fri Aug 01, 2008 2:31 pm    Post subject: DrawCaption problem. Reply with quote

Hi.

Lately, I was experimenting a bit with the GDI functions... But I've got stuck on the DrawCaption command. According to the msdn database, when I execute the command with the DC_SMALLCAP parameter, it should draw a normal caption bar. But it draws nothing instead! How can I make it to draw a normal caption (not gradient one)?
I'm posting my script:

Code:
VarSetCapacity(Rect, 16)

NumPut(0, Rect, 0, true)
NumPut(0, Rect, 4, true)
NumPut(600, Rect, 8, true)
NumPut(32, Rect, 12, true)

DllCall("user32.dll\DrawCaption", UInt, h:=WinExist("A"), UInt, hdc:=DllCall("GetDC", UInt,  WinExist("A")), UInt, &Rect, UInt, DC_SMALLCAP:=0x0002)

_________________
My first app: Note
(Please, vote if you like my apps!)

None of my apps took me more than a day to create... After this time I get bored with it (maybe except the note one)...
Back to top
View user's profile Send private message
engunneer



Joined: 30 Aug 2005
Posts: 6847
Location: Pacific Northwest, US

PostPosted: Sat Aug 02, 2008 5:48 am    Post subject: Reply with quote

I haven't checked, but is the functionality you want already in the GDI+ wrapper scripts that have been posted? They might show you what you are missing.
_________________
Unless otherwise noted, all code is untested.
Common Answers: 1.(Loops, Viruses, etc.) 2. Search 3.RTFM
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group