Skip to content

OpenSelectedPathnames Clarification #758

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions content/docs/searching.md
Original file line number Diff line number Diff line change
Expand Up @@ -285,9 +285,15 @@ In v8.7.5, the algorithm is standardized to:

There is a capability to copy the list of files containing hits from past searches (v8.0.0 and later). The **Copy Selected Pathname(s)** context menu command (known as **Copy Pathname(s)** from v8.0.0 to v8.7.1) copies to the clipboard the full pathnames of all the files for any lines selected in **Search results**. The list copied to the clipboard will contain one line for each pathname. From v8.0.0 to v8.7.1, **Copy Pathname(s)** would copy all pathnames from all prior searches. Starting in v8.7.2, if you have selected search results that include a pathname line (even partially), or if the [caret](#caret-and-cursor "typing/insertion cursor") with no selected text is on one of the search result pathname lines, then this action will copy the pathname associated with each search result entry so selected. Running this action on never-saved files, like the `new 1` tabs (even if they've been manually renamed but not yet saved), will use the tab's name as the "pathname", since there is no filesystem path associated with such tabs. To mimic the behavior of **Copy Pathname(s)** from earlier software in v8.7.2 and later, select all text in search-results before running the action.

##### Opening path(s) from the **Search results** window

Prior to v8.7.2, the **Open all** command in the **Search Results** right-click context menu would open _all_ the files from your **Search Results** window. If you had done multiple searches that were still listed in that window, _all_ of those files will be opened. there was no way to open just a few of the files, or just the files from a particular search.

Starting in v8.7.2, that **Open all** command was removed, and was replaced with **Open selected pathname(s)**, which will open the file(s) associated with selected search results, following the same selection/[caret](#caret-and-cursor "typing/insertion cursor") logic as **Copy Selected Pathname(s)** (described above); if the file is already opened, it will not be opened a second time (but it will activate that file's tab if there's only one in the selection). If you want the old **Open all**-style behavior, you can use <kbd>Ctrl+A</kbd> (or **Select all**) then **Open selected pathname(s)**.

##### Other commands

The **Search results** window/tab accumulates results from every **Find All in ...** search the user does; the results from old searches remain until the user removes them. Individual results can be deleted with the <kbd>Delete</kbd> key, or all previous results can be deleted by invoking **Clear all**. Stale results can be removed to reduce visual clutter, or when it is desired that a follow-on action should not be affected by old results. An example of this would be the **Open all** command which opens *all* files listed in the **Search results** tab that have previously had hits. If the search history in **Search results** is really long, it may not be desirable to open all files listed there, so using **Clear all** before doing some new searches with the intent to **Open all** afterwards may be the thing to do.
The **Search results** window/tab accumulates results from every **Find All in ...** search the user does; the results from old searches remain until the user removes them. Individual results can be deleted with the <kbd>Delete</kbd> key, or all previous results can be deleted by invoking **Clear all**. Stale results can be removed to reduce visual clutter, or when it is desired that a follow-on action should not be affected by old results.

The **Select all** command is self-explanatory: All text in the **Search results** tab is selected.

Expand All @@ -297,8 +303,6 @@ The user can fold/unfold "branches" of this tree. To fold, click with the mouse

The **Fold all** and **Unfold all** commands perform the corresponding actions on all elements of the entire result history in the **Search results** window at once. (These were called **Collapse all** and **Uncollapse all** before v8.4.6.)

Starting in v8.7.2, **Open selected pathname(s)** will open the file(s) associated with selected search results (following the same selection/[caret](#caret-and-cursor "typing/insertion cursor") logic as **Copy Selected Pathname(s)** (described above); if the file is already opened, it will not be opened a second time (but it will activate that file's tab if there's only one in the selection.)

##### Searching in previously-found results (secondary searching)

Assume that you have done a search and your results are in a tab in the **Search results** window. Now you'd like to conduct a search but with a scope of only the files that have previous matches. Or maybe you want to look only in the *lines* matched by previous searches, not only the matched files, tightening the search criteria even more. Can you do this sort of second-level searching with Notepad++? Yes, by using <kbd>RightClick</kbd> in the **Search results** window client area and selecting **Find in these search results...**.
Expand Down