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

[REG 3.6.1->4.x] Auto-generated includes from UIC are not parsed properly

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • Qt Creator 4.14.0-beta2
    • Qt Creator 4.0.3, Qt Creator 4.1.0, Qt Creator 4.2.0, Qt Creator 4.2.1
    • None
    • QtCreator 4.2.1, Linux
    • f7399d520e8a6b7cbf133c60285d5ef7479e8d1c (qt-creator/qt-creator/4.14)

    Description

      Included auto-generated ui files aren't parsed properly.

      #include "ui_MainWindow.h"
      

      This causes that all clases which are only included in auto-generated ui file aren't available for completer and highlighter.

      In UiFile.png attachment you can see that no class is highlighted (which is properly included and known to the compiler).

      E.g. If I manually change the ui file name or ui file location (for test purpose only) then QtCreator parses it properly.

      This bug exists on both: CMake and QMake projects.

      Steps to reproduce:

      • unpack "UiCompletion.zip",
      • open CMake or QMake project,
      • compile,
      • go to "MainWindow.hpp" and open auto-generated "ui_MainWindow.h" file,
      • notice, that it is not parsed properly,
      • try to use completer on e.g. QToolBar which is included only in the ui file - nothing happens.

      This bug can be related to QTCREATORBUG-16578.

      Attachments

        1. UiCompletion.zip
          3 kB
        2. UiFile.png
          UiFile.png
          73 kB
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            kandeler Christian Kandeler
            zaps166 Błażej Szczygieł
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes