码迷,mamicode.com
首页 > 系统相关 > 详细

[Practical.Vim(2012.9)].Drew.Neil.Tip47 学习摘要

时间:2015-04-22 00:39:37      阅读:203      评论:0      收藏:0      [点我收藏+]

标签:vim   real-lines   

Distinguish Between Real Lines and Display Lines

Unlike many text editors, Vim makes a distinction between real lines and display lines. When the ‘wrap’ setting is enabled (and it’s on by default), each line of text that exceeds the width of the window will display as wrapped, ensuring that no text is truncated from view. As a result, a single line in the file may be represented by multiple lines on the display.
在Vim 中区分real linesdisplay lines。对于一个文本,如果一行文字的长度大于显示窗口的宽度,就会自动换为下一行以免被截断。这样原本的单行(real lines)就变为了多行(display lines)。

The easiest way to tell the difference between real lines and display lines is by enabling the ‘number’ setting. Lines that begin with a number correspond to the real lines, which may span one or more display lines.
在vim 的normal模式下中输入命令

:set number

就可以显示文本的行号。以行号开头的行就是real lines
技术分享

Vim中分别提供了直接在real linesdisplay lines中快速上下移动以及在行首和行尾快速跳转的快捷键。
技术分享

[Practical.Vim(2012.9)].Drew.Neil.Tip47 学习摘要

标签:vim   real-lines   

原文地址:http://blog.csdn.net/wdy_yx/article/details/45179575

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!