= Planned Commands for levi = Implementation status: * (Buggy): Already implemented, but has some bugs. * (Partially): Partially implemented. * (Planned): Not implemented yet, but planned. * (Stalled): Tried to implement, but not functional yet. * (Out of Scope): Not planned to implement. Command categories: * Motion * Marking * View * Search * Character Finding * Insertion * Operator (Copy / Delte / Change) * Editing * Miscellaneous * Prompt == Motion Commands == === Move by Character / Move by Line === * h : Move cursor left by character. (MoveLeft) * j : Move cursor down by line. (MoveDown) * k : Move cursor up by line. (MoveUp) * l : Move cursor right by character. (MoveRight) === Move in Line === * 0 : Move cursor to start of current line. (MoveToStart) * $ : Move cursor to end of current line. (MoveToEnd) * ^ : Move cursor to first non-blank character of current line. (MoveToNonBlank) * | : Move cursor to column of current line. (MoveToColumn) (Note: Proper vi's column number is visual-based, but levi' is rune-based.) === Move by Word / Move by Loose Word === * w : Move cursor forward by word. (MoveByWord) * b : Move cursor backward by word. (MoveBackwardByWord) * e : Move cursor to end of word. (MoveToEndOfWord) * W : Move cursor forward by loose word. (MoveByLooseWord) * B : Move cursor backward by loose word. (MoveBackwardByLooseWord) * E : Move cursor to end of loose word. (MoveToEndOfLooseWord) === Move by Line === * Enter, + : Move cursor to first non-blank character of next line. (MoveToNonBlankOfNextLine) * - : Move cursor to first non-blank character of previous line. (MoveToNonBlankOfPrevLine) * G : Move cursor to last line. (MoveToLastLine) * G : Move cursor to line . (MoveToLine) === Move by Block === * ) : Move cursor forward by sentence. (MoveBySentence) * ( : Move cursor backward by sentence. (MoveBackwardBySentence) * } : Move cursor forward by paragraph. (MoveByParagraph) (Note: Proper vi respects nroff/troff directives, but levi doesn't.) * { : Move cursor backward by paragraph. (MoveBackwardByParagraph) (Note: Proper vi respects nroff/troff directives, but levi doesn't.) * ]] : Move cursor forward by section. (MoveBySection) (Note: Proper vi respects nroff/troff directives, but levi doesn't.) * [[ : Move cursor backward by section. (MoveBackwardBySection) (Note: Proper vi respects nroff/troff directives, but levi doesn't.) === Move in View === * H : Move cursor to top of view. (MoveToTopOfView) * M : Move cursor to middle of view. (MoveToMiddleOfView) * L : Move cursor to bottom of view. (MoveToBottomOfView) * H : Move cursor below lines from top of view. (MoveToBelowTopOfView) * L : Move cursor above lines from bottom of view. (MoveToAboveBottomOfView) == Marking Commands == === Set Mark / Move to Mark === * m : Mark current cursor position labelled by . (MarkSet) * ` : Move cursor to marked position labelled by . (MarkMoveTo) * ' : Move cursor to marked line labelled by . (MarkMoveToLine) === Move by Context === * `` : Move cursor to previous position in context. (MarkBack) * '' : Move cursor to previous line in context. (MarkBackToLine) == View Commands == === Scroll by View Height / Scroll by Line === * Ctrl-f : Scroll down by view height. (ViewDown) * Ctrl-b : Scroll up by view height. (ViewUp) * Ctrl-d : Scroll down by half view height. (ViewDownHalf) * Ctrl-u : Scroll up by half view height. (ViewUpHalf) * Ctrl-y : Scroll down by line. (ViewDownLine) * Ctrl-e : Scroll up by line. (ViewUpLine) === Reposition === * z Enter : Reposition cursor line to top of view. (ViewToTop) * z. : Reposition cursor line middle of view. (ViewToMiddle) * z- : Reposition cursor line bottom of view. (ViewToBottom) === Redraw === * Ctrl-l : Redraw view. (ViewRedraw) == Search Commands == * / Enter : Search forward. (SearchForward) * ? Enter : Search backward. (SearchBackward) * n : Search next match. (SearchNextMatch) * N : Search previous match. (SearchPrevMatch) * / Enter : Repeat last search forward. (SearchRepeatForward) * ? Enter : Repeat last search backward. (SearchRepeatBackward) == Character Finding Commands == * f : Find character forward in current line. (FindForward) * F : Find character backward in current line. (FindBackward) * t : Find before character forward in current line. (FindBeforeForward) * T : Find before character backward in current line. (FindBeforeBackward) * ; : Find next match. (FindNextMatch) * , : Find previous match. (FindPrevMatch) == Insertion Commands == === Enter Insert Mode === * i : Switch to insert mode before cursor. (InsertBefore) * a : Switch to insert mode after cursor. (InsertAfter) * I : Switch to insert mode before first non-blank character of current line. (InsertBeforeNonBlank) * A : Switch to insert mode after end of current line. (InsertAfterEnd) * R : Switch to replace (overwrite) mode. (InsertOverwrite) === Open Line === * o : Open a new line below and switch to insert mode. (InsertOpenBelow) * O : Open a new line above and switch to insert mode. (InsertOpenAbove) == Operator Commands (Copy / Delte / Change) == === Copy (Yank) === * yy, Y : Copy current line. (OpCopyLine) * y : Copy region from current cursor to destination of motion . (OpCopyRegion, OpCopyLineRegion) * yw : Copy word. (OpCopyWord) * y$ : Copy to end of current line. (OpCopyToEnd) * "yy : Copy current line into register . (OpCopyLineIntoReg) === Paste (Put) === * p : Paste after cursor. (OpPaste) * P : Paste before cursor. (OpPasteBefore) * "p : Paste from register . (OpPasteFromReg) === Delete === * x : Delete character under cursor. (OpDelete) * X : Delete character before cursor. (OpDeleteBefore) * dd : Delete current line. (OpDeleteLine) * d : Delete region from current cursor to destination of motion . (OpDeleteRegion, OpDeleteLineRegion) * dw : Delete word. (OpDeleteWord) * d$, D : Delete to end of current line. (OpDeleteToEnd) === Change / Substitute === * cc : Change current line. (OpChangeLine) * c : Change region from current cursor to destination of motion . (OpChangeRegion, OpChangeLineRegion) * cw : Change word. (OpChangeWord) * C : Change to end of current line. (OpChangeToEnd) * s : Substitute one character under cursor. (OpSubst) * S : Substtute current line (equals cc). (OpSubstLine) == Editing Commands == * r : Replace single character under cursor. (EditReplace) * J : Join current line with next line. (EditJoin) * >> : Indent current line. (EditIndent) * << : Outdent current line. (EditOutdent) * > : Indent region from current cursor to destination of motion . (EditIndentRegion) * < : Outdent region from current cursor to destination of motion . (EditOutdentRegion) == Miscellaneous Commands == * Ctrl-g : Show info such as current cursor position. (MiscShowInfo) * . : Repeat last edit. (MiscRepeat) * u : Undo. (MiscUndo) * U : Restore current line to previous state. (MiscRestore) * ZZ : Save and quit. (MiscSaveAndQuit) == Prompt Commands == === Move === * : Enter : Move cursor to line . (PromptMoveToLine) === File === * :wq Enter : Save current file and quit. (PromptSaveAndQuit) * :w Enter : Save current file. (PromptSave) * :w! Enter : Force save current file. (PromptForceSave) * :q Enter : Quit editor. (PromptQuit) * :q! Enter : Force quit editor. (PromptForceQuit) * :e Enter : Open file. (PromptOpen) * :e! Enter : Force open file. (PromptForceOpen) * :r Enter : Read file and insert to current buffer. (PromptRead) * :n Enter : Switch to next buffer (tab). (PromptNext) * :prev Enter : Switch to previous buffer (tab). (PromptPrev) (extension) === Utility === * :sh Enter : Execute shell. (PromptShell) (Note: Only Unix-like OSes are supported.) === From Vim === * :wa Enter : Save all files. (PromptSaveAll) * :qa Enter : Close all files and quit editor. (PromptQuitAll) * :qa! Enter : Force close all files and quit editor. (PromptForceQuitAll)