QFileDialog on 4K screen
-
Hi,
The issue that I have is that on 4K screen native QFileDialog dialog looks tiny (despite 200% OS user scale setting)
Is it possible to make it aware of desktop 200% user scale setting ?
Alternatively, is it possible to apply stylesheet (to compensate the resolution) to QFileDialog instance but still keep it native ?
In my application I use the QT recommended approach:
Always use the qreal versions of the QPainter drawing API. Size windows and dialogs in relation to the screen size. Replace hard-coded sizes in layouts and drawing code by values calculated from font metrics or screen size.I don't know what to do with QFileDialog though...
Thanks a lot!
-
Hi
Did you try anything from ?
http://doc.qt.io/qt-5/highdpi.htmlAlso when you say native QFileDialog , do you mean
native to Qt. ( its version ) or native to the OS via the
Qt::DontUseNativeDialog flag ? -
By native I mean OS file dialog (with all bells and whistles)
I have the following lines in my code:
setAttribute(Qt::AA_EnableHighDpiScaling); setDesktopSettingsAware(true);I tried other true/false combinations but without spotting any difference.
Also tried to open dialog passing null parent -
By native I mean OS file dialog (with all bells and whistles)
I have the following lines in my code:
setAttribute(Qt::AA_EnableHighDpiScaling); setDesktopSettingsAware(true);I tried other true/false combinations but without spotting any difference.
Also tried to open dialog passing null parent