Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-22839

Importing QML dir by qrc:/ URL results in "Unknown component (M300)"

    XMLWordPrintable

Details

    Description

      If QML directory is imported using "qrc:/..." URL, and a component from this directory is used, editor displays "Unknown component. (M300)" error near the component. Also no completion is provided for the component in this case. The application itself runs without errors. Importing the same directory using a relative path works fine.

      The attached project illustrates this behavior (see screenshots). The message disappears as soon as "qrc:/Controls" is replaced with just "Controls".

      "qrc:/" may seem unnecessary in this particular example, but in a more complex project it's a must. Ability to use absolute paths is important because they're much more maintainable during directory structure changes.

      Attachments

        Activity

          People

            fawzi Fawzi Mohamed
            tonygluk Anton Karandeev
            Votes:
            2 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: