Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. Project Tree: Source and Headers Inconsistent View
Forum Updated to NodeBB v4.3 + New Features

Project Tree: Source and Headers Inconsistent View

Scheduled Pinned Locked Moved Solved Qt Creator and other tools
4 Posts 3 Posters 579 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.
  • C Offline
    C Offline
    Calvin H-C
    wrote on last edited by
    #1

    On the tree/folders showing the files in the project, the header files are shown directly under the project name as I would expect them to, but the source files have a whole directory tree all the way down to the project folder:
    db985d23-8bd5-4814-a943-0a83b5a905c9-image.png

    I would prefer to see both the source and headers the same way the headers appear, relative to the project folder. I do not need to see the entire directory tree all the way down to the project folder.

    Is there a way to change this?

    Christian EhrlicherC M 2 Replies Last reply
    0
    • Christian EhrlicherC Christian Ehrlicher moved this topic from General and Desktop on
    • Christian EhrlicherC Christian Ehrlicher

      Don't use absolute paths for your source files in your project.

      C Offline
      C Offline
      Calvin H-C
      wrote on last edited by
      #4

      @Christian-Ehrlicher said in Project Tree: Source and Headers Inconsistent View:

      Don't use absolute paths for your source files in your project.

      I am not. Both source and headers are specified in EXACTLY the same way, but one is being displayed with the absolute path and the other isn't.

      That said, in fixing an unrelated problem, I had to re-create the project file (changing from cmake to qmake). This fixed this problem and now both show relative to the project directory. It doesn't explain why it was doing that, but since I won't be switching back, it doesn't matter for me.

      1 Reply Last reply
      0
      • C Calvin H-C

        On the tree/folders showing the files in the project, the header files are shown directly under the project name as I would expect them to, but the source files have a whole directory tree all the way down to the project folder:
        db985d23-8bd5-4814-a943-0a83b5a905c9-image.png

        I would prefer to see both the source and headers the same way the headers appear, relative to the project folder. I do not need to see the entire directory tree all the way down to the project folder.

        Is there a way to change this?

        Christian EhrlicherC Offline
        Christian EhrlicherC Offline
        Christian Ehrlicher
        Lifetime Qt Champion
        wrote on last edited by
        #2

        Don't use absolute paths for your source files in your project.

        Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
        Visit the Qt Academy at https://academy.qt.io/catalog

        C 1 Reply Last reply
        0
        • C Calvin H-C

          On the tree/folders showing the files in the project, the header files are shown directly under the project name as I would expect them to, but the source files have a whole directory tree all the way down to the project folder:
          db985d23-8bd5-4814-a943-0a83b5a905c9-image.png

          I would prefer to see both the source and headers the same way the headers appear, relative to the project folder. I do not need to see the entire directory tree all the way down to the project folder.

          Is there a way to change this?

          M Offline
          M Offline
          mpergand
          wrote on last edited by mpergand
          #3

          @Calvin-H-C
          You have several options in Filter Tree pull down menu:
          Simplify tree and Hide header and source groups

          see Projects View Toolbar here:
          https://doc.qt.io/qtcreator/creator-projects-view.html

          1 Reply Last reply
          0
          • Christian EhrlicherC Christian Ehrlicher

            Don't use absolute paths for your source files in your project.

            C Offline
            C Offline
            Calvin H-C
            wrote on last edited by
            #4

            @Christian-Ehrlicher said in Project Tree: Source and Headers Inconsistent View:

            Don't use absolute paths for your source files in your project.

            I am not. Both source and headers are specified in EXACTLY the same way, but one is being displayed with the absolute path and the other isn't.

            That said, in fixing an unrelated problem, I had to re-create the project file (changing from cmake to qmake). This fixed this problem and now both show relative to the project directory. It doesn't explain why it was doing that, but since I won't be switching back, it doesn't matter for me.

            1 Reply Last reply
            0
            • C Calvin H-C has marked this topic as solved on

            • Login

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