mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-20 21:27:50 -06:00
Make some minor improvements to the qml
This implements some of the best practices that weren't used yet for the QML CURA-6005
This commit is contained in:
parent
49076a7103
commit
0edc3f2680
6 changed files with 16 additions and 69 deletions
|
@ -13,9 +13,9 @@ RowLayout
|
|||
width: parent.width
|
||||
height: 40 * screenScaleFactor
|
||||
|
||||
property var iconSource
|
||||
property var label
|
||||
property var value
|
||||
property alias iconSource: icon.source
|
||||
property alias label: detailName.text
|
||||
property alias value: detailValue.text
|
||||
|
||||
// Spacing.
|
||||
Item
|
||||
|
@ -23,16 +23,18 @@ RowLayout
|
|||
width: 40 * screenScaleFactor
|
||||
}
|
||||
|
||||
Icon
|
||||
UM.RecolorImage
|
||||
{
|
||||
id: icon
|
||||
width: 18 * screenScaleFactor
|
||||
iconSource: detailsRow.iconSource
|
||||
height: width
|
||||
source: ""
|
||||
color: UM.Theme.getColor("text")
|
||||
}
|
||||
|
||||
Label
|
||||
{
|
||||
text: detailsRow.label
|
||||
id: detailName
|
||||
color: UM.Theme.getColor("text")
|
||||
elide: Text.ElideRight
|
||||
Layout.minimumWidth: 50 * screenScaleFactor
|
||||
|
@ -43,7 +45,7 @@ RowLayout
|
|||
|
||||
Label
|
||||
{
|
||||
text: detailsRow.value
|
||||
id: detailValue
|
||||
color: UM.Theme.getColor("text")
|
||||
elide: Text.ElideRight
|
||||
Layout.minimumWidth: 50 * screenScaleFactor
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue