| 1 |
/* |
| 2 |
SPDX-FileCopyrightText: %{CURRENT_YEAR} %{AUTHOR} <%{EMAIL}> |
| 3 |
SPDX-License-Identifier: LGPL-2.1-or-later |
| 4 |
*/ |
| 5 |
|
| 6 |
import QtQuick |
| 7 |
import QtQuick.Layouts |
| 8 |
import QtQuick.Controls as QQC2 |
| 9 |
import org.kde.kirigami as Kirigami |
| 10 |
|
| 11 |
ColumnLayout { |
| 12 |
id: root |
| 13 |
property alias cfg_DisplayText: textField.text |
| 14 |
|
| 15 |
RowLayout { |
| 16 |
spacing: Kirigami.Units.largeSpacing |
| 17 |
|
| 18 |
// To allow aligned integration in the settings form, |
| 19 |
// "formAlignment" is a property injected by the config containment |
| 20 |
// which defines the offset of the value fields |
| 21 |
QQC2.Label { |
| 22 |
Layout.minimumWidth: width |
| 23 |
Layout.maximumWidth: width |
| 24 |
width: formAlignment - Kirigami.Units.largeSpacing * 2 |
| 25 |
horizontalAlignment: Text.AlignRight |
| 26 |
|
| 27 |
// use i18nd in config QML, as the default textdomain is set to that of the config container |
| 28 |
text: i18nd("plasma_wallpaper_org.kde.plasma.%{APPNAMELC}", "Text to Display:") |
| 29 |
} |
| 30 |
QQC2.TextField { |
| 31 |
id: textField |
| 32 |
Layout.fillWidth: true |
| 33 |
} |
| 34 |
} |
| 35 |
|
| 36 |
Item { // tighten layout |
| 37 |
Layout.fillHeight: true |
| 38 |
} |
| 39 |
} |