mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
QML UI: take device pixel ratio into account when scaling pixmaps on iOS
This way warning icons and tank change icons and other event markers are no longer ridiculously tiny on retina screens. Oddly this doesn't appear to be needed on Android, only on iOS. Fixes #1033 Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
8185d24e61
commit
dd0d88f9d7
4 changed files with 17 additions and 1 deletions
|
@ -25,9 +25,12 @@ struct IconMetrics {
|
|||
int sz_pic; // ex 128px
|
||||
// icon spacing
|
||||
int spacing; // ex 2px
|
||||
// devicePixelRatio
|
||||
double dpr; // 1.0 for traditional screens, HiDPI screens up to 3.0
|
||||
IconMetrics();
|
||||
};
|
||||
|
||||
const IconMetrics & defaultIconMetrics();
|
||||
void updateDevicePixelRatio(double dpr);
|
||||
|
||||
#endif // METRICS_H
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue