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

qmllint: produce warnings for string to valuetype conversions

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Unresolved
    • Icon: P2: Important P2: Important
    • 6.11
    • 6.6.0
    • QML: Tooling
    • None
    • 5f84cf00e (dev), aca69f832 (dev), 9cdd485c2 (dev), cdb254058 (dev)

      It seems that qmllint does not warn about string to value type conversion in QML.

      An example might be the `vector2d` types:

      import QtQuick
      
      Item {
          property vector2d myVector: "1.2,1.3"
      }
       

      Here a list of candidates that can be constructed from strings that qmllint should know about

      • point, like "30x50"
      • rect, like "30, 50, 100x150"
      • size, like "30x50"
      • color, like "blue" (that already has its own bugreport in QTBUG-100137)
      • quaternion, like "1,2,3,4" ("scalar,x,y,z")
      • vectorXd, like "1,2" or "1,2,3" or "1,2,3,4"

        For Gerrit Dashboard: QTBUG-118323
        # Subject Branch Project Status CR V

            qtqmlteam Qt Qml Team User
            sami.shalayel Sami Shalayel
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:

                There are no open Gerrit changes