When I hit ctrl+f
, then paste the searched phrase by ctrl+v
and hit enter
I expect the editor to Find the phrase, not to create another line in search box. Which is very irittating, since I have to manually click on the Find button. It happens now in Sublime Text 3 or program's linux version might be the case. How can I restore the proper behaviour?
4 Answers
I'll bet you are using the enter key on the keypad (right side of the keyboard)
Add a key mapping like this to user key mappings: Preferences -> Key Binding - User
{ "keys": ["keypad_enter"], "command": "find_next", "context":
[{"key": "panel", "operand": "find"}, {"key": "panel_has_focus"}]
}
Source: http://sublimetext.info/docs/en/reference/key_bindings.html
-
Indeed, Enter btn under the Backspace works as expected. Your advise helped to fix this 'issue' with Sublim on the macOS.– MykolaCommented Oct 20, 2021 at 13:29
In Sublime Text 4 it seems the behavior has changed again and makes Enter
add a newline. I've found a way to fix it by adding this to the User Key Bindings:
{ "keys": ["enter"], "command": "find_all",
"context": [{"key": "panel", "operand": "find_in_files"}, {"key": "panel_has_focus"}]
},
-
Had this happen on 1/18/2022 and this was the quick and easy resolution wth Sublime build 4126. Commented Jan 18, 2022 at 16:46
-
I was able to reproduce this behavior in Sublime Text 3, but only when pressing Enter
while still holding down Ctrl+V
. Are you sure you're not pressing Enter
too quickly?
If you are copy/pasting text within Sublime Text 3, you can also highlight the text and press Ctrl+F
to immediately paste the selection into the search box, and use Enter
to search.
For reference, I'm using build 3059 on Ubuntu 12.04 x64
You need to activate the wrap feature. This way the first occurrence will automatically be selected and hitting Enter
should work as expected.
ctrl+d
as I know