mobile UI: show dives marked as invalid with strike through

This matches the visual language of the desktop UI.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2020-03-20 15:40:50 -07:00
parent 5747573019
commit c77cc93eec

View file

@ -187,6 +187,7 @@ Kirigami.ScrollablePage {
id: locationText id: locationText
text: (undefined !== location && "" != location) ? location : qsTr("<unnamed dive site>") text: (undefined !== location && "" != location) ? location : qsTr("<unnamed dive site>")
font.weight: Font.Medium font.weight: Font.Medium
font.strikeout: isInvalid
font.pointSize: subsurfaceTheme.smallPointSize font.pointSize: subsurfaceTheme.smallPointSize
elide: Text.ElideRight elide: Text.ElideRight
maximumLineCount: 1 // needed for elide to work at all maximumLineCount: 1 // needed for elide to work at all
@ -211,6 +212,7 @@ Kirigami.ScrollablePage {
text: (undefined !== dateTime) ? dateTime : "" text: (undefined !== dateTime) ? dateTime : ""
width: Math.max(locationText.width * 0.45, paintedWidth) // helps vertical alignment throughout listview width: Math.max(locationText.width * 0.45, paintedWidth) // helps vertical alignment throughout listview
font.pointSize: subsurfaceTheme.smallPointSize font.pointSize: subsurfaceTheme.smallPointSize
font.strikeout: isInvalid
color: selected ? subsurfaceTheme.darkerPrimaryTextColor : subsurfaceTheme.secondaryTextColor color: selected ? subsurfaceTheme.darkerPrimaryTextColor : subsurfaceTheme.secondaryTextColor
} }
// spacer, just in case // spacer, just in case
@ -223,6 +225,7 @@ Kirigami.ScrollablePage {
text: (undefined !== depthDuration) ? depthDuration : "" text: (undefined !== depthDuration) ? depthDuration : ""
width: Math.max(Kirigami.Units.gridUnit * 3, paintedWidth) // helps vertical alignment throughout listview width: Math.max(Kirigami.Units.gridUnit * 3, paintedWidth) // helps vertical alignment throughout listview
font.pointSize: subsurfaceTheme.smallPointSize font.pointSize: subsurfaceTheme.smallPointSize
font.strikeout: isInvalid
color: selected ? subsurfaceTheme.darkerPrimaryTextColor : subsurfaceTheme.secondaryTextColor color: selected ? subsurfaceTheme.darkerPrimaryTextColor : subsurfaceTheme.secondaryTextColor
} }
} }
@ -230,6 +233,7 @@ Kirigami.ScrollablePage {
id: numberText id: numberText
text: "#" + number text: "#" + number
font.pointSize: subsurfaceTheme.smallPointSize font.pointSize: subsurfaceTheme.smallPointSize
font.strikeout: isInvalid
color: selected ? subsurfaceTheme.darkerPrimaryTextColor : subsurfaceTheme.secondaryTextColor color: selected ? subsurfaceTheme.darkerPrimaryTextColor : subsurfaceTheme.secondaryTextColor
anchors { anchors {
right: parent.right right: parent.right