Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Qt Creator 2.6.2 Intellisense or autocomplete does not work for headers in precompiled header.
Qt 6.11 is out! See what's new in the release blog

Qt Creator 2.6.2 Intellisense or autocomplete does not work for headers in precompiled header.

Scheduled Pinned Locked Moved General and Desktop
4 Posts 4 Posters 5.2k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • ? Offline
    ? Offline
    A Former User
    wrote on last edited by
    #1

    Hi All,

    I have moved all my header inclusions from cpp files in project to precompiled header. In such case Intellisense or autocomplete does not work for identifiers declared/defined in those headers. Compiling works absolutely fine because of following code in .pro file:
    @
    CONFIG += precompile_header
    PRECOMPILED_HEADER = Precompiled.h
    precompile_header:!isEmpty(PRECOMPILED_HEADER) {
    DEFINES += USING_PCH
    }
    @

    Can someone suggest how to make it work without having to move the headers back in respective cpp files.

    Thank you,

    Best Regards.

    1 Reply Last reply
    0
    • JeroentjehomeJ Offline
      JeroentjehomeJ Offline
      Jeroentjehome
      wrote on last edited by
      #2

      I don't think that will work at all for intellisense and autocomplete. The pro file is for the compiler to read and maybe creator is smart enough to grab some defines from it to use in source files. Maybe try this in the tools forum instead. Might be a smart guy out there who knows.

      Greetz, Jeroen

      1 Reply Last reply
      0
      • S Offline
        S Offline
        Sam
        wrote on last edited by
        #3

        I suggest you to close all the other projects in the session and keep only the current and dependent projects, After that try the following

        Restart Qt Creator and check if it works, if not then try

        1. Right Click on your project in project tree ->Clean
        2. Right Click on your project in project tree ->Run qmake
        3. Right Click on your project in project tree ->Build
        4. Run.

        If that too does not work then go to your project directory in windows explorer and try to delete all the make files manually.

        makefile
        makefile.debug
        makefile.release
        yourProject.pro.user

        Restart Qt Creator and open the project again.

        Check if this works.

        1 Reply Last reply
        0
        • ? Offline
          ? Offline
          A Former User
          wrote on last edited by
          #4

          Hello,

          i am use creator 2.7.1 and lib 4.8.4 with VirtualBox on windows7 . The IDE is not loading the members if i try to get acces via . do you now if i have to set something in the settings or to install an additional plug in for auto code completion?

          Thank you fo your help.

          @
          QByteArray data;
          QString sdata;
          data.append("test1\r\ntest2\r\ntest3\r\n");
          data.append("test4\r\ntest5\r\ntest6\r\n");
          @

          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved