moment/src/gui/Base/HMenuItem.qml

31 lines
720 B
QML
Raw Normal View History

2019-12-19 22:46:16 +11:00
// SPDX-License-Identifier: LGPL-3.0-or-later
import QtQuick 2.12
import QtQuick.Controls 2.12
MenuItem {
id: menuItem
spacing: theme.spacing
2019-08-22 06:23:22 +10:00
leftPadding: spacing
rightPadding: leftPadding
topPadding: spacing / 1.75
bottomPadding: topPadding
height: visible ? implicitHeight : 0
background: HButtonBackground {
button: menuItem
buttonTheme: theme.controls.menuItem
}
contentItem: HButtonContent {
id: contentItem
button: menuItem
buttonTheme: theme.controls.menuItem
2019-08-22 06:23:22 +10:00
label.horizontalAlignment: Label.AlignLeft
}
readonly property alias iconItem: contentItem.icon
readonly property alias label: contentItem.label
}