I do a lot of find using the "In Folder" setting. A hassle is that actions often move the Find window to be not frontmost. The only easy way to bring it to the from is cmd-F, but this re-sets the "In: <where>" dropping down to the default, which is document.
If possible, I'd love this behavior to change to leave things as they were. Preferably even between open/close of the Find window, but certainly when the only actin of cmd-F is to bring the window frontmost, not toggling to a default state would be GREAT.
thoughts?
On 28 Nov 2018, at 6:14, Tim Bates wrote:
I do a lot of find using the "In Folder" setting. A hassle is that actions often move the Find window to be not frontmost. The only easy way to bring it to the from is cmd-F, but this re-sets the "In: <where>" dropping down to the default, which is document.
I normally use the mouse, but just tried ⇧⌘F to refocus the Find window and it preserved the selected folder. That makes sense to me since ⌘F is supposed to be limited to a single document or selection, while ⇧⌘F is for searching something larger like “in folder”.
On 28 Nov 2018, at 8:17, Rob McBroom wrote:
I normally use the mouse, but just tried ⇧⌘F to refocus the Find window and it preserved the selected folder.
Actually, I also use ⌘` quite a lot, and that also seems to preserve the search location. That one is less convenient if you have many projects open, but could work.
On Wed, Nov 28, 2018 at 7:17 AM Rob McBroom mailinglist0@skurfer.com wrote:
I normally use the mouse, but just tried ⇧⌘F to refocus the Find window and it preserved the selected folder. That makes sense to me since ⌘F is supposed to be limited to a single document or selection, while ⇧⌘F is for searching something larger like “in folder”.
I use ⇧⌘F for this purpose all the time and find it convenient.
However, there is a strange issue when you are working with multiple projects open. 1. Bring project1 to the front. Press ⇧⌘F and search in that project. The search window will have a list of matches in project1. 2. Bring project2 to the front (perhaps to make a quick edit). 3. Press ⇧⌘F to bring the search window to the front again. Click on one of the matches that are still in the search window from before. 4. The file with the match is opened as a tab in project2 rather than project1.
Not a big deal but can catch you of guard if you are not expecting it.
Thanks for the ⇧⌘F tip… never seen it. Weirdly, if the find window is closed, ⇧⌘F opens with the user’s directory as the search scope. But if the find window is open, but not front most, ⇧⌘F opens with previous directory as the search scope. And if it’s already open, then ⇧⌘F sets the scope to ~ ...
The behavior of searches that are stale is another issue: clicking on them often also does nothing after an edit has been made.
best, tim
On Wed, Nov 28, 2018 at 7:17 AM Rob McBroom <mailinglist0@skurfer.com mailto:mailinglist0@skurfer.com> wrote:
However, there is a strange issue when you are working with multiple projects open.
- Bring project1 to the front. Press ⇧⌘F and search in that project. The search window will have a list of matches in project1.
- Bring project2 to the front (perhaps to make a quick edit).
- Press ⇧⌘F to bring the search window to the front again. Click on one of the matches that are still in the search window from before.
- The file with the match is opened as a tab in project2 rather than project1.
On 29 Nov 2018, at 2:40, Tim Bates wrote:
Weirdly, if the find window is closed, ⇧⌘F opens with the user’s directory as the search scope.
I assume this part is expected. A feature many may not be aware of is that if focus is in the file browser, it will use the file browser selection as what to search.
This can either be one or more folders, but one can also select files, and then only these files will be searched. I find this extremely useful myself to quick select and search a subset of my project.
An alternative to moving focus to file browser (⌥⌘⇥) and pressing ⇧⌘F is to click the magnifying glass in the file browser’s bottom action bar.
But if the find window is open, but not front most, ⇧⌘F opens with previous directory as the search scope.
This is intended for your use-case where you run a folder search and don’t close the window, so ⇧⌘F brings it back without changing anything.
There is actually a `keepSearchResultsOnDoubleClick` defaults key which can be set to `YES` so that double-clicking search results don’t close the window.
But I don’t find this useful myself as I often will use keyboard to select search results (⌘1-n) followed by ⌘W.
And if it’s already open, then ⇧⌘F sets the scope to ~ ...
If you open the “in” folder pop-up you will see that “Document” is given a shortcut of ⌘F with ⇧⌘F assigned to “Project Folder”. So these two keys can be used to switch between the two search scopes (while the window is open).
The behavior of searches that are stale is another issue: clicking on them often also does nothing after an edit has been made.
The search reuslts are stored as offsets that are not updated on edits, which means after an edit, they will point to the wrong section of the document.
But I am not aware they should become no-ops, if you have steps to reproduce, I will add an issue about this.
As for updating search reuslts on edits; that one is a long-term goal (coupled with a few related issues).
On 28 Nov 2018, at 23:29, Curt Sellmer wrote:
However, there is a strange issue when you are working with multiple projects open.
- Bring project1 to the front. Press ⇧⌘F and search in that
project. The search window will have a list of matches in project1. 2. Bring project2 to the front (perhaps to make a quick edit). 3. Press ⇧⌘F to bring the search window to the front again. Click on one of the matches that are still in the search window from before. 4. The file with the match is opened as a tab in project2 rather than project1.
This has now been fixed in 2.0-rc.22 :)
On Nov 28, 2018, at 7:17 AM, Rob McBroom mailinglist0@skurfer.com wrote:
I normally use the mouse, but just tried ⇧⌘F to refocus the Find window and it preserved the selected folder. That makes sense to me since ⌘F is supposed to be limited to a single document or selection, while ⇧⌘F is for searching something larger like “in folder”.
The problem is that the window has to stay open to preserve the last used folder scope. If you use ⇧⌘F and then double click on something to edit (find window closes), then ⇧⌘F again. All the previous searches are still there, but the "In" scope value is lost. Seems like it should stay the same until the user changes it on purpose.
John DeSoi, Ph.D.
On 29 Nov 2018, at 4:49, John DeSoi wrote:
The problem is that the window has to stay open to preserve the last used folder scope. If you use ⇧⌘F and then double click on something to edit (find window closes), then ⇧⌘F again. All the previous searches are still there, but the "In" scope value is lost. Seems like it should stay the same until the user changes it on purpose.
The problem is that a lot of the time ⇧⌘F is the user saying “I want to do a new folder search with my current project / selected items in the file browser” rather than “bring back the previous search I did”.
But I do run into the case myself, where I want to re-run a search on e.g. selected file browser items or a non-project folder, but has closed the window and thus there is no way to bring it back without resetting the “in” pop-up.
What I have been wanting to add is history to the find dialog with ⌘[ / ⌘] to go back/forward in the history.
That way, one would be able to use ⇧⌘F followed by ⌘[ to open Find in Folder and get back to the previous search folder.
For me, as a heavy keyboard user, I *think* this would be a good solution. I’ll move up the item on my to-do.
On Nov 28, 2018, at 8:34 PM, Allan Odgaard mailinglist@textmate.org wrote:
The problem is that a lot of the time ⇧⌘F is the user saying “I want to do a new folder search with my current project / selected items in the file browser” rather than “bring back the previous search I did”.
I agree, but the other part of the time is that I have a list of results and I need to continue to process and perhaps enter another search in the same folder. And when the find dialog re-appears, everything is the same except that property.
I'm OK with whatever you decide to do, but here is one other idea. Perhaps double clicking to edit should only bring the edit window forward and leave the find window open with no changes. If the user closes the Find window, then that would justify switching the folder search back to the default.
John DeSoi, Ph.D.
On 29 Nov 2018, at 02:34, Allan Odgaard mailinglist@textmate.org wrote:
The problem is that a lot of the time ⇧⌘F is the user saying “I want to do a new folder search with my current project / selected items in the file browser” rather than “bring back the previous search I did”.
A prefs toggle for this would be good. I never use the file browser or project tools (still don’t really understand projects, and while I have tried to set them, project never seems to be right for me: might be that I work on files from more than one “project" at once in a window.
What I have been wanting to add is history to the find dialog with ⌘[ / ⌘] to go back/forward in the history.
That seems like it would be good: Just a key stroke to get back to a prior set of settings.
T
On 1 Dec 2018, at 22:29, Timothy Bates wrote:
What I have been wanting to add is history to the find dialog with ⌘[ / ⌘] to go back/forward in the history.
That seems like it would be good: Just a key stroke to get back to a prior set of settings.
It took a while, but latest build supports pressing ⌘[ (after ⇧⌘F) to go back to previous folder searched.
In this thread, John DeSoi suggested not changing the folder when double-clicking search results (which closes the window and will likely see it be re-opened with ⇧⌘F, which is when it goes to project”) — I do think this change makes sense, but as the folder changes on open (not close), it was not immediately clear how to actually implement this, but I have put it on the to-do.
That works! Can now just hit the normal "⌘[“ combo once or twice to target the right folder to search.
On 11 May 2020, at 01:57, Allan Odgaard mailinglist@textmate.org wrote:
What I have been wanting to add is history to the find dialog with ⌘[ / ⌘] to go back/forward in the history.
latest build supports pressing ⌘[ (after ⇧⌘F) to go back to previous folder searched.
On 1 Dec 2018, at 22:29, Timothy Bates wrote: