eclipse viplugin命令大全

1. Switch Mode Commands

CommandDescription
ESC  Switch to command mode
i  Switch to insert mode on current character
a  Switch to insert mode after current character
I  Switch to insert mode on first visible character of the current line
A  Switch to insert mode on last visible character of the current line
o  add a new line after the current line and switch to insert mode
O  add a new line before the current line and switch to insert mode
v  Switch to visual character mode
V  Switch to visual line mode

!   

§

CTRL+V (if
mapped)

  Switch to visual block mode

 

 

 

 

 

 

 

 

 

 

 

 

2. Movement Commands

CommandDescription
hjklmovement keys
wmove one word forward
bMove one word backward
WMove one WORD forward
BMove one WORD backward
eMove to end of word
EMove to end of WORD
ggGo to the first line
GGo to the last line
<n>GGo to the <n>-th line
^Move to first visible character in line
$move to the end of the line
0
| (pipe)
move to the beginning of the line
{Go to next blank line
}Go to previous blank line
%Match brace
HGo to first visible line
LGo to last visible line
MGo to center visible line
+Go to the first visible character in the next line
-Go to the first visible character in the previous line
_Go to first visible character in line
<SPACE>Move one character right (jump to next line if it was the last character
in the line)
<ENTER>Go to the first visible character in the next line

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

3.Delete Commands

CommandDescription
xdelete current character
sdelete current character and switch to Insert Mode
ddDelete current line
dk or d(Up Arrow)delete current line and the line above
dj or d(Down Arrow)delete current line and the line below
dwDelete word
d$Delete to the end of the line
d0Delete to the beginning of the line
cc or SDelete current line and switch to insert mode
cwDelete to the end of the word and switch to insert mode
c$Delete to the end of the line and switch to insert mode
c0Delete to the beginning of the line and switch to insert mode

 

 

 

 

 

 

 

 

 

 

 

4.Other Commands

CommandDescription
yyyank (copy) current line
yyank (copy) selected text to default buffer (clipboard)
"ayyank (copy) selected text to buffer a
ppaste text in default buffer
"appaste text in buffer a
/abcsearch for abc
*search for word under cursor
#search for word under cursor backwards
nsearch again with the last search string
Nsearch backwards with the last search string
.repeat last command
uUndo last change

U
CTRL-R (if
mapped)

Redo last undo
<<Shift line left
>>Shift line right

 

 

 

 

 

 

 

 

 

 

 

 

 

 

5.Ex Commands

Ex commands support ranges e.g.
:.,+1d
:.,$s/foo/bar/g
:1,'ac

Ex-CommandDescription
:dDelete current selection
:cDelete current selection and switch to insert mode
:fs or :fullscreenMaximize editor window
:versionShow viPlugin version information
:registersShow content of registers
:vimExecute external vim application with the currently opened file at the
same line/column. The path to the vim exectuable has to be
configured in the preferences.
:< Shift current selection left
:>Shift current selection right
:taStart Eclipse ?Open Type“ Dialog
:yYank current selection
:e# or :b#Switch to last editor
:t or :co (with
range)
Copy range to specified destination
:mapMap command (easier via preferences)
:imapMap insert mode command (easier via preferences)
:umapUnmap command or insert mode command (easier via preferences)
:m (with range)Move range to specified destination
:wSave file
:wq or :xSave file and close editor
:waSave all
:e!Revert changes
:qClose editor without saving (but ask if there are unsaved changes)
:q!Close editor without saving (and do not ask if there are unsaved changes)
:<nr>go to line number <nr>
:uUndo last change
:redRedo
:newOpen new untitled text file
:nGoto next editor
:N or :prevGoto previous editor
:cn Goto next Problem marker in current editor
:$Goto last line
:<Up-Arrow>Go through Ex command history
:<Down-Arrow>Go through Ex command history
:[%]s/foo/bar/[gic]vi style search and replace
:%s or :sExecute last search/replace command
:g/pattern/cmdExecute cmd on all lines matching pattern. Support commands are d,
y, t and m
:v/pattern/cmdExecute cmd on all lines NOT matching pattern. Support commands
are d, y, t and m

 

 

转载于:https://www.cnblogs.com/LBlogs/archive/2013/01/09/eclipse_viplugin.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值