在 Vim 可视模式下,为什么命令以 '<,'> 开头? [英] In Vim visual mode, why does the command start with '<,'>?

查看:32
本文介绍了在 Vim 可视模式下,为什么命令以 '<,'> 开头?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

例如,当我进入 Vim 的可视模式以缩进一段文本时,命令提示符总是以 '<,'> 开头.有人可以为我分解为什么会这样或者更确切地说它是做什么的吗?这似乎与标记有关,但根据我目前阅读的手册内容,我并不完全确定这一点.

When I pop into Vim's visual mode to, for example, indent a block of text, the command prompt always starts with '<,'>. Can someone break down for me why this is or rather what it does? It seems like it's got something to do with markers but I'm not entirely sure of this based on the manual stuff I've read so far.

推荐答案

'< 为视觉选择的第一行,'> 为视觉选择的最后一行被选中.这是 vim 使您的命令仅应用于可视区域的方式.

'< is the first line visually selected, and '> is the last line visually selected. This is vim's way of making your command apply to only the visual area.

这篇关于在 Vim 可视模式下,为什么命令以 '&lt;,'&gt; 开头?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆