PDA

View Full Version : QScreen devicePixelRatio wrong for my application.



kfieldi5
14th June 2016, 23:36
Hi I've been working on an application in Qt for a few months now and out of nowhere it started rendering fonts and icons blurry. I checked my logs where I spit out the devicePixelRatio of the main window's screen and instead of being 2 (which it was before - I am developing on a retina macbook) it is now 1 (same machine).

my Info.plist file has:

<key>NSPrincipalClass</key>
<string>NSApplication</string>
<key>NSHighResolutionCapable</key>
<string>True</string>

as well as in main.cpp I am setting my application to use highdpi:

a.setAttribute(Qt::AA_UseHighDpiPixmaps);


Any help very much appreciated!

Thanks,
k