Finding the handle of a TipField/ToolTip
Posted: Fri Apr 30, 2010 2:05 pm
ToolTips (created by setting the Tip property in the Dyalog GUI) have a new theme in Windows Vista and Windows 7, they are grey metallic.
By default, ToolTips of any object that doesn't require setting the TipObj property to show tips use this new style, however objects that require a TipObj (like e.g. an Edit field), don't, the render with the old XP black on yellow style.
I'm trying to make sure all tool tips use the new style using some []NA and win32 API.
If I create my own ToolTip via win32 from scratch and attach it to an object by sending an TTM_ADDTOOL message, everything works fine and it renders with the correct theme. But to avoid having to change the code everywhere it would be nice to set some style on the TipField object itself, causing everything to look nice (I suspect TTS_USEVISUALSTYLE is needed). Sadly, TipField objects do no have a Handle property where I can get their HWND.
Can I get a hwnd for the TipField object in any way? Or is the TipField object in fact just a template used when sending TTM_ADDTOOL messages in response to someone setting a Tip property? So I either need to create ToolTip controls manually or ask Dyalog to fix this?
By default, ToolTips of any object that doesn't require setting the TipObj property to show tips use this new style, however objects that require a TipObj (like e.g. an Edit field), don't, the render with the old XP black on yellow style.
I'm trying to make sure all tool tips use the new style using some []NA and win32 API.
If I create my own ToolTip via win32 from scratch and attach it to an object by sending an TTM_ADDTOOL message, everything works fine and it renders with the correct theme. But to avoid having to change the code everywhere it would be nice to set some style on the TipField object itself, causing everything to look nice (I suspect TTS_USEVISUALSTYLE is needed). Sadly, TipField objects do no have a Handle property where I can get their HWND.
Can I get a hwnd for the TipField object in any way? Or is the TipField object in fact just a template used when sending TTM_ADDTOOL messages in response to someone setting a Tip property? So I either need to create ToolTip controls manually or ask Dyalog to fix this?