Tooltips not showing in some hosts on Windows..

I had some customers complaining that tooltips weren’t showing up which could be reproduced on e.g. Win 7 x64 in Ableton Live or iZotope RX6.

Further debugging revealed that in those cases “SendMessage (hwndTT, TTM_ADDTOOL, 0, (LPARAM)&ti)” fails to create the tooltip window in initTooltip() in win32frame.cpp. Replacing “ti.cbSize = sizeof(TOOLINFO);” with “ti.cbSize = TTTOOLINFO_V1_SIZE;” seems to help creating the tooltip container window successfully, which of course isn’t considered a proper bugfix at all, but I still can’t get the tooltips to show. I guess it must have something to do with the minimum ComCtl version a given host is built for.

Any chance in seeing this fixed?

Thanks!

You can try to get in contact with the host developers and ask why they are using such an old ComCtl version. Version 6.1 (the current one) was introduced with Windows Vista. Do these hosts still support Windows XP ?

Hi Arne,

Although the minimum system requirements state Windows 7 for both mentioned hosts, it seems they are linked against an older ComCtl version. I assume this can be considered as “won’t fix” then?

Yeah, at least I’m not aware of any solution on how to fix this from the VSTGUI side.

Tooltips didn’t work for me in any host on Windows.

2 changes required

(1) Use ti.cbSize = TTTOOLINFO_V1_SIZE instead of sizeof(TOOLINFO)
in Win32Frame::initTooltip(), showTooltip() and hideTooltip()

The versions just mean that they added first one struct member (lParam), then another (lpReserved)
VSTGUI doesn’t use either of those, so there’s no reason to define a later version than the most backwards compatible.


(2) in Win32Frame::showTooltip(), fix a setting:
SendMessage (tooltipWindow, TTM_SETMAXTIPWIDTH, 0, 0);

The last 0 is wrong, either use -1 to allow any width (and then the message should be sent in initTooltip() )
or set actual width in each call, ie
SendMessage (tooltipWindow, TTM_SETMAXTIPWIDTH, 0, (LPARAM)rc.right - rc.left);

Now tooltips work for me in latest Ableton, Bitwig, Renoise…


(3) also, feature request:
Win32Frame::showTooltip(rect, text), the line
SendMessage (tooltipWindow, TTM_SETDELAYTIME, 0, 2000);

should please take the delay time from a 3rd function argument that can be passed to CFrame.
2 secs is too long for me, I’m probably going to add a button to turn on/off help, then let the tips pop up quickly (2-400ms even).


Thanks,
/rasmus

Thanks for sharing, Rasmus! I’ll try that asap.

Hi,
if this fixes the issue, can someone make a pull request on GitHub ?

Thanks,
Arne