I highly doubt that Tooltips are any real physical object that have
handles and DCs and whatnot. They are more than likely just drawn
on the screen. Unless you draw your own tooltips on the screen's
DC like that, I don't think you can change the existing ones.
Thats how I would do it: Create a bitmap with the text you want to show, put a picturebox and make it invisible. On the mousemove event of a control set the apporopriate image to the picture box, get the location of the control, subtract or add the values from its location and then set the modified location to the picturebox so it doesnt go over the control, make the picturebox visible. On mouseleave event make the picture box invisible.
Here's a little example of a customized tool tip ( not exactly a tooltip, but it serves the purpose and allows for many appearance altering abilities...
As you can see of course, there are a few things up with it...
one of which is a timing effect ( we can worry bout that later )...
another is the amount of text that is displayed isn't much before it stops displaying the rest of the text...
Guys, feel free to play around with it, if you make any modifications, please post them here, thanx!
Cool ToolTip, just add the museleave event so it hides and its all set. But one of the problems is that main form looses focus when the tooltip is shown.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.