mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
QML-UI: Rearrange the DiveDetails page
After adding "Cylinder" to the DiveDetails page the objects had to be rearranged in order to better utilise the space. To get a cleaner look on smaller screens the left side is left aligned and the right side is right aligend. Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
37d841966f
commit
1c3a1433e4
1 changed files with 37 additions and 21 deletions
|
@ -65,14 +65,16 @@ Item {
|
||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
MobileComponents.Label {
|
MobileComponents.Label {
|
||||||
Layout.alignment: Qt.AlignRight
|
Layout.alignment: Qt.AlignLeft
|
||||||
id: dateLabel
|
id: dateLabel
|
||||||
text: "Date: "
|
text: "Date: "
|
||||||
opacity: 0.6
|
opacity: 0.6
|
||||||
}
|
}
|
||||||
MobileComponents.Label {
|
MobileComponents.Label {
|
||||||
|
Layout.alignment: Qt.AlignLeft
|
||||||
text: dive.date + " " + dive.time
|
text: dive.date + " " + dive.time
|
||||||
Layout.columnSpan: 2
|
Layout.columnSpan: 2
|
||||||
|
Layout.fillWidth: true
|
||||||
}
|
}
|
||||||
MobileComponents.Label {
|
MobileComponents.Label {
|
||||||
id: numberText
|
id: numberText
|
||||||
|
@ -82,12 +84,13 @@ Item {
|
||||||
}
|
}
|
||||||
|
|
||||||
MobileComponents.Label {
|
MobileComponents.Label {
|
||||||
Layout.alignment: Qt.AlignRight
|
Layout.alignment: Qt.AlignLeft
|
||||||
id: depthLabel
|
id: depthLabel
|
||||||
text: "Depth: "
|
text: "Depth: "
|
||||||
opacity: 0.6
|
opacity: 0.6
|
||||||
}
|
}
|
||||||
MobileComponents.Label {
|
MobileComponents.Label {
|
||||||
|
Layout.alignment: Qt.AlignLeft
|
||||||
text: dive.depth
|
text: dive.depth
|
||||||
}
|
}
|
||||||
MobileComponents.Label {
|
MobileComponents.Label {
|
||||||
|
@ -97,6 +100,7 @@ Item {
|
||||||
}
|
}
|
||||||
MobileComponents.Label {
|
MobileComponents.Label {
|
||||||
text: dive.duration
|
text: dive.duration
|
||||||
|
Layout.alignment: Qt.AlignRight
|
||||||
}
|
}
|
||||||
|
|
||||||
QMLProfile {
|
QMLProfile {
|
||||||
|
@ -113,7 +117,6 @@ Item {
|
||||||
border.width: 1
|
border.width: 1
|
||||||
border.color: MobileComponents.Theme.textColor;
|
border.color: MobileComponents.Theme.textColor;
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -125,7 +128,7 @@ Item {
|
||||||
}
|
}
|
||||||
|
|
||||||
MobileComponents.Label {
|
MobileComponents.Label {
|
||||||
Layout.alignment: Qt.AlignRight
|
Layout.alignment: Qt.AlignLeft
|
||||||
text: "Air Temp:"
|
text: "Air Temp:"
|
||||||
opacity: 0.6
|
opacity: 0.6
|
||||||
}
|
}
|
||||||
|
@ -137,26 +140,25 @@ Item {
|
||||||
}
|
}
|
||||||
|
|
||||||
MobileComponents.Label {
|
MobileComponents.Label {
|
||||||
Layout.alignment: Qt.AlignRight
|
Layout.alignment: Qt.AlignLeft
|
||||||
text: "Water Temp:"
|
text: "Water Temp:"
|
||||||
opacity: 0.6
|
opacity: 0.6
|
||||||
}
|
}
|
||||||
MobileComponents.Label {
|
MobileComponents.Label {
|
||||||
id: txtWaterTemp
|
id: txtWaterTemp
|
||||||
text: dive.waterTemp
|
text: dive.waterTemp
|
||||||
Layout.fillWidth: true
|
|
||||||
wrapMode: TextEdit.WrapAtWordBoundaryOrAnywhere
|
wrapMode: TextEdit.WrapAtWordBoundaryOrAnywhere
|
||||||
|
Layout.alignment: Qt.AlignRight
|
||||||
}
|
}
|
||||||
|
|
||||||
MobileComponents.Label {
|
MobileComponents.Label {
|
||||||
Layout.alignment: Qt.AlignRight
|
Layout.alignment: Qt.AlignLeft
|
||||||
text: "Suit:"
|
text: "Suit:"
|
||||||
opacity: 0.6
|
opacity: 0.6
|
||||||
}
|
}
|
||||||
MobileComponents.Label {
|
MobileComponents.Label {
|
||||||
id: txtSuit
|
id: txtSuit
|
||||||
text: dive.suit
|
text: dive.suit
|
||||||
Layout.fillWidth: true
|
|
||||||
wrapMode: TextEdit.WrapAtWordBoundaryOrAnywhere
|
wrapMode: TextEdit.WrapAtWordBoundaryOrAnywhere
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -170,10 +172,35 @@ Item {
|
||||||
//text: dive.weights
|
//text: dive.weights
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
wrapMode: TextEdit.WrapAtWordBoundaryOrAnywhere
|
wrapMode: TextEdit.WrapAtWordBoundaryOrAnywhere
|
||||||
|
Layout.alignment: Qt.AlignRight
|
||||||
}
|
}
|
||||||
|
|
||||||
MobileComponents.Label {
|
MobileComponents.Label {
|
||||||
|
Layout.alignment: Qt.AlignLeft
|
||||||
|
text: "Cylinder:"
|
||||||
|
opacity: 0.6
|
||||||
|
}
|
||||||
|
MobileComponents.Label {
|
||||||
|
id: txtCylinder
|
||||||
|
text: cylinder
|
||||||
|
Layout.fillWidth: true
|
||||||
|
wrapMode: TextEdit.WordWrap
|
||||||
|
}
|
||||||
|
|
||||||
|
MobileComponents.Label {
|
||||||
|
Layout.alignment: Qt.AlignLeft
|
||||||
|
text: "Dive Master:"
|
||||||
|
opacity: 0.6
|
||||||
|
}
|
||||||
|
MobileComponents.Label {
|
||||||
|
id: txtDiveMaster
|
||||||
|
text: dive.divemaster
|
||||||
|
wrapMode: TextEdit.WrapAtWordBoundaryOrAnywhere
|
||||||
Layout.alignment: Qt.AlignRight
|
Layout.alignment: Qt.AlignRight
|
||||||
|
}
|
||||||
|
|
||||||
|
MobileComponents.Label {
|
||||||
|
Layout.alignment: Qt.AlignLeft
|
||||||
text: "Buddy:"
|
text: "Buddy:"
|
||||||
opacity: 0.6
|
opacity: 0.6
|
||||||
}
|
}
|
||||||
|
@ -181,19 +208,8 @@ Item {
|
||||||
id: txtBuddy
|
id: txtBuddy
|
||||||
text: dive.buddy
|
text: dive.buddy
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
wrapMode: TextEdit.WrapAtWordBoundaryOrAnywhere
|
wrapMode: TextEdit.WordWrap
|
||||||
}
|
Layout.columnSpan: 3
|
||||||
|
|
||||||
MobileComponents.Label {
|
|
||||||
Layout.alignment: Qt.AlignRight
|
|
||||||
text: "Dive Master:"
|
|
||||||
opacity: 0.6
|
|
||||||
}
|
|
||||||
MobileComponents.Label {
|
|
||||||
id: txtDiveMaster
|
|
||||||
text: dive.divemaster
|
|
||||||
Layout.fillWidth: true
|
|
||||||
wrapMode: TextEdit.WrapAtWordBoundaryOrAnywhere
|
|
||||||
}
|
}
|
||||||
|
|
||||||
MobileComponents.Heading {
|
MobileComponents.Heading {
|
||||||
|
|
Loading…
Add table
Reference in a new issue