Repeater3DSection.qml 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. // Copyright (C) 2021 The Qt Company Ltd.
  2. // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
  3. import QtQuick 2.15
  4. import QtQuick.Layouts 1.15
  5. import HelperWidgets 2.0
  6. import StudioTheme 1.0 as StudioTheme
  7. Section {
  8. caption: qsTr("Repeater")
  9. width: parent.width
  10. SectionLayout {
  11. PropertyLabel {
  12. text: qsTr("Model")
  13. tooltip: qsTr("The model providing data for the repeater. This can simply specify the number of delegate instances to create or it can be bound to an actual model.")
  14. }
  15. SecondColumnLayout {
  16. LineEdit {
  17. backendValue: backendValues.model
  18. showTranslateCheckBox: false
  19. writeAsExpression: true
  20. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  21. + StudioTheme.Values.actionIndicatorWidth
  22. width: implicitWidth
  23. }
  24. ExpandingSpacer {}
  25. }
  26. PropertyLabel {
  27. text: qsTr("Delegate")
  28. tooltip: qsTr("The delegate provides a template defining each object instantiated by the repeater.")
  29. }
  30. SecondColumnLayout {
  31. ItemFilterComboBox {
  32. typeFilter: "Component"
  33. backendValue: backendValues.delegate
  34. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  35. + StudioTheme.Values.actionIndicatorWidth
  36. }
  37. ExpandingSpacer {}
  38. }
  39. }
  40. }