displays differently with 5.15.7 build than 5.0.1 build
-
I compiled Qt version 5.15.7 with the standard configure options. It built fine.
However, the graphics are very different than those I had with a previous 5.0.1 build (I am not sure what compile options were used for the older build).
I am building and running on windows 10 and using visual studio c++.Display with 5.0.1 build:
Display with my new 5.15.7 build:
If I was going to guess, it looks like the new build is using windows fonts (text seems sharper), and the previous build is using a different text display.
How do I update the build configuration (ie Qt build option) to make the new display look the the previous display? Or is there another way to fix the issue?
-
I would guess 5.0 has some bugs (I mean it's 5.0) which were fixed afterwards.
Please show how you resize the columns - if you don't resize them at all then you should add this code to resize them programatically. -
I used qt Creator to design the graphics (Qt Creator 2.6.2).
All the display code is generated directly from Qt Creator.
The graphics on the 5.0.1 design correspond to what Qt Creator shows.
I have tried -style options (as mentioned in a previous post) and that makes no real difference. -
I don't see what QtCreator has to do with the different styles. As I already said Qt 5.0 is really old and may contain bugs whioch were fixed later on so you get the correct display with a newer Qt5 version.
-
It looks like you're running this on a HighDPI display with scaling.
Qt 5.4 introduced experimental support for HighDPI displays, which was then expanded in Qt 5.6.Qt 5.0 did not have this support and so the scaling was done by the OS, simply stretching your app up, like you would zoom an image. That's why it looks blurry.
Qt 5.15 does proper scaling i.e. it adjusts font size appropriately to the scale factor. If you have hardcoded widget sizes (which you generally shouldn't do) this might result in clipping of overflowing text, like you see.Read more about High DPI suport here. It also describes how you can get back to the old behavior if you don't want to fix your layout. Note that in Qt6 a proper high dpi behavior of the app is crucial and on some platforms you can't disable it.