This is follow-up question to Handle runtime change of DPI (text size) on Windows 10
Windows 10 allows runtime change of DPI without restart (logon/logoff) of the system. When DPI is changed, and the system detects that the application cannot handle runtime DPI change, it scales the application windows pixel-wise. What is similar to the compatibility behavior seen in previous versions of Windows. Except that in this case, the system can even scale down, not only up.
The strange thing is, that the application restart won't help. The system seems to remembers that the application did not respond correctly to the change of scaling and still behaves as before (the application believes the scaling has not changed and the system scales the windows pixel-wise). Only system logon/logoff helps resetting to the correct scaling.
Is there a way to reset the compatibility mode programmatically, to allow the user to restart the application only, not whole system? (as is a very first step towards full support for runtime DPI change)
I'm using C++ Builder, so I'm looking for a pure WinAPI solution, no WinForms.
SetProcessDpiAwareness
function. – RRUZ