so yet again i have compiled some motion commands for
a beginner's course in "moving about in some text".
enjoy! :)

Sven

-- 
Vimfest 2016 on Sep16-18 in Berlin at IN-Berlin
2016-09-16/18 Fr-Sa VimFest http://vimfest.de/
2016-09-17 14-16h Bram Moolenaar: "Vim-8"
location/venue:  Individual Network Berlin e.V.

---------------------------------------------------------------------
VIM MOTION Commands - 67 lines - compiled by Sven Guckes [2016-09-14]
moving up+down:
h  ←  →  l  jump onto left/right character
j  ↓  ↑  k  jump onto next/prev line, keeping column (if possible)
gj gk       jump onto next/prev *screen* line
jump to start/end of line:
0  $        jump to first column, last column of current line
^           jump to first non-whitespace char of current line
jump to begin/end of words/WORDs:
b w         jump to prev/next begin-of-word
B W         jump to prev/next begin-of-WORD
e ge        jump to next/prev   end-of-word
E gE        jump to next/prev   end-of-WORD
scrolling:
^B ^F       page backward/forward by full page
^D ^U       page     down/up      by 1/2  page
^E ^Y       scroll     up/down    by one line
repositioning the cursor/line on screen:
 H  M  L      position cursor at home, middle, last line of window
zt zz zb    reposition current line at top, middle, bottom line of window
jumping *to* a line by number:
gg G        jump to first/last line
:23         jump to line number 23
42G         jump to line number 42
searching within the current line:
fX FX       jump onto   next/prev char 'X' within current line
tX TX       jump before next/prev char 'X' within current line
f. f:       jump onto next dot/colon.
t( t]       jump before next closing parenthesis/bracket.
;           repeat latest f,F,t,T command in             latest used direction
,           repeat latest f,F,t,T command in opposite of latest used direction
searching with patterns and repetitions:
/pattern    search  forward for next match of "pattern"
?pattern    search backward for next match of "pattern"
:0/pattern
 *  #       search for the next/prev match of the current word
g* g#       search for the next/prev match of the current word with word 
boundary
n N         search again forward/backward for next match of last used pattern
window commands:
CTRL-W n    window new   -> open  a new   window
CTRL-W c    window close -> close current window
CTRL-W s    window split -> split current window
CTRL-W v    window split vertical -> vertically split current window
switching buffers/files:
:bn :bp     switch to next/prev buffer (by number)
:b #        switch to alternate/previous buffer
:b foo      switch to buffer name containing "foo" in dir or file
gf          switch to current filename ("under cursor")
jumping by text objects:
{ }         jump onto empty line before/after  current paragraph
( )         jump   to             begin/end of current sentence
copy+paste:
dip         delete inner paragraph
yip         copY   inner paragraph
using a number prefix for "repetitions":
6b          jump back by six words
3j          jump down by 3 lines
9k          jump   up by 9 lines
23}         jump over 23 paragraphs
42)         jump over 42 sentences
42G         jump onto line number 42
3H          jump onto 3rd line from Highest line
5L          jump onto 5th line from Lowest  line
using marks:
ma mb .. mz mark current line by letter 'a/b/../z'
'a 'b .. 'z jump onto first non-whitespace of marked line 'a/b/../z'
`a `b .. `z jump onto the exact character  of marked line 'a/b/../z'

-- 
-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to