Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I find that navigating text files that have been word wrapped somewhat difficult in vi. If there is a line that is word-wrapped and it goes down several lines, then it is hard to navigate around this line using the arrow keys. If you're on a line that's word-wrapped and you press up, it won't go up to the line above, it will go up several lines. How can this be fixed?

share|improve this question
up vote 5 down vote accepted

If your vi is really Vim, then you can move up and down a screen column using gk and gj. Since two keystrokes per movement isn't convenient, you can create a mapping to make it easier, e.g.,

:nnoremap k gk
:nnoremap j gj

or

:nmap <Up> gk
:nmap <Down> gj
share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .