I have a visual component in my app written in QML, Qt5. I want it to always have the width of 5 cm
on the screen, no matter what device is used.
If I set width: somevalue
, then the DPI might differ among the devices which will result in different physical size on different devices.
Is there any way to achieve my goal?
Well, I've just might've found a solution:
Screen.pixelDensity
. But feel free to suggest anything better.