mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-25 15:44:04 -06:00
Add extended description header
Wrapping the whole content so far in another column so that we can have a wider part below, automatically aligned. Contributes to issue CURA-8565.
This commit is contained in:
parent
cfd29b268d
commit
0546f58e57
1 changed files with 316 additions and 280 deletions
|
@ -13,7 +13,7 @@ Rectangle
|
|||
property var packageData
|
||||
property bool expanded: false
|
||||
|
||||
height: UM.Theme.getSize("card").height
|
||||
height: childrenRect.height
|
||||
color: UM.Theme.getColor("main_background")
|
||||
radius: UM.Theme.getSize("default_radius").width
|
||||
|
||||
|
@ -33,6 +33,11 @@ Rectangle
|
|||
target: downloadCount
|
||||
visible: false
|
||||
}
|
||||
PropertyChanges
|
||||
{
|
||||
target: extendedDescription
|
||||
visible: false
|
||||
}
|
||||
},
|
||||
State
|
||||
{
|
||||
|
@ -48,10 +53,25 @@ Rectangle
|
|||
target: downloadCount
|
||||
visible: true
|
||||
}
|
||||
PropertyChanges
|
||||
{
|
||||
target: extendedDescription
|
||||
visible: true
|
||||
}
|
||||
}
|
||||
]
|
||||
|
||||
// Separate column for icon on the left.
|
||||
Column
|
||||
{
|
||||
width: parent.width
|
||||
|
||||
spacing: 0
|
||||
|
||||
Item
|
||||
{
|
||||
width: parent.width
|
||||
height: UM.Theme.getSize("card").height
|
||||
|
||||
Image
|
||||
{
|
||||
id: packageItem
|
||||
|
@ -356,6 +376,22 @@ Rectangle
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Column
|
||||
{
|
||||
id: extendedDescription
|
||||
padding: UM.Theme.getSize("default_margin").width
|
||||
topPadding: 0
|
||||
|
||||
Label
|
||||
{
|
||||
text: catalog.i18nc("@header", "Description")
|
||||
font: UM.Theme.getFont("medium_bold")
|
||||
color: UM.Theme.getColor("text")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
FontMetrics
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue