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

Qt 5 kit cannot handle easing curves

    XMLWordPrintable

Details

    • 3fc66782f (qds/4.1)

    Description

      Steps to reproduce

      1. Launch Qt DS and create a new project that targets Qt 5.15
      2. Replace the generated *.ui.qml file with the sample code below and save the changes
      import QtQuick 2.15
      
      Rectangle {
          id: rectangle
          width: 640
          height: 480
      
          Text {
              id: label
              text: "Hello World"
              anchors.centerIn: parent
          }
      
          PropertyAnimation {
              id: anim
              target: label
              property: "font.pointSize"
              easing.bezierCurve: [0.2, 0.2, 0.8, 0.8, 1, 1]
              running: true
              from: 9
              to: 48
          }
      }
      

       

      Outcomes

      • The code model annotates '"easing" does not have members. (M17)' in the Code pane
      • The 2D designer becomes unusable

       

      Workaround (only usable on Qt DS 3.9, not on Qt DS 4.0)

      Click Tools > QML/JS > Reset Code Model to make the error disappear

       

      Other notes

      • Switching to the Qt 6 kit makes the issue go away
      • If you comment out the easing.bezierCurve line, Qt DS is happy. Qt DS also lets you can launch the Qt DS Easing Curve Editor (https://doc.qt.io/qtdesignstudio/qtquick-editing-easing-curves.html ) to add a curve to the PropertyAnimation. However, clicking "OK" in the editor will also produce the M17 error, and the easing curve code will not be added.

       

      Original report
       

      Preview the QML file error, "much" does not have members. (M17)The correct one is 'easing". Changing to 'Easing' gives you a preview, but it runs incorrectly.

      Attachments

        1. EffectDemo.zip
          215 kB
        2. image-2023-03-11-20-53-39-545.png
          image-2023-03-11-20-53-39-545.png
          39 kB
        3. image-2023-03-30-22-38-00-249.png
          image-2023-03-30-22-38-00-249.png
          48 kB
        4. screenshot-1.png
          screenshot-1.png
          532 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
              zjl111 zhang jinlei
              Votes:
              8 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes