Uploaded image for project: 'Qt Design Studio'
  1. Qt Design Studio
  2. QDS-10271

Properties View: Make "Custom Properties" editable from the parent's editor

    XMLWordPrintable

Details

    Description

      Code

      // MyWidget.ui.qml
      import QtQuick
      import QtQuick.Controls.Basic
      
      Item {
          width: 200
          height: 100
      
          property alias myRectangle: myRectangle
          property alias myButton: myButton
          property alias myItem: myItem
      
          Rectangle {
              id: myRectangle
              color: "green"
              property string description: "A Rectangle"
          }
      
          Button {
              id: myButton
              checkable: true
              property string description: "A Button"
          }
      
          Item {
              id: myItem
              property string description: "An Item"
          }
      }
      
      // MyScreen.ui.qml
      import QtQuick
      
      Rectangle {
          width: 640
          height: 480
      
          MyWidget {
              id: widget
          }
      }
      

       

      Property editor capabilities (QtDS 4.2.0)
      Editor when MyWidget.ui.qml is active:

       

      Editor when MyScreen.ui.qml is active:

       

      Suggestions

      Reference point: When MyScreen.ui.qml is active, the property editor lets us edit widget.myRectangle.color and other "built-in" Rectangle properties under "Exposed Custom Properties". That's good.

      I suggest that this capability be extended so that we can similarly edit:

      • Properties that are user-defined (widget.myRectangle.description, widget.myButton.description, and widget.myItem.description)
      • Properties that are not user-defined but are still considered "custom" by the Properties View (widget.myButton.checkable et al.)

      Attachments

        1. qds-propeditor-inner.png
          qds-propeditor-inner.png
          79 kB
        2. qds-propeditor-outer.png
          qds-propeditor-outer.png
          34 kB
        3. screenshot-1.png
          screenshot-1.png
          22 kB

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              thohartm Thomas Hartmann
              skoh-qt Sze Howe Koh
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes