mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
mobile-widgets: move basePointSize to themeinterface
Check defaultfont and calculate basepointsize in themeinterface instead of in QML. Signed-off-by: jan Iversen <jan@casacondor.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
08e39f9d2d
commit
a3e3a30b70
5 changed files with 17 additions and 21 deletions
|
@ -318,7 +318,7 @@ Kirigami.ScrollablePage {
|
|||
enabled: subsurfaceTheme.currentScale !== 0.85
|
||||
onClicked: {
|
||||
PrefDisplay.mobile_scale = 0.85
|
||||
fontMetrics.font.pointSize = subsurfaceTheme.basePointSize * PrefDisplay.mobile_scale;
|
||||
fontMetrics.font.pointSize = themeNew.basePointSize * PrefDisplay.mobile_scale;
|
||||
}
|
||||
}
|
||||
SsrfButton {
|
||||
|
@ -326,7 +326,7 @@ Kirigami.ScrollablePage {
|
|||
enabled: subsurfaceTheme.currentScale !== 1.0
|
||||
onClicked: {
|
||||
PrefDisplay.mobile_scale = 1.0
|
||||
fontMetrics.font.pointSize = subsurfaceTheme.basePointSize * PrefDisplay.mobile_scale;
|
||||
fontMetrics.font.pointSize = themeNew.basePointSize * PrefDisplay.mobile_scale;
|
||||
}
|
||||
}
|
||||
SsrfButton {
|
||||
|
@ -334,7 +334,7 @@ Kirigami.ScrollablePage {
|
|||
enabled: subsurfaceTheme.currentScale !== 1.15
|
||||
onClicked: {
|
||||
PrefDisplay.mobile_scale = 1.15
|
||||
fontMetrics.font.pointSize = subsurfaceTheme.basePointSize * PrefDisplay.mobile_scale;
|
||||
fontMetrics.font.pointSize = themeNew.basePointSize * PrefDisplay.mobile_scale;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue