Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-99638

Capitalized properties used in QML that come from C++ do not error on runtime

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Reported
    • Priority: P3: Somewhat important
    • Resolution: Unresolved
    • Affects Version/s: 6.2.2
    • Fix Version/s: None
    • Labels:
      None
    • Platform/s:
      All

      Description

      Any property declared in QML that begins with a capital letter will error out in QML runtime. This is not the case for properties declared in C++ but used in QML.

      This inconsistency is unfortunate as it can confuse the situation when developers and designers use the best practices of using mock properties declared in QML to provide a temporary backend for Qt Design Studio that are then replaced by properties that come from C++ for the real application. This can result in a developer for instance declaring a property with a capital letter and then adding this to the mocked properties in QML also with a capital letter. Unless the developer is aware to check the mocked properties in design studio she won't be aware that there is a problem.

      If at all possible, the QML runtime should abort when it encounters an uppercase property declared in C++ but used in QML so that behavior is consistent and confusion does not arise.

        Attachments

          Issue Links

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

            Activity

              People

              Assignee:
              qtqmlteam Qt Qml Team User
              Reporter:
              peter.rohles Peter Rohles
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:

                  Gerrit Reviews

                  There are no open Gerrit changes