Close Project command: any way to also close all open documents for a specific project?
-
This may have been askec before but I've searched around and didn't see any questions on it.
Qt Creator has a "Close Project" command but it doesn't close document files (i.e. it leaves them in the Editor and listed in the "Open Documents" pane). This seems odd and results in a lot of leftover clutter. If I just open a project to check syntax or copy a method, it's a couple of clicks just to close it again.
The command "Close all projects and editors closes everything. With "Close Project," is there some keyboard option to also close all documents associated with a project?
-
Hi,
I didn't see that option either, this might be a good suggestion to make to the QtCreator team
-
I don't know the protocol for making a feature request but posted in the Beta forum since that seemed a possible spot: "[Feature Req- Qt Creator] “Close Project” command should close all associated documents":http://qt-project.org/forums/viewthread/31161/
-
Everything bug/feature related can be reported/asked on "Jira":bugreports.qt-project.org/
-
Just got notified that this feature request got closed as a duplicate.
-
If it's a duplicate at least it means that there is already work going in this way
-
Alas no. It was closed as duplicate with the comment:
bq. "Please consider to switch between sessions. We do not close files along with a project since it is hard to reliably tell which files belong to which project."
Seemed an odd reason/limitation – not to know what files are associated with which project. The duplicates were also closed.
I'm new to Qt, coming from iOS dev with Xcode, and haven't used Sessions yet. It seems like those are more geared to discreetly defined projects. I jump around between lots of example projects and end up with lots of cruft in y "open documents" and "editor" windows.
Oh well.
-
In the same step also some older reports relating to the same issue have been closed.
The comment is correct. If you have two application projects sharing the same lib code, creator cannot know for which project those files have been opened.
Personally I would not mind if too many files would be closed. Either option closing one keep the rest or keeping one and close the rest are sometimes a bit tedious.
-
Not arguing this but one would think it would be possible to scan the open .pro files to see if there are shared files. Aren't all sources listed there? If an open file is part of an included lib (and not listed in .pro), then don't close it.
But I'm new to Qt and maybe there are bigger underlying issues.
-
I think it is slightly more than that. If you are using subdirs templates it will become complicated. Nevertheless, it seems manageable.
However, if I understand correctly, the "sessions" seem to cover all this, so why opening a complicated construction area when not necessary.