Scaling: Replaced all Theme.uiScale by Theme.scale(Screen) so stuff scale accordingly to the Screen used by the Item/component

This commit is contained in:
quadbyte 2025-08-07 14:09:18 -04:00
parent 3148dc62a0
commit cb74b6e5d5
50 changed files with 564 additions and 568 deletions

View file

@ -4,11 +4,11 @@ import qs.Settings
Item {
id: root
property int innerRadius: 34 * Theme.uiScale
property int outerRadius: 48 * Theme.uiScale
property int innerRadius: 34 * Theme.scale(Screen)
property int outerRadius: 48 * Theme.scale(Screen)
property color fillColor: "#fff"
property color strokeColor: "#fff"
property int strokeWidth: 0 * Theme.uiScale
property int strokeWidth: 0 * Theme.scale(Screen)
property var values: []
property int usableOuter: 48
@ -24,7 +24,7 @@ Item {
Rectangle {
property real value: root.values[index]
property real angle: (index / root.values.length) * 360
width: Math.max(2 * Theme.uiScale, (root.innerRadius * 2 * Math.PI) / root.values.length - 4 * Theme.uiScale)
width: Math.max(2 * Theme.scale(Screen), (root.innerRadius * 2 * Math.PI) / root.values.length - 4 * Theme.scale(Screen))
height: Settings.settings.visualizerType === "diamond" ? value * 2 * (usableOuter - root.innerRadius) : value * (usableOuter - root.innerRadius)
radius: width / 2
color: root.fillColor