Moving

  1. G and gg

    G let the cursor go to the last line, while gg let the cursor go the first line of the whole file.

  2. zz and z<enter>

    It is used to adjust view. Put the cursor at the line you want to scroll to the center: type: zz
    to the top: type: z<enter>

  3. ge

    It can move backward to the end character of each word.

  4. gd

    Find the local definition part of the variable or function at the current cursor. Use " or `` to jump back.

  5. gD

    Find the global definition part of the variable or function at the current cursor.

  6. ``

    Jump back to the character position where last absolute jump occurred

  7. ''

    Jump back to the start of the line where last absolute jump occurred

  8. Move across split windows: Ctrl-W related commands for split windows

  9. 0 and ^
    0 move the cursor to the first character of the line, while ^ move the cursor to the first

Tony Han 2011-06-16