Commit 44d338fc authored by Nate Graham's avatar Nate Graham 🔩

[applets/digital clock] Make tooltip spacing and text nicer and more consistent

Test Plan:
Before, no clocks: {F8246116}
After, no clocks: {F8246114}
[Now the vertical spacing between labels matches other tooltips]

Before, some clocks: {F8246113}
After, some clocks: {F8246115}
[Now the full date is displayed on the first line instead of being split across two]

Reviewers: #vdg, #plasma, ndavis

Reviewed By: #vdg, ndavis

Subscribers: plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D28970
parent 13616ee1
......@@ -43,13 +43,15 @@ Item {
margins: units.gridUnit / 2
}
spacing: 0
PlasmaExtras.Heading {
id: tooltipMaintext
level: 3
Layout.minimumWidth: Math.min(implicitWidth, preferredTextWidth)
Layout.maximumWidth: preferredTextWidth
elide: Text.ElideRight
text: Qt.formatDate(tzDate,"dddd")
text: clocks.visible ? Qt.formatDate(tzDate, Locale.LongFormat) : Qt.formatDate(tzDate,"dddd")
}
PlasmaComponents.Label {
......@@ -58,14 +60,17 @@ Item {
Layout.maximumWidth: preferredTextWidth
text: Qt.formatDate(tzDate, dateFormatString)
opacity: 0.6
visible: !clocks.visible
}
GridLayout {
id: clocks
Layout.minimumWidth: Math.min(implicitWidth, preferredTextWidth)
Layout.maximumWidth: preferredTextWidth
Layout.maximumHeight: childrenRect.height
columns: 2
visible: plasmoid.configuration.selectedTimeZones.length > 1
rowSpacing: 0
Repeater {
model: {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment