![]() |
[Windows API] Tooltips w/o MFC
Hey all
I have been trying the whole night long to write a program that would display a tooltip control at an arbitrary position on screen (without making it a child of an existing window), WITHOUT using these terrible MFC classes... I've scoured the net for code samples and stuff, but all that I've succeeded in coming up was something like this : Code:
// don't forget to link with comctl32.lib when you compile this app What am I doing wrong ? |
Re: [Windows API] Tooltips w/o MFC
In your CreateWindow() call you have...
Code:
0,0, // left/top positions botman |
Re: [Windows API] Tooltips w/o MFC
That doesn't work, botman... I already tried many combinations with left/top and width/height coordinates. The tooltip always show in the top left corner of the screen. :(
|
Re: [Windows API] Tooltips w/o MFC
just a little idea, have you tried moving the window after you've created it?
- using code, rather than the mouse or any such thing |
Re: [Windows API] Tooltips w/o MFC
Thanks for the tip, that worked :)
Code:
// these #define's apply to balloon tooltips and are not present in the MSVC 6 headers |
Re: [Windows API] Tooltips w/o MFC
ahh, have to pass that one. I'm a complete n00b when it comes to anything more advanced than QBASIC...
|
Re: [Windows API] Tooltips w/o MFC
TTM_TRACKACTIVATE allows the tooltip to track the mouse position and disply the tooltip window when the mouse is over the item.
See the MSDN webpage about it... http://msdn.microsoft.com/library/de...ckactivate.asp botman |
Re: [Windows API] Tooltips w/o MFC
I know that botman.. looking it up in the MSDN was the first thing I did, but still it doesn't tell me WHY I need this message... since all I want is a topmost-level tooltip not child of any other window (but the desktop window) that I could pop up at an arbitrary location.
I prolly *hate* when I use a piece of code that I don't understand. Thanks for taking the time to search it anyway :) |
All times are GMT +2. The time now is 22:41. |
Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.