how can i intuitively move cursor in vim?(not by line)

后端 未结 4 951
误落风尘
误落风尘 2020-12-15 22:07

if some lines are too long, it will be forced to be newlined.

for example, normally a long line will looks like this

1 first line
2 this is the long          


        
4条回答
  •  北荒
    北荒 (楼主)
    2020-12-15 22:24

    In Vim, the gj and gk commands move by line on the screen rather than by line in the file. This sounds like it probably matches your description.

    You can modify your keys like this:

    :map j gj
    :map k gk
    

提交回复
热议问题