|
From: Francesco A. <fra...@gm...> - 2021-02-08 09:23:15
|
Dear all, Jeroen,
high DPI screens are more and more common and Windows is managing high
dpi screens by scaling old applications that are not dpi-aware. For
new applications there are some high dpi aware API that can be used to
behave in the correct way.
I think FOX is not high dpi aware so on Windows, on high dpi screens
the applications look blurry.
One very simple way to declare the application high dpi aware is to
use the call:
HINSTANCE lib = LoadLibrary("user32.dll");
int (*SetProcessDPIAware)() = (void*) GetProcAddress(lib, "SetProcessDPIAware");
SetProcessDPIAware();
This is already sort of better, at least fonts are no longer blurry
which is unsupportable to me personally. Unfortunately in this case
FOX throws some assert in FXCursor.cpp:
FXASSERT(GetSystemMetrics(SM_CXCURSOR)==32);
FXASSERT(GetSystemMetrics(SM_CYCURSOR)==32);
because these metrics can be bigger than 32. I think in this case we
may need to provide bigger cursor images to blit them into the image
bitmap area.
I am wondering if we can fix this fairly simple problem with cursors
waiting to have proper high dpi support.
If you can provide me with some indications I may try to fix this by myself.
In any case I appreciate any feedback and suggestions.
Kind regards
Francesco
|