Port libnum, Make editor more Vi-like, refactor stuff.
Created by: ticki
libnum is now ported. The editor now has following commands:
- hjkl: Motion
- JK: Big horizontal motion (15).
- i: Go to insert mode
- d: Delete the rest of the line
- D: The rest of the line before the cursor
- 0: Go to the start of the line
- $: Go to the end of the line
- a: Insert text after the cursor
- o: Create a new line under the current one and go to insert mode.
- O: Same as
o
but instead above the current line. - x: Delete char after cursor.
- X: Delete char before cursor.
- d: Delete the rest of the line.
- c: Go to the other cursor.
- u: Undo (only one undo level, to redo: u)
- g: Go to the top
- G: Go to the bottom
- ,: Start/stop recording a period
- !: Play a period
- ^: Go to the first non blank char of the line.
- s: Remove the char under the cursor and start inserting.
- w: Save the file.
- e: Navigate to the end of the Vi-like word. Note: that the rules differ.
- b: Navigate to the start of the Vi-like word.
- E: Navigate to the end of the word seperated by spaces.
- B: Navigate to the start of the word seperated by spaces.
- %: Go to the matching delimiter.
- y: Yank the rest of the line.
- Y: Yank the rest of the line before the cursor.
- p: Paste the clipboard.
- z: Clip the rest of the line.
- Z: Clip the rest of the line before the cursor.