按照
vimtutor技巧,我在第2.3课中找到了以下内容:
Many commands that text are made from an operator and a motion. The format for a follows: d motion Where: d - is the delete operator. motion - is what the operator will operate on (listed below). A short list of motions: w - until the start of the next word,EXCLUDING its first character. e - to the end of the current word,INCLUDING the last character. $- to the end of the line,INCLUDING the last character.
但是,我没有看到dw和de之间的区别.使用dw和de时的用例是什么?
有这样的缓冲区:
Lorem ipsum dolor
在ipsum字的中间移动光标(▒):
Lorem ip▒um dolor
现在按de:
Lorem ip▒dolor
光标删除了当前单词中的字母,直到结束,但没有空格.
在执行dw时,空格将被删除:
Lorem ip▒olor
原文地址:https://www.jb51.cc/vim/384528.html
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。