fix icon not lining up
This commit is contained in:
parent
f04e6a5e0f
commit
a4b7b42cfe
1 changed files with 23 additions and 7 deletions
|
@ -222,7 +222,7 @@ ColumnLayout {
|
|||
Component {
|
||||
id: libraryDelegate
|
||||
Item {
|
||||
implicitWidth: ListView.view.width
|
||||
implicitWidth: libraryList.width
|
||||
height: selectedLibrary == libraryType ? 50 : 0
|
||||
property bool rightMenu: false
|
||||
property bool selected: selectionModel.hasSelection && selectionModel.currentIndex == innerModel.index(index, 0)
|
||||
|
@ -250,12 +250,13 @@ ColumnLayout {
|
|||
|
||||
implicitWidth: libraryList.width
|
||||
height: selectedLibrary == libraryType ? 50 : 0
|
||||
spacing: Kirigami.Unit.gridUnit * 2.0
|
||||
Controls.Label {
|
||||
id: itemTitle
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: Kirigami.Units.smallSpacing
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: Kirigami.Units.gridUnit * 1.7
|
||||
anchors.leftMargin: Kirigami.Units.gridUnit * 0.7
|
||||
width: parent.width - Kirigami.Units.gridUnit * 3.5
|
||||
|
||||
text: title
|
||||
|
@ -284,7 +285,7 @@ ColumnLayout {
|
|||
anchors.top: itemTitle.bottom
|
||||
anchors.topMargin: Kirigami.Units.smallSpacing
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: Kirigami.Units.gridUnit * 1.7
|
||||
anchors.leftMargin: Kirigami.Units.gridUnit * 0.7
|
||||
width: parent.width - Kirigami.Units.gridUnit * 3.5
|
||||
font.pointSize: 9
|
||||
text: {
|
||||
|
@ -315,10 +316,25 @@ ColumnLayout {
|
|||
}
|
||||
}
|
||||
|
||||
icon.source: itemIcon
|
||||
icon.width: Kirigami.Units.gridUnit
|
||||
icon.height: Kirigami.Units.gridUnit
|
||||
/* supportsMouseEvents: false */
|
||||
Kirigami.Icon {
|
||||
id: trailing
|
||||
anchors.right: parent.right
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.rightMargin: 28
|
||||
implicitWidth: Kirigami.Units.gridUnit
|
||||
source: itemIcon
|
||||
|
||||
Binding on color {
|
||||
when: dragHandler.containsMouse ||
|
||||
(selectionModel.hasSelection &&
|
||||
selectionModel.isSelected(proxyModel.idx(index)))
|
||||
value: Kirigami.Theme.highlightedTextColor
|
||||
}
|
||||
}
|
||||
/* icon.source: itemIcon */
|
||||
/* icon.width: Kirigami.Units.gridUnit */
|
||||
/* icon.height: Kirigami.Units.gridUnit */
|
||||
/* /\* supportsMouseEvents: false *\/ */
|
||||
|
||||
Behavior on height {
|
||||
NumberAnimation {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue