4 ms·
I hear you and I raise you > And if I want to look around a single file, I feel like anything else besides scrolling would be quite inferior in terms of speed
by phatskat 2y ago
I hear you and I raise you
> And if I want to look around a single file, I feel like anything else besides scrolling would be quite inferior in terms of speed and accuracy.
{ and } jump you to the previous/next new line, respectively. Also page up and down work of course, as well as arrows or j/k. But I’m rarely scrolling in vim because I know what I’m looking for and how to get there faster.
> And moving around lines and words is already quite optimal enough without a mouse, using arrows and option/command modifier.
Fair, and in vim you have a single key to jump words (w/W) or the f/F commands (along with ;) to quickly jump through a single character in a line. Example:
This is a string and I want to get to the last letter.
If your cursor is at the beginning of the line, you can just type “fr” and then hit ; until you’re at the “r” in “letter”. Or hit $ since really you just want to get to the end of the line. Or “f.” since there’s only one period. Or…
> And also I use a lot of ctrl + f to move around, which I find quite reliable.
And in Vim you can use / to search ahead, or ? to search behind. And n/N to jump to the next/previous match. Maybe your cursor is on the word you want to find more of in the file? Just hit * to jump to the next instance of it and n/N to jump next/previous.