0

I have a legacy code that creates Windows native balloon tooltips. In previous versions of Windows I could set custom background and foreground colors for tooltips using the TTM_SETTIPBKCOLOR and TTM_SETTIPTEXTCOLOR messages with the following calls:

SendMessage hwndTooltip, TTM_SETTIPBKCOLOR, BackColorValue, 0
SendMessage hwndTooltip, TTM_SETTIPTEXTCOLOR, ForeColorValue, 0

enter image description here

But now, when the OS visual styles are used in my app in Windows 10/11, these settings no longer work. I always see tooltips with the default system colors:

enter image description here

Is it possible to make the TTM_SETTIPBKCOLOR and TTM_SETTIPTEXTCOLOR messages work in the modern environment?

TecMan
  • 2,743
  • 2
  • 30
  • 64
  • have you tried that? `TTM_SETTIPBKCOLOR wParam= (WPARAM)(COLORREF) clr;lParam= 0;` https://learn.microsoft.com/de-de/windows/win32/controls/ttm-settipbkcolor – Roadman1991 Nov 23 '21 at 16:58
  • @Roadman1991, I don't understand. What I showed is VB6 code that has been working for years correctly. `BackColorValue` is also the value in the expected `WPARAM` `COLORREF` format, it works in the case when visual styles aren't applied. – TecMan Nov 24 '21 at 07:16

0 Answers0