//

637
1
Jump to solution
07-05-2017 11:40 AM
_____
by
New Member
 
0 Kudos
1 Solution

Accepted Solutions
LucasDanzinger
Esri Frequent Contributor

Basically, the issue is that most UI elements in QML are defined in raw pixels. However, due to extremely different screen resolutions from a high end Android device to a low end Windows monitor, 14 pixels will look much different. On a very high DPI device, 14 pixels would be very tiny, and on a lower DPI device, it might look how you want. So, we provided this helper that basically figures out a factor that you need to multiply the raw pixel value by so that it looks exactly the same on all devices, no matter the resolution. 

One of the newer features of Qt is to enable high DPI support. This is something you can try if you like. We have found that it doesn't always work well on some platforms, but in general it seems to work well. More info can be found about this on Qt's website - High DPI Displays | Qt 5.9 

View solution in original post

1 Reply
LucasDanzinger
Esri Frequent Contributor

Basically, the issue is that most UI elements in QML are defined in raw pixels. However, due to extremely different screen resolutions from a high end Android device to a low end Windows monitor, 14 pixels will look much different. On a very high DPI device, 14 pixels would be very tiny, and on a lower DPI device, it might look how you want. So, we provided this helper that basically figures out a factor that you need to multiply the raw pixel value by so that it looks exactly the same on all devices, no matter the resolution. 

One of the newer features of Qt is to enable high DPI support. This is something you can try if you like. We have found that it doesn't always work well on some platforms, but in general it seems to work well. More info can be found about this on Qt's website - High DPI Displays | Qt 5.9