Vim: Scrolling a file with no line-breaks
When a file has no line-breaks and is just one single line, navigating line by line is obviously not an option. Some editors wrap the text and treat each pseudo-line as a separate element and allow us to scroll through them. Others don't. Vim, by default doesn't.
Or to be more precise, Vim (and GVim) do not allow us to scroll through such files using the arrow keys. Instead, the following short-cuts do the business:
Scroll up: g, k / g, up
Scroll down: g, j / g, down
Beginning of the line: g, ^ [i.e. g, SHIFT + 6 on a keyboard with a US layout]
Tags:
- Read more about Vim: Scrolling a file with no line-breaks
- Log in to post comments