Warning, /office/klevernotes/src/contents/ui/dialogs/tableMakerDialog/UpDownButtonDelegate.qml is written in an unsupported language. File is not indexed.
0001 // SPDX-License-Identifier: GPL-2.0-or-later 0002 // SPDX-FileCopyrightText: 2023 Louis Schul <schul9louis@gmail.com> 0003 0004 import QtQuick 2.15 0005 import QtQuick.Controls 2.15 0006 import QtQuick.Layouts 1.15 0007 0008 import org.kde.kirigami 2.19 as Kirigami 0009 import org.kde.kirigamiaddons.formcard 1.0 0010 0011 AbstractFormDelegate { 0012 id: root 0013 0014 // see https://doc.qt.io/qt-6/qt.html#ArrowType-enum 0015 property int arrowDirection: Qt.NoArrow 0016 0017 focusPolicy: Qt.StrongFocus 0018 0019 ToolTip.text: text 0020 ToolTip.delay: Kirigami.Units.toolTipDelay 0021 ToolTip.visible: hovered 0022 0023 contentItem: RowLayout { 0024 spacing: 0 0025 0026 Label { 0027 text: root.text 0028 color: root.enabled ? Kirigami.Theme.textColor : Kirigami.Theme.disabledTextColor 0029 elide: Text.ElideRight 0030 wrapMode: Text.WordWrap 0031 maximumLineCount: 2 0032 0033 Layout.margins: 0 0034 Layout.alignment: Qt.AlignVCenter 0035 Layout.fillWidth: true 0036 Layout.fillHeight: true 0037 0038 Accessible.ignored: true // base class sets this text on root already 0039 } 0040 0041 FormArrow { 0042 // 0 = Qt::NoArrow ; 5 = Qt::RightArrow 0043 direction: (0 < root.arrowDirection && root.arrowDirection < 5) ? root.arrowDirection : Qt.NoArrow 0044 0045 Layout.alignment: Qt.AlignRight | Qt.AlignVCenter 0046 Layout.leftMargin: Kirigami.Units.smallSpacing 0047 } 0048 } 0049 0050 Accessible.onPressAction: action ? action.trigger() : root.clicked() 0051 }