statusbar: Don't use fractional font sizes

This commit is contained in:
Devin Lin 2022-10-27 20:00:49 -04:00
parent be5acaf8a9
commit 06de6e416e
2 changed files with 4 additions and 10 deletions

View file

@ -54,7 +54,8 @@ Item {
property alias colorScopeColor: icons.backgroundColor property alias colorScopeColor: icons.backgroundColor
property alias applets: appletIconsRow property alias applets: appletIconsRow
readonly property real textPixelSize: PlasmaCore.Units.gridUnit * 0.6 readonly property real textPixelSize: 11
readonly property real smallerTextPixelSize: 9
readonly property real elementSpacing: PlasmaCore.Units.smallSpacing * 1.5 readonly property real elementSpacing: PlasmaCore.Units.smallSpacing * 1.5
PlasmaCore.DataSource { PlasmaCore.DataSource {
@ -208,14 +209,14 @@ Item {
PlasmaComponents.Label { PlasmaComponents.Label {
text: Qt.formatDate(timeSource.data.Local.DateTime, "ddd. MMMM d") text: Qt.formatDate(timeSource.data.Local.DateTime, "ddd. MMMM d")
color: PlasmaCore.ColorScope.disabledTextColor color: PlasmaCore.ColorScope.disabledTextColor
font.pixelSize: root.textPixelSize * 0.8 font.pixelSize: root.smallerTextPixelSize
} }
Item { Layout.fillWidth: true } Item { Layout.fillWidth: true }
PlasmaComponents.Label { PlasmaComponents.Label {
visible: root.showTime visible: root.showTime
text: MobileShell.SignalStrengthProvider.label text: MobileShell.SignalStrengthProvider.label
color: PlasmaCore.ColorScope.disabledTextColor color: PlasmaCore.ColorScope.disabledTextColor
font.pixelSize: root.textPixelSize * 0.8 font.pixelSize: root.smallerTextPixelSize
horizontalAlignment: Qt.AlignRight horizontalAlignment: Qt.AlignRight
} }
} }

View file

@ -13,8 +13,6 @@ import org.kde.plasma.core 2.0 as PlasmaCore
import org.kde.plasma.components 3.0 as PC3 import org.kde.plasma.components 3.0 as PC3
import org.kde.plasma.private.mobileshell 1.0 as MobileShell import org.kde.plasma.private.mobileshell 1.0 as MobileShell
import org.kde.kirigami 2.20 as Kirigami
Item { Item {
id: root id: root
implicitHeight: clockColumn.implicitHeight implicitHeight: clockColumn.implicitHeight
@ -30,11 +28,6 @@ Item {
intervalAlignment: PlasmaCore.Types.AlignToMinute intervalAlignment: PlasmaCore.Types.AlignToMinute
} }
Kirigami.ImageColors {
id: imageColors
source: wallpaper
}
DropShadow { DropShadow {
anchors.fill: parent anchors.fill: parent
source: clockColumn source: clockColumn