Different resolution values returned by qGuiApp->primaryScreen().size() on different Graphic Environments (XFCE vs GNOME)
-
Hello Qt Friends,
I'm working on GUI application and I've tested on different Graphic Environments. I have noticed that when I run it on XFCE my application gets wrong screen size from:
https://doc.qt.io/qt-5/qguiapplication.html#primaryScreen-propI have multiple Graphic Environments. I use Ubuntu 20
There is only 1 screen that has 1920 x 1080 resolution in settings. Also xrand command returns the same resolution.
In my code I use:qGuiApp->primaryScreen().size()
On Gnome3 and Plasma it returns proper value i.e. 1920 x 1080.
However, on XCFE (and LXDE) this command returns: 960 x 540What's also strange when I run Plasma and then switch to XFCE it works fine. But after reseting PC and opening XFCE it returns wrong values...
Do you have idea what is missing?
-
Hi,
That rather looks like an XFCE issue. Did you check the settings of that desktop environment ?
-
Is there some "magnifying" settings ?
The factor 2 you have is troubling.