Closed chrisjbillington closed 1 year ago
I haven't actually tested this on Windows yet. I'll do so at some point, or anyone should feel free to beat me to it.
I can confirm this works on Windows. For me, it appears this also scales up the font sizes of most things, meaning that the minimum sizes of some widgets are different. The digital buttons are the most notable for me.
Before:
After:
Relative scales in these screen clips appear to be accurate. Probably not a fundamental issue, but I can imagine some users with a ton of tabs and a big screen may get annoyed when their layout options change.
As a fun note, it appears the restored windows size (ie you ran BLACS before implementing this PR) scales up as well. People may be in for a fun surprise when updating when everything is suddenly huge.
Overall, I like this change. We like using giant screens with high resolution. This definitely makes it easier to see things.
@chrisjbillington Do you think this is ready to merge? I'm hoping to include it in the next release (which will let me push labscript-suite
v3.2.0 with full Python 3.10 & 3.11 support).
Yep, I'm happy let's do it.
Thanks for all the work getting the latest releases happening!
labscript_utils.splash
is the first place aQApplication
gets created for all of our apps. So setting these settings there applies them to all our applications, although they are also needed for the splash screen itself to be scaled better on High DPI displays.AA_EnableHighDpiScaling
scales all pixel metrics to the device pixel ratio - so this means curved edges and padding and whatnot get scaled up, as well as the size of some pixmaps.AA_UseHighDpiPixmaps
means to use high DPI pixmaps for icons etc, directly, rather than rendering them at the lower resolution and then scaling them up (not sure why anyone would want the latter behaviour). Strangely, high resolution pixmaps are used whenAA_EnableHighDpiScaling
is off. It's only when it is turned on that they get downscaled and then upscaled again and end up blocky.Before:
After:
There are some other places where is it maybe more obvious like this tiny icon in BLACS:
Which is full-sized after these changes:
With higher resolution icons in qtutils now, things should be pretty good on High DPI displays.