-
Notifications
You must be signed in to change notification settings - Fork 4.5k
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
Select and find next/previous uses search mode #3229
Comments
I agree. Since I use the RegExp-Search quite often, it is the "last mode" most of the time. And every time I try to use the Shift+F3 feature to save time, it does the quite opposite and wastes it. I would really appreciate if the Shift-F3-Keystroke would automatically switch the search mode to normal, since everything else seems the way more uncommon intent of the user. (At least allow to enable this automatically switching in the options) |
But other Find options from the Find window affect this type of search invocation as well:
Change your test data to the following and then play around with how the "Select and Find Next/Prev" searches work in conjunction with the settings listed above:
Aren't these settings (whole-word, match case, wrap) also a problem for an unsuspecting user? The "safest" thing to do might be to automatically set the following up for a "Select and Find Next/Prev" invocation:
This will find the maximum amount of matches for this speedy type of searching; if the user doesn't like that, he can "slow down a bit" and do a "real" search using the actual Find window and its "Find Next" button in conjunction with "Backward direction" checkbox (or equivalently, the "<<" and ">>" buttons). The above works well if one continues to reinvoke "Select and Find Next/Prev" for each match encountered. But if one only invokes that specific command for the first invocation and then switches to the keyboard equivalent for "Find Next", that will revert to using the Find window settings that we are trying to escape for this scenario. [I noticed that in conjunction with testing a possible code change...and I saw that the "Find what" box would change to the "lowercase" version of So for good or bad, it seems like these features (interactive Find, Select-and-Find, (keyboard)Find-next) might be inexorably tied together... |
I think, this would be another good candidate to "reset" for as fast search. |
@2chg |
OK, I see. The quick search ignores this directional option. My fault. |
FWIW, I made a Pythonscript for the desired behavior. I call it It can be tied to the keycombo for the native N++ command Depending upon how you like this type of search to work, change these lines to either assign
Here's the script:
|
Description of the Issue
When selecting text and pressing [Shift]+[F3], or selecting "Select and find next" from the search menu will select the next instance of the selected text. But if, for instance, the selected text contains regex characters and the search mode is set to "Regular expression", then it will use the selected text as regex search string, instead of searching for the literal selected text
Steps to Reproduce the Issue
Expected Behavior
I don't know if people use the select and find next with regular expressions, but I expect to only use the normal search mode with this. so would it be possible to have the search mode during "select and find next" either hard coded to "Normal" or have a setting for this?
Since the search mode is not visible during use of "select and find next", this makes it somewhat irritating when it is still set to anything other than Normal.
Debug Information
Notepad++ v7.3.3 (32-bit)
Build time : Mar 8 2017 - 03:37:37
Path : C:\Program Files (x86)\Notepad++\notepad++.exe
Admin mode : ON
Local Conf mode : OFF
OS : Windows 7 (64-bit)
Plugins : ComparePlugin.dll NotepadStarterPlugin.dll NppConverter.dll NppExport.dll OpenSelection.dll PluginManager.dll Python Indent.dll regrexplace.dll ReloadButton.dll XMLTools.dll
The text was updated successfully, but these errors were encountered: