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

Follow symbol under cursor opens file in build directory

    XMLWordPrintable

Details

    • a235aa29a1 (qt-creator/qt-creator/8.0) a235aa29a1 (qt-creator/qt-creator/master) a235aa29a1 (qt-creator/tqtc-qt-creator/8.0) 129448d61d (qt-creator/qt-creator/9.0) 129448d61d (qt-creator/qt-creator/qds/dev) 129448d61d (qt-creator/qt-creator/master)

    Description

      If QML modules are made through qt_add_qml_module, qml files there are copied to build directory as they should be. However, because import path points to build directory, Qt Creator opens qml files from that build directory instead of from source directory.

      To reproduce:

      • build attached project
      • Tools -> QML/JS -> Reset code model
      • open main.qml
      • ctrl+click Broken component there

      this opens the file from build directory.

      This is a big problem as it can lead to lost code as the file is overridden by the build process so all changes user might do would disappear.

      While this is probably pretty hard to fix, maybe a simple fix would be to make Qt Creator display a banner saying that the file is generated or just that it exists in the build directory. Or maybe even doesn't allow editing it (read-only) by default.

      Attachments

        Issue Links

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

          Activity

            People

              madwinter Marcus Tillmanns
              poikelin Joni Poikelin
              Votes:
              4 Vote for this issue
              Watchers:
              12 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes