(defun vi-switch-mode (arg mode-char) "\
Switch the major mode of current buffer as specified by the following char \\{vi-tilde-map}" (interactive "P
c") (byte-code "ň	
!\"?Ȑ!!&\" !)" [mode-cmd vi-tilde-map mode-char prefix-arg arg nil lookup-key char-to-string "*Help*" princ substitute-command-keys "Possible major modes to switch to: \\{vi-tilde-map}" command-execute set-buffer-modified-p buffer-modified-p] 8))

(if (null (where-is-internal (quote vi-switch-mode) (current-local-map))) (define-key ctl-x-map "~" (quote vi-switch-mode)))

(defvar vi-tilde-map nil "\
Keymap used for \\[vi-switch-mode] prefix key.  Link to various major modes.")

(if vi-tilde-map nil (setq vi-tilde-map (make-keymap)) (define-key vi-tilde-map "a" (quote abbrev-mode)) (define-key vi-tilde-map "c" (quote c-mode)) (define-key vi-tilde-map "d" (quote vi-debugging)) (define-key vi-tilde-map "e" (quote emacs-lisp-mode)) (define-key vi-tilde-map "f" (quote auto-fill-mode)) (define-key vi-tilde-map "g" (quote prolog-mode)) (define-key vi-tilde-map "h" (quote hanoi)) (define-key vi-tilde-map "i" (quote info-mode)) (define-key vi-tilde-map "l" (quote lisp-mode)) (define-key vi-tilde-map "n" (quote nroff-mode)) (define-key vi-tilde-map "o" (quote overwrite-mode)) (define-key vi-tilde-map "O" (quote outline-mode)) (define-key vi-tilde-map "P" (quote picture-mode)) (define-key vi-tilde-map "r" (quote vi-readonly-mode)) (define-key vi-tilde-map "t" (quote text-mode)) (define-key vi-tilde-map "v" (quote vi-mode)) (define-key vi-tilde-map "x" (quote tex-mode)) (define-key vi-tilde-map "~" (quote vi-back-to-old-mode)))

(defun vi-debugging (arg) "\
Toggle debug-on-error flag.  If prefix arg is given, set t." (interactive "P") (byte-code "È‰	?	!!" [arg debug-on-error t nil message "Debug-on-error ..." "NO more debug-on-error"] 3))

(defun vi-back-to-old-mode nil "\
Go back to the previous mode without setting up for insertion." (interactive) (byte-code "Lj
! !" [vi-mode-old-major-mode mode-name vi-mode-old-mode-name vi-mode-old-local-map major-mode case-fold-search vi-mode-old-case-fold nil use-local-map set-buffer-modified-p buffer-modified-p] 4))

(defun vi-readonly-mode nil "\
Toggle current buffer's readonly flag." (interactive) (byte-code "?" [buffer-read-only nil] 2))

(defvar vi-com-map nil "\
Keymap used in Evi's command state
Command state includes most of the vi editing commands, with some Emacs
command extensions.")

(put (quote vi-undefined) (quote suppress-keymap) t)

(if vi-com-map nil (setq vi-com-map (make-keymap)) (define-key vi-com-map "" (quote vi-mark-region)) (define-key vi-com-map "" (quote vi-ask-for-info)) (define-key vi-com-map "" (quote vi-backward-windowfull)) (define-key vi-com-map "" (quote vi-do-old-mode-C-c-command)) (define-key vi-com-map "" (quote vi-scroll-down-window)) (define-key vi-com-map "" (quote vi-expose-line-below)) (define-key vi-com-map "" (quote vi-forward-windowfull)) (define-key vi-com-map "" (quote keyboard-quit)) (define-key vi-com-map "	" (quote indent-relative-maybe)) (define-key vi-com-map "
" (quote vi-next-line)) (define-key vi-com-map "" (quote vi-kill-line)) (define-key vi-com-map "" (quote recenter)) (define-key vi-com-map "
" (quote vi-next-line-first-nonwhite)) (define-key vi-com-map "" (quote vi-next-line)) (define-key vi-com-map "" (quote vi-split-open-line)) (define-key vi-com-map "" (quote previous-line)) (define-key vi-com-map "" (quote vi-query-replace)) (define-key vi-com-map "" (quote vi-isearch-backward)) (define-key vi-com-map "" (quote vi-isearch-forward)) (define-key vi-com-map "" (quote vi-transpose-objects)) (define-key vi-com-map "" (quote vi-scroll-up-window)) (define-key vi-com-map "" (quote scroll-up)) (define-key vi-com-map "" (quote vi-kill-region)) (define-key vi-com-map "" (quote Control-X-prefix)) (define-key vi-com-map "" (quote vi-expose-line-above)) (define-key vi-com-map "" (quote suspend-emacs)) (define-key vi-com-map "" (quote ESC-prefix)) (define-key vi-com-map "" (quote vi-unimplemented)) (define-key vi-com-map "" (quote find-tag)) (define-key vi-com-map "" (quote vi-locate-def)) (define-key vi-com-map "" (quote vi-undefined)) (define-key vi-com-map " " (quote forward-char)) (define-key vi-com-map "!" (quote vi-operator)) (define-key vi-com-map "\"" (quote vi-char-argument)) (define-key vi-com-map "#" (quote universal-argument)) (define-key vi-com-map "$" (quote end-of-line)) (define-key vi-com-map "%" (quote vi-find-matching-paren)) (define-key vi-com-map "&" (quote vi-unimplemented)) (define-key vi-com-map "'" (quote vi-goto-line-mark)) (define-key vi-com-map "(" (quote backward-sexp)) (define-key vi-com-map ")" (quote forward-sexp)) (define-key vi-com-map "*" (quote vi-name-last-change-or-macro)) (define-key vi-com-map "+" (quote vi-next-line-first-nonwhite)) (define-key vi-com-map "," (quote vi-reverse-last-find-char)) (define-key vi-com-map "-" (quote vi-previous-line-first-nonwhite)) (define-key vi-com-map "." (quote vi-redo-last-change-command)) (define-key vi-com-map "/" (quote vi-search-forward)) (define-key vi-com-map "0" (quote beginning-of-line)) (define-key vi-com-map "1" (quote vi-digit-argument)) (define-key vi-com-map "2" (quote vi-digit-argument)) (define-key vi-com-map "3" (quote vi-digit-argument)) (define-key vi-com-map "4" (quote vi-digit-argument)) (define-key vi-com-map "5" (quote vi-digit-argument)) (define-key vi-com-map "6" (quote vi-digit-argument)) (define-key vi-com-map "7" (quote vi-digit-argument)) (define-key vi-com-map "8" (quote vi-digit-argument)) (define-key vi-com-map "9" (quote vi-digit-argument)) (define-key vi-com-map ":" (quote vi-ex-cmd)) (define-key vi-com-map ";" (quote vi-repeat-last-find-char)) (define-key vi-com-map "<" (quote vi-operator)) (define-key vi-com-map "=" (quote vi-operator)) (define-key vi-com-map ">" (quote vi-operator)) (define-key vi-com-map "?" (quote vi-search-backward)) (define-key vi-com-map "@" (quote vi-call-named-change-or-macro)) (define-key vi-com-map "A" (quote vi-append-at-end-of-line)) (define-key vi-com-map "B" (quote vi-backward-blank-delimited-word)) (define-key vi-com-map "C" (quote vi-change-rest-of-line)) (define-key vi-com-map "D" (quote vi-kill-line)) (define-key vi-com-map "E" (quote vi-end-of-blank-delimited-word)) (define-key vi-com-map "F" (quote vi-backward-find-char)) (define-key vi-com-map "G" (quote vi-goto-line)) (define-key vi-com-map "H" (quote vi-home-window-line)) (define-key vi-com-map "I" (quote vi-insert-before-first-nonwhite)) (define-key vi-com-map "J" (quote vi-join-lines)) (define-key vi-com-map "K" (quote vi-undefined)) (define-key vi-com-map "L" (quote vi-last-window-line)) (define-key vi-com-map "M" (quote vi-middle-window-line)) (define-key vi-com-map "N" (quote vi-reverse-last-search)) (define-key vi-com-map "O" (quote vi-open-above)) (define-key vi-com-map "P" (quote vi-put-before)) (define-key vi-com-map "Q" (quote vi-quote-words)) (define-key vi-com-map "R" (quote vi-replace-chars)) (define-key vi-com-map "S" (quote vi-substitute-lines)) (define-key vi-com-map "T" (quote vi-backward-upto-char)) (define-key vi-com-map "U" (quote vi-unimplemented)) (define-key vi-com-map "V" (quote vi-undefined)) (define-key vi-com-map "W" (quote vi-forward-blank-delimited-word)) (define-key vi-com-map "X" (quote call-last-kbd-macro)) (define-key vi-com-map "Y" (quote vi-yank-line)) (define-key vi-com-map "Z" (make-sparse-keymap)) (define-key vi-com-map "ZZ" (quote vi-save-all-and-exit)) (define-key vi-com-map "[" (quote vi-unimplemented)) (define-key vi-com-map "\\" (quote vi-operator)) (define-key vi-com-map "]" (quote vi-unimplemented)) (define-key vi-com-map "^" (quote back-to-indentation)) (define-key vi-com-map "_" (quote vi-undefined)) (define-key vi-com-map "`" (quote vi-goto-char-mark)) (define-key vi-com-map "a" (quote vi-insert-after)) (define-key vi-com-map "b" (quote backward-word)) (define-key vi-com-map "c" (quote vi-operator)) (define-key vi-com-map "d" (quote vi-operator)) (define-key vi-com-map "e" (quote vi-end-of-word)) (define-key vi-com-map "f" (quote vi-forward-find-char)) (define-key vi-com-map "g" (quote vi-beginning-of-buffer)) (define-key vi-com-map "h" (quote backward-char)) (define-key vi-com-map "i" (quote vi-insert-before)) (define-key vi-com-map "j" (quote vi-next-line)) (define-key vi-com-map "k" (quote previous-line)) (define-key vi-com-map "l" (quote forward-char)) (define-key vi-com-map "m" (quote vi-set-mark)) (define-key vi-com-map "n" (quote vi-repeat-last-search)) (define-key vi-com-map "o" (quote vi-open-below)) (define-key vi-com-map "p" (quote vi-put-after)) (define-key vi-com-map "q" (quote vi-replace)) (define-key vi-com-map "r" (quote vi-replace-1-char)) (define-key vi-com-map "s" (quote vi-substitute-chars)) (define-key vi-com-map "t" (quote vi-forward-upto-char)) (define-key vi-com-map "u" (quote undo)) (define-key vi-com-map "v" (quote vi-verify-spelling)) (define-key vi-com-map "w" (quote vi-forward-word)) (define-key vi-com-map "x" (quote vi-kill-char)) (define-key vi-com-map "y" (quote vi-operator)) (define-key vi-com-map "z" (quote vi-adjust-window)) (define-key vi-com-map "{" (quote backward-paragraph)) (define-key vi-com-map "|" (quote vi-goto-column)) (define-key vi-com-map "}" (quote forward-paragraph)) (define-key vi-com-map "~" (quote vi-change-case)) (define-key vi-com-map "" (quote delete-backward-char)))

(put (quote backward-char) (quote point-moving-unit) (quote char))

(put (quote vi-next-line) (quote point-moving-unit) (quote line))

(put (quote next-line) (quote point-moving-unit) (quote line))

(put (quote forward-line) (quote point-moving-unit) (quote line))

(put (quote previous-line) (quote point-moving-unit) (quote line))

(put (quote vi-isearch-backward) (quote point-moving-unit) (quote search))

(put (quote vi-search-backward) (quote point-moving-unit) (quote search))

(put (quote vi-isearch-forward) (quote point-moving-unit) (quote search))

(put (quote vi-search-forward) (quote point-moving-unit) (quote search))

(put (quote forward-char) (quote point-moving-unit) (quote char))

(put (quote end-of-line) (quote point-moving-unit) (quote char))

(put (quote vi-find-matching-paren) (quote point-moving-unit) (quote match))

(put (quote vi-goto-line-mark) (quote point-moving-unit) (quote line))

(put (quote backward-sexp) (quote point-moving-unit) (quote sexp))

(put (quote forward-sexp) (quote point-moving-unit) (quote sexp))

(put (quote vi-next-line-first-nonwhite) (quote point-moving-unit) (quote line))

(put (quote vi-previous-line-first-nonwhite) (quote point-moving-unit) (quote line))

(put (quote vi-reverse-last-find-char) (quote point-moving-unit) (quote rev-find))

(put (quote vi-re-search-forward) (quote point-moving-unit) (quote search))

(put (quote beginning-of-line) (quote point-moving-unit) (quote char))

(put (quote vi-beginning-of-buffer) (quote point-moving-unit) (quote char))

(put (quote vi-repeat-last-find-char) (quote point-moving-unit) (quote find))

(put (quote vi-re-search-backward) (quote point-moving-unit) (quote search))

(put (quote vi-backward-blank-delimited-word) (quote point-moving-unit) (quote WORD))

(put (quote vi-end-of-blank-delimited-word) (quote point-moving-unit) (quote match))

(put (quote vi-backward-find-char) (quote point-moving-unit) (quote find))

(put (quote vi-goto-line) (quote point-moving-unit) (quote line))

(put (quote vi-home-window-line) (quote point-moving-unit) (quote line))

(put (quote vi-last-window-line) (quote point-moving-unit) (quote line))

(put (quote vi-middle-window-line) (quote point-moving-unit) (quote line))

(put (quote vi-reverse-last-search) (quote point-moving-unit) (quote rev-search))

(put (quote vi-backward-upto-char) (quote point-moving-unit) (quote find))

(put (quote vi-forward-blank-delimited-word) (quote point-moving-unit) (quote WORD))

(put (quote back-to-indentation) (quote point-moving-unit) (quote char))

(put (quote vi-goto-char-mark) (quote point-moving-unit) (quote char))

(put (quote backward-word) (quote point-moving-unit) (quote word))

(put (quote vi-end-of-word) (quote point-moving-unit) (quote match))

(put (quote vi-forward-find-char) (quote point-moving-unit) (quote find))

(put (quote backward-char) (quote point-moving-unit) (quote char))

(put (quote vi-forward-char) (quote point-moving-unit) (quote char))

(put (quote vi-repeat-last-search) (quote point-moving-unit) (quote search))

(put (quote vi-forward-upto-char) (quote point-moving-unit) (quote find))

(put (quote vi-forward-word) (quote point-moving-unit) (quote word))

(put (quote vi-goto-column) (quote point-moving-unit) (quote match))

(put (quote forward-paragraph) (quote point-moving-unit) (quote paragraph))

(put (quote backward-paragraph) (quote point-moving-unit) (quote paragraph))

(put (quote mark-page) (quote point-moving-unit) (quote region))

(put (quote mark-paragraph) (quote point-moving-unit) (quote region))

(put (quote mark-word) (quote point-moving-unit) (quote region))

(put (quote mark-sexp) (quote point-moving-unit) (quote region))

(put (quote mark-defun) (quote point-moving-unit) (quote region))

(put (quote mark-whole-buffer) (quote point-moving-unit) (quote region))

(put (quote mark-end-of-sentence) (quote point-moving-unit) (quote region))

(put (quote mark-c-function) (quote point-moving-unit) (quote region))

(defvar vi-mark-alist nil "\
Alist of (NAME . MARK), marks are local to each buffer.")

(defvar vi-scroll-amount (/ (window-height) 2) "\
Default amount of lines for scrolling (used by " ^D "/" ^U ").")

(defvar vi-shift-width 4 "\
Shift amount for " < "/" > " operators.")

(defvar vi-ins-point nil "\
Last insertion point.  Should use 'mark' instead.")

(defvar vi-ins-length nil "\
Length of last insertion.")

(defvar vi-ins-repetition nil "\
The repetition required for last insertion.")

(defvar vi-ins-overwrt-p nil "\
T if last insertion was a replace actually.")

(defvar vi-ins-prefix-code nil "\
Code to be eval'ed before (redo-)insertion begins.")

(defvar vi-last-find-char nil "\
Save last direction, char and upto-flag used for char finding.")

(defvar vi-last-change-command nil "\
Save commmands for redoing last changes.  Each command is in (FUNC . ARGS)
form that is ready to be 'apply'ed.")

(defvar vi-last-shell-command nil "\
Save last shell command given for \"!\" operator.")

(defvar vi-insert-state nil "\
T if it is in insert state.")

(defvar vi-search-last-command nil "\
Save last search command for possible redo.")

(defvar vi-mode-old-local-map nil "\
Save the local-map used before entering vi-mode.")

(defvar vi-mode-old-mode-name nil "\
Save the mode-name before entering vi-mode.")

(defvar vi-mode-old-major-mode nil "\
Save the major-mode before entering vi-mode.")

(defvar vi-mode-old-case-fold nil)

(defun vi-mode-setup nil "\
Setup a buffer for vi-mode by creating necessary buffer-local variables." (byte-code "! \"!Ɖ!!!!!!!!!!!!!!!" [vi-scroll-amount vi-shift-width make-local-variable / window-height 2 4 vi-ins-point vi-ins-length vi-ins-repetition vi-ins-overwrt-p vi-ins-prefix-code vi-last-change-command vi-last-shell-command vi-last-find-char vi-mark-alist vi-insert-state vi-mode-old-local-map vi-mode-old-mode-name vi-mode-old-major-mode vi-mode-old-case-fold run-hooks vi-mode-hook] 20))

(defun vi-mode nil "\
Major mode that acts like the `vi' editor.
The purpose of this mode is to provide you the combined power of vi (namely,
the \"cross product\" effect of commands and repeat last changes) and Emacs.

This command redefines nearly all keys to look like vi commands.
It records the previous major mode, and any vi command for input
(`i', `a', `s', etc.) switches back to that mode.
Thus, ordinary Emacs (in whatever major mode you had been using)
is \"input\" mode as far as vi is concerned.

To get back into vi from \"input\" mode, you must issue this command again.
Therefore, it is recommended that you assign it to a key.

Major differences between this mode and real vi :

* Limitations and unsupported features
  - Search patterns with line offset (e.g. /pat/+3 or /pat/z.) are
    not supported.
  - Ex commands are not implemented; try ':' to get some hints.
  - No line undo (i.e. the 'U' command), but multi-undo is a standard feature.

* Modifications
  - The stopping positions for some point motion commands (word boundary,
    pattern search) are slightly different from standard 'vi'.
    Also, no automatic wrap around at end of buffer for pattern searching.
  - Since changes are done in two steps (deletion then insertion), you need
    to undo twice to completely undo a change command.  But this is not needed
    for undoing a repeated change command.
  - No need to set/unset 'magic', to search for a string with regular expr
    in it just put a prefix arg for the search commands.  Replace cmds too.
  - ^R is bound to incremental backward search, so use ^L to redraw screen.

* Extensions
  - Some standard (or modified) Emacs commands were integrated, such as
    incremental search, query replace, transpose objects, and keyboard macros.
  - In command state, ^X links to the 'ctl-x-map', and ESC can be linked to
    esc-map or set undefined.  These can give you the full power of Emacs.
  - See vi-com-map for those keys that are extensions to standard vi, e.g.
    `vi-name-last-change-or-macro', `vi-verify-spelling', `vi-locate-def',
    `vi-mark-region', and 'vi-quote-words'.  Some of them are quite handy.
  - Use \\[vi-switch-mode] to switch among different modes quickly.
Syntax table and abbrevs while in vi mode remain as they were in Emacs." (interactive) (byte-code "Lj?	 	= \"H 	lj!ˉщ !	H " [vi-mode-old-major-mode major-mode vi-mode-old-local-map vi-mode-old-mode-name mode-name vi-mode-old-case-fold case-fold-search nil vi-com-map vi-insert-state vi-mode-setup vi-mode message "Already in vi-mode." ding current-local-map use-local-map "VI" set-buffer-modified-p buffer-modified-p vi-end-of-insert-state] 9))

(defun vi-ding nil "\
Ding !" (interactive) (byte-code " " [nil ding] 2))

(defun vi-save-all-and-exit nil "\
Save all modified buffers without asking, then exits emacs." (interactive) (byte-code "! " [t nil save-some-buffers kill-emacs] 3))

(defvar vi-replaced-string nil)

(defvar vi-replacing-string nil)

(defun vi-ex-cmd nil "\
Ex commands are not implemented in Evi mode.  For some commonly used ex
commands, you can use the following alternatives for similar effect :
w            C-x C-s (save-buffer)
wq           C-x C-c (save-buffers-kill-emacs)
w fname      C-x C-w (write-file)
e fname      C-x C-f (find-file)
r fname      C-x i   (insert-file)
s/old/new    use q (vi-replace) to do unconditional replace
             use C-q (vi-query-replace) to do query replace
set sw=n     M-x set-variable vi-shift-width n " (interactive) (byte-code "!!" [nil "*Help*" princ documentation vi-ex-cmd] 4))

(defun vi-undefined nil (interactive) (byte-code "!\" " [last-command-char nil message "Command key \"%s\" is undefined in Evi." single-key-description ding] 4))

(defun vi-unimplemented nil (interactive) (byte-code "!\" " [last-command-char nil message "Command key \"%s\" is not implemented in Evi." single-key-description ding] 4))

(defun vi-goto-insert-state (repetition &optional prefix-code do-it-now-p) "\
Go into insert state, the text entered will be repeated if REPETITION > 1.
If PREFIX-CODE is given, do it before insertion begins if DO-IT-NOW-P is T.
In any case, the prefix-code will be done before each 'redo-insert'.
This function expects 'overwrite-mode' being set properly beforehand." (byte-code "
	@	A\"`		
! !Ή
" [do-it-now-p prefix-code vi-ins-point vi-ins-repetition repetition vi-ins-prefix-code mode-name vi-mode-old-mode-name case-fold-search vi-mode-old-case-fold vi-mode-old-local-map major-mode vi-mode-old-major-mode vi-insert-state t apply use-local-map set-buffer-modified-p buffer-modified-p] 6))

(defun vi-end-of-insert-state nil "\
Terminate insertion and set up last change command." (byte-code "`W`U	?
V9c
	%!" [vi-ins-point vi-ins-prefix-code vi-ins-repetition t str overwrite-mode 0 vi-goto-command-state 1 buffer-substring vi-set-last-change-command vi-first-redo-insertion] 8))

(defun vi-first-redo-insertion (begin end &optional overwrite-p prefix-code) "\
Redo last insertion the first time.  Extract the string and save it for
future redoes.  Do prefix-code if it's given, use overwrite mode if asked." (byte-code "	
\"@A\"``G\\\"c$)" [str begin end prefix-code overwrite-p buffer-substring apply delete-region vi-set-last-change-command vi-more-redo-insertion] 8))

(defun vi-more-redo-insertion (str &optional overwrite-p prefix-code) "\
Redo more insertion : copy string from STR to point, use overwrite mode
if overwrite-p is T; apply prefix-code first if it's non-nil." (byte-code "
@A\"	``
c" [prefix-code overwrite-p str apply delete-region] 5))

(defun vi-goto-command-state (&optional from-insert-state-p) "\
Go to vi-mode command state.  If optional arg exists, means return from
insert state." (byte-code "!‰!" [vi-com-map vi-insert-state nil from-insert-state-p overwrite-mode use-local-map 0] 3))

(defun vi-kill-line (arg) "\
kill specified number of lines (=d$), text saved in the kill ring." (interactive "*P") (byte-code "!\"" [arg nil kill-line vi-set-last-change-command] 4))

(defun vi-kill-region nil (interactive) (byte-code " !" [nil kill-region vi-set-last-change-command] 3))

(defun vi-append-at-end-of-line (arg) "\
go to end of line and then go into vi insert state." (interactive "*p") (byte-code "ˆ#" [arg t nil vi-goto-insert-state (end-of-line)] 4))

(defun vi-change-rest-of-line (arg) "\
Change the rest of (ARG) lines (= c$ in vi)." (interactive "*P") (byte-code "ˆD#" [arg t nil vi-goto-insert-state 1 kill-line] 4))

(defun vi-insert-before-first-nonwhite (arg) "\
(= ^i in vi)" (interactive "*p") (byte-code "ˆ#" [arg t nil vi-goto-insert-state (back-to-indentation)] 4))

(defun vi-open-above (arg) "\
open new line(s) above current line and enter insert state." (interactive "*p") (byte-code "ˆD#" [arg t nil vi-goto-insert-state 1 (lambda (x) (byte-code " !" [x beginning-of-line open-line] 3))] 4))

(defun vi-open-below (arg) "\
open new line(s) and go into insert mode on the last line." (interactive "*p") (byte-code "ˆD#" [arg t nil vi-goto-insert-state 1 (lambda (x) (byte-code " !!" [x end-of-line open-line forward-line] 4))] 4))

(defun vi-insert-after (arg) "\
start vi insert state after cursor." (interactive "*p") (byte-code "ˆC#" [arg t nil vi-goto-insert-state (lambda nil (byte-code "l? " [forward-char] 2))] 4))

(defun vi-insert-before (arg) "\
enter insert state before the cursor." (interactive "*p") (byte-code "!" [arg nil vi-goto-insert-state] 2))

(defun vi-goto-line (arg) "\
Go to ARGth line." (interactive "P") (byte-code "!? !!" [arg nil vi-raw-numeric-prefix end-of-buffer goto-line vi-prefix-numeric-value] 5))

(defun vi-beginning-of-buffer nil "\
Move point to the beginning of current buffer." (interactive) (byte-code "eb" [nil] 1))

(defun vi-isearch-forward (arg) "\
Incremental search forward.  Use regexp version if ARG is non-nil." (interactive "P") (byte-code "È	
`UÂ'	$Ȃ%ɉ*" [scmd arg opoint nil vi-search-last-command isearch-forward-regexp isearch-forward call-interactively re-search-forward search-forward] 3))

(defun vi-isearch-backward (arg) "\
Incremental search backward.  Use regexp version if ARG is non-nil." (interactive "P") (byte-code "È	
`UÂ'	$Ȃ%ɉ*" [scmd arg opoint nil vi-search-last-command isearch-backward-regexp isearch-backward call-interactively re-search-backward search-backward] 3))

(defun vi-search-forward (arg string) "\
Nonincremental search forward. Use regexp version if ARG is non-nil." (interactive (byte-code "
\"D\"D" [current-prefix-arg t nil read-string "regexp/" "/"] 5)) (byte-code "ˆ
%" [current-prefix-arg t nil vi-search-last-command arg string search-last-string re-search-forward search-forward 0 funcall 1] 6))

(defun vi-search-backward (arg string) "\
Nonincremental search backward.  Use regexp version if ARG is non-nil." (interactive (byte-code "
\"D\"D" [current-prefix-arg t nil read-string "regexp?" "?"] 5)) (byte-code "ˆ
%" [current-prefix-arg t nil vi-search-last-command arg string search-last-string re-search-backward search-backward 0 funcall 1] 6))

(defun vi-repeat-last-search (arg &optional search-command search-string) "\
Repeat last search command.  If optional search-command/string are given,
use those instead of the ones saved." (interactive "p") (byte-code "Ĉ?
??! \"(

%" [search-command vi-search-last-command search-string search-last-string nil arg message "No last search command to repeat." ding funcall] 8))

(defun vi-reverse-last-search (arg &optional search-command search-string) "\
Redo last search command in reverse direction. If the optional search args
are given, use those instead of the ones saved." (interactive "p") (byte-code "Ĉ?
??! \"L=,˂G=6ʂG=@͂G=G

%" [search-command vi-search-last-command search-string search-last-string nil arg message "No last search command to repeat." ding funcall re-search-forward re-search-backward search-forward search-backward] 8))

(defun vi-join-lines (arg) "\
join ARG lines from current line (default 2), cleaning up white space." (interactive "P") (byte-code "È!?!'!
S\"" [arg t count nil vi-raw-numeric-prefix delete-indentation vi-prefix-numeric-value 2 vi-set-last-change-command vi-join-lines] 7))

(defun vi-backward-kill-line nil "\
kill the current line.  Only works in insert state." (interactive) (byte-code "?!!" [vi-insert-state nil beginning-of-line 1 kill-line] 3))

(defun vi-abort-ins nil "\
abort insert state, kill inserted text and go back to command state." (interactive) (byte-code "?`
`\"!" [vi-insert-state nil vi-ins-point t kill-region vi-goto-command-state] 3))

(defun vi-backward-windowfull (count) "\
Backward COUNT windowfulls. Default is one." (interactive "p") (byte-code "V!S" [count nil 0 scroll-down] 4))

(defun vi-scroll-down-window (count) "\
Scrolls down window COUNT lines.  If COUNT is nil (actually, non-integer),
scrolls default amount.  The given COUNT is remembered for future scrollings." (interactive "P") (byte-code "ˆ!	!" [count vi-scroll-amount nil integerp scroll-up] 3))

(defun vi-expose-line-below (count) "\
Expose COUNT more lines below the current window.  Default COUNT is 1." (interactive "p") (byte-code "!" [count nil scroll-up] 2))

(defun vi-forward-windowfull (count) "\
Forward COUNT windowfulls. Default is one." (interactive "p") (byte-code "V!S" [count nil 0 scroll-up] 4))

(defun vi-next-line (count) "\
Go down count lines, try to keep at the same column." (interactive "p") (byte-code "Èĉ`	!`U ĉ" [this-command count last-command nil next-line next-line-internal ding] 4))

(defun vi-next-line-first-nonwhite (count) "\
Go down COUNT lines.  Stop at first non-white." (interactive "p") (byte-code "`! `U " [count nil forward-line back-to-indentation ding] 4))

(defun vi-previous-line-first-nonwhite (count) "\
Go up COUNT lines.  Stop at first non-white." (interactive "p") (byte-code "! " [count nil previous-line back-to-indentation] 3))

(defun vi-scroll-up-window (count) "\
Scrolls up window COUNT lines.  If COUNT is nil (actually, non-integer),
scrolls default amount.  The given COUNT is remembered for future scrollings." (interactive "P") (byte-code "ˆ!	!" [count vi-scroll-amount nil integerp scroll-down] 3))

(defun vi-expose-line-above (count) "\
Expose COUNT more lines above the current window.  Default COUNT is 1." (interactive "p") (byte-code "!" [count nil scroll-down] 2))

(defun vi-char-argument (arg) "\
Get following character (could be any CHAR) as part of the prefix argument.
Possible perfix-arg cases are NIL, INTEGER, (NIL . CHAR) or (INTEGER . CHAR)." (interactive "P") (byte-code "Èr	?B%	!	B%	@B)" [char arg prefix-arg nil t integerp] 3))

(defun vi-goto-mark (mark-char &optional line-flag) "\
Go to marked position or line (if line-flag is given). Goto mark '@' means
jump into and pop the top mark on the mark ring." (byte-code "	\" 
$ F!?8 \"E!b
E )" [mark-char last-command-char line-flag t mark nil char-equal exchange-point-and-mark back-to-indentation 64 set-mark-command vi-get-mark message "Mark register undefined." vi-ding] 12))

(defun vi-goto-line-mark (char) "\
Go to the line (at first non-white) marked by next char." (interactive "c") (byte-code "ˆ\"" [char t nil vi-goto-mark] 3))

(defun vi-goto-char-mark (char) "\
Go to the char position marked by next mark-char." (interactive "c") (byte-code "!" [char nil vi-goto-mark] 2))

(defun vi-digit-argument (arg) "\
Set numeric prefix argument." (interactive "P") (byte-code "?
!8! !
@?0ǂ2@\"AB" [arg nil prefix-arg t digit-argument integerp * 1] 8))

(defun vi-raw-numeric-prefix (arg) "\
Return the raw value of numeric part prefix argument." (byte-code ":
@" [arg] 1))

(defun vi-prefix-numeric-value (arg) "\
Return numeric meaning of the raw prefix argument.  This is a modification
to the standard one provided in `callint.c' to handle (_ . CHAR) cases." (byte-code "?	#!#:#@\"@#" [arg 1 integerp] 2))

(defun vi-reverse-last-find-char (count &optional find-arg) "\
Reverse last f F t T operation COUNT times.  If the optional FIND-ARG
is given, it is used instead of the saved one." (interactive "p") (byte-code "È?
	? \"#@\"AB
\"" [find-arg vi-last-find-char count nil message "No last find char to repeat." ding vi-find-char * -1] 6))

(defun vi-find-char (arg count) "\
Find in DIRECTION (1/-1) for CHAR of COUNT'th times on current line.
If UPTO-FLAG is T, stop before the char. ARG = (DIRECTION.CHAR.UPTO-FLAG." (byte-code "	@	A@	AA`\\ƍb ," [direction arg char upto-flag pos exit-find-char (byte-code "O	f?\"D	f\" \"D	f\"DSUD
B	ZC	\"	\\" [t pos nil char count upto-flag direction throw exit-find-char char-equal 10 0] 9) ding] 2))

(defun vi-repeat-last-find-char (count &optional find-arg) "\
Repeat last f F t T operation COUNT times.  If optional FIND-ARG is given,
it is used instead of the saved one." (interactive "p") (byte-code "È?
	? \"
\"" [find-arg vi-last-find-char count nil message "No last find char to repeat." ding vi-find-char] 5))

(defun vi-backward-find-char (count char) "\
Find the COUNT'th CHAR backward on current line." (interactive "p
c") (byte-code "ˆ	BB!" [vi-last-find-char char nil count -1 vi-repeat-last-find-char] 3))

(defun vi-forward-find-char (count char) "\
Find the COUNT'th CHAR forward on current line." (interactive "p
c") (byte-code "ˆ	BB!" [vi-last-find-char char nil count 1 vi-repeat-last-find-char] 3))

(defun vi-backward-upto-char (count char) "\
Find upto the COUNT'th CHAR backward on current line." (interactive "p
c") (byte-code "Ĉ	BB!" [vi-last-find-char char t count nil -1 vi-repeat-last-find-char] 3))

(defun vi-forward-upto-char (count char) "\
Find upto the COUNT'th CHAR forward on current line." (interactive "p
c") (byte-code "Ĉ	BB!" [vi-last-find-char char t count nil 1 vi-repeat-last-find-char] 3))

(defun vi-end-of-word (count) "\
Move forward until encountering the end of a word.
With argument, do this that many times." (interactive "p") (byte-code "m?	 
$ " [nil t count forward-char re-search-forward "\\W*\\w+\\>" backward-char] 6))

(defun vi-replace-1-char (count char) "\
Replace char after point by CHAR.  Repeat COUNT times." (interactive "p
c") (byte-code "\"!#" [count nil last-command-char char delete-char self-insert-command vi-set-last-change-command vi-replace-1-char] 6))

(defun vi-replace-chars (arg) "\
Replace chars over old ones." (interactive "*p") (byte-code "!!" [arg nil overwrite-mode 1 vi-goto-insert-state] 3))

(defun vi-substitute-chars (count) "\
Substitute COUNT chars by the input chars, enter insert state." (interactive "*p") (byte-code "ˆD#" [count t nil vi-goto-insert-state 1 (lambda (c) (byte-code "``\\\"" [c delete-region] 4))] 4))

(defun vi-substitute-lines (count) "\
Substitute COUNT lines by the input chars. (=cc in vi)" (interactive "*p") (byte-code "ˆSE#" [count t nil vi-goto-insert-state 1 vi-delete-op next-line] 5))

(defun vi-prefix-char-value (arg) "\
Get the char part of the current prefix argument." (byte-code "?	!:A" [arg nil t integerp] 2))

(defun vi-operator (arg) "\
Handling vi operators (d/c/</>/!/=/y).  Current implementation requires
the key bindings of the operators being fixed." (interactive "P") (byte-code "" [nil vi-exit-op (byte-code "	r	!\"
!r	!\"	\"C!S!B#H
#)" [this-op-char last-command-char this-command vi-com-map prefix-arg arg t lookup-key char-to-string vi-digit-argument char-equal vi-execute-op next-line vi-prefix-numeric-value vi-prefix-char-value] 13)] 2))

(defun vi-execute-op (op-char motion-command arg) "\
Execute vi edit operator as specified by OP-CHAR, the operand is the region
determined by the MOTION-COMMAND with ARG." (byte-code "U	
\"	!
\".	!
\"E	!
\"]	!

[#x	!


#	!

\"	!
\"" [op-char motion-command arg nil vi-last-shell-command vi-shift-width 100 vi-delete-op vi-set-last-change-command vi-repeat-command-of 99 vi-goto-insert-state 1 121 vi-yank-op 33 vi-shell-op 60 vi-shift-op 62 61 vi-indent-op 92 vi-narrow-op] 24))

(defun vi-repeat-command-of (command) "\
Return the command for redo the given command." (byte-code "	N=ł=ǂ	)" [cmd-type command t point-moving-unit search vi-repeat-last-search find vi-repeat-last-find-char] 2))

(defun vi-effective-range (motion-command arg) "\
Return (begin . end) of the range spanned by executing the given
   MOTION-COMMAND in ready-to-eval list form is not yet supported." (byte-code "`N`\"`

B=: 8``XG`N`=X=b	T=b `	b! `	dVd	B,)" [begin end opoint moving-unit motion-command prefix-arg arg nil point-moving-unit command-execute line region mark match find beginning-of-line next-line 1] 7))

(defun vi-delete-op (motion-command arg) "\
Delete range specified by MOTION-COMMAND with ARG." (byte-code "	
\"@AUƂH
?)\"F
!$F
$," [range motion-command arg begin end reg nil t vi-effective-range vi-prefix-char-value kill-region 65 90 append-to-register downcase copy-to-register] 10))

(defun vi-yank-op (motion-command arg) "\
Yank (in vi sense) range specified by MOTION-COMMAND with ARG." (byte-code "	
\"@AUƂH
?)\"F
!$F
$," [range motion-command arg begin end reg nil t vi-effective-range vi-prefix-char-value copy-region-as-kill 65 90 append-to-register downcase copy-to-register] 10))

(defun vi-yank-line (arg) "\
Yank (in vi sense) lines (= `yy' command)." (interactive "*P") (byte-code "!S!B\"#" [arg nil vi-prefix-numeric-value vi-prefix-char-value vi-yank-op next-line vi-set-last-change-command] 7))

(defun vi-string-end-with-nl-p (string) "\
See if STRING ends with a newline char.  Used in checking whether the yanked
text should be put back as lines or not." (byte-code "GSHU" [string 10] 2))

(defun vi-put-before (arg &optional after-p) "\
Put yanked (in vi sense) text back before/above cursor.  If a numeric prefix
value (currently it should be >1) is given, put back text as lines.
If the optional after-p is given, put after/below the cursor." (interactive "P") (byte-code "Ȉ	!WV!?&\"?.ʉY8XVGω#GZ\\\"8)g!;c!g\"
!~!  !`!
c 	#*" [reg arg put-text ring-length kill-ring this-command kill-ring-yank-pointer after-p nil vi-prefix-char-value 49 57 get-register error "Nothing in register %c" yank % - 48 1 "Register %c is not containing text string" vi-string-end-with-nl-p next-line beginning-of-line forward-char push-mark exchange-point-and-mark vi-set-last-change-command vi-put-before] 19))

(defun vi-put-after (arg) "\
Put yanked (in vi sense) text back after/below cursor." (interactive "P") (byte-code "ˆ\"" [arg t nil vi-put-before] 3))

(defun vi-shell-op (motion-command arg &optional shell-command) "\
Perform shell command (as filter) on range specified by MOTION-COMMAND
with ARG. If SHELL-COMMAND is not given, ask for one from minibuffer.
If char argument is given, it directs the output to a *temp* buffer." (byte-code "	
\"@AUł5?(\"
!?$+" [range motion-command arg begin end nil shell-command vi-last-shell-command t vi-effective-range read-string "!" shell-command-on-region vi-prefix-char-value] 8))

(defun vi-shift-op (motion-command arg amount) "\
Perform shift command on range specified by MOTION-COMMAND with ARG for
AMOUNT on each line.  Negative amount means shift left.
SPECIAL FEATURE: char argument can be used to specify shift amount(1-9)." (byte-code "	
\"@AUł;
!Z#+" [range motion-command arg begin end nil amount t vi-effective-range vi-prefix-char-value 0 48 indent-rigidly] 8))

(defun vi-indent-op (motion-command arg) "\
Perform indent command on range specified by MOTION-COMMAND with ARG." (byte-code "	
\"@AUł#+" [range motion-command arg begin end nil t vi-effective-range indent-region] 5))

(defun vi-narrow-op (motion-command arg) "\
Narrow to region specified by MOTION-COMMAND with ARG." (byte-code "	
\"@AUƂ\"," [range motion-command arg begin end reg nil vi-effective-range narrow-to-region] 4))

(defun vi-get-mark (char) "\
Return contents of vi mark register named CHAR, or nil if undefined." (byte-code "	\"A" [char vi-mark-alist assq] 3))

(defun vi-set-mark (char) "\
Set contents of vi mark register named CHAR to current point. '@' is the
special anonymous mark register." (interactive "c") (byte-code "\"!.\"
B)" [char nil aelt vi-mark-alist char-equal 64 set-mark-command assq move-marker copy-marker] 7))

(defun vi-find-matching-paren nil "\
Locate the matching paren.  It's a hack right now." (interactive) (byte-code "!!!$!\"!!$ " [t nil looking-at "[[({]" forward-sexp 1 backward-char "[])}]" forward-char backward-sexp ding] 8))

(defun vi-backward-blank-delimited-word (count) "\
Backward COUNT blank-delimited words." (interactive "p") (byte-code "
$o?!" [nil t count re-search-backward "[ 	
`]+" forward-char 1] 5))

(defun vi-forward-blank-delimited-word (count) "\
Forward COUNT blank-delimited words." (interactive "p") (byte-code "
$m?!" [nil t count re-search-forward "[^ 	
]" backward-char 1] 5))

(defun vi-end-of-blank-delimited-word (count) "\
Forward to the end of the COUNT'th blank-delimited word." (interactive "p") (byte-code "
$m?!" [nil t count re-search-forward "[^ 	
']" backward-char 2] 5))

(defun vi-home-window-line (arg) "\
To window home or arg'th line from the top of the window." (interactive "p") (byte-code "S! " [arg nil move-to-window-line back-to-indentation] 3))

(defun vi-last-window-line (arg) "\
To window last line or arg'th line from the bottom of the window." (interactive "p") (byte-code "[! " [arg nil move-to-window-line back-to-indentation] 3))

(defun vi-middle-window-line nil "\
To the middle line of the window." (interactive) (byte-code "! " [nil move-to-window-line back-to-indentation] 3))

(defun vi-forward-word (count) "\
Stop at the beginning of the COUNT'th words from point." (interactive "p") (byte-code "
$ " [nil t count re-search-forward "\\w*\\W+\\<" vi-ding] 5))

(defun vi-set-last-change-command (fun &rest args) "\
Set (FUN . ARGS) as the last-change-command." (byte-code "	
B" [vi-last-change-command fun args] 2))

(defun vi-redo-last-change-command (count &optional command) "\
Redo last change command COUNT times.  If the optional COMMAND is given,
it is used instead of the current last-change-command." (interactive "p") (byte-code "È?
S" [command vi-last-change-command count nil message "No last change command available." 0 apply] 5))

(defun vi-kill-char (count) "\
Kill COUNT chars from current point." (interactive "*p") (byte-code "ˆ\"#" [count t nil delete-char vi-set-last-change-command] 5))

(defun vi-transpose-objects (arg unit) "\
Transpose objects, the following char specifies unit of objects to be
transposed -- \"c\" for chars, \"l\" for lines, \"w\" for words, \"s\" for
 sexp, \"p\" for paragraph.
For the use of the prefix-arg, refer to individual functions called." (interactive "*P
c") (byte-code "È\"!r	#\"$	!d\"3	!!d\"B	!!d\"Q	!!d\"`	!!d	\"" [unit arg t nil char-equal 63 message "Transpose: c(har), l(ine), p(aragraph), s(-exp), w(ord)," vi-set-last-change-command vi-transpose-objects 99 transpose-chars 108 transpose-lines vi-prefix-numeric-value 112 transpose-paragraphs 115 transpose-sexps 119 transpose-words] 20))

(defun vi-query-replace (arg) "\
Query replace, use regexp version if ARG is non-nil." (interactive "*P") (byte-code "ˆ	
Â\")" [rcmd arg nil query-replace-regexp query-replace call-interactively] 3))

(defun vi-replace (arg) "\
Replace strings, use regexp version if ARG is non-nil." (interactive "*P") (byte-code "ˆ	
Â\")" [rcmd arg nil replace-regexp replace-string call-interactively] 3))

(defun vi-adjust-window (arg position) "\
Move current line to the top/center/bottom of the window." (interactive "p
c") (byte-code "È\"!9\"!9\"- \"!9!r
\"" [position t arg nil char-equal 13 recenter 0 45 -1 46 / window-height 2 message "Move current line to: \\r(top) -(bottom) .(middle)" vi-adjust-window] 12))

(defun vi-goto-column (col) "\
Go to given column of the current line." (interactive "p") (byte-code "È` 	V#lƉ!	S	U.‚3b )" [opoint col t nil beginning-of-line 1 0 forward-char ding] 5))

(defun vi-name-last-change-or-macro (arg char) "\
Give name to the last change command or just defined kbd macro.  If prefix
ARG is given, name last macro, otherwise name last change command.  The
following CHAR will be the name for the command or macro." (interactive "P
c") (byte-code "Lj	!!!<
$,	!!
M" [arg char vi-last-change-command args str overwrite-p prefix-code nil name-last-kbd-macro intern char-to-string vi-first-redo-insertion buffer-substring 0 1 2 3 vi-set-last-change-command vi-more-redo-insertion] 9))

(defun vi-call-named-change-or-macro (count char) "\
Execute COUNT times the keyboard macro definition named by the following CHAR." (interactive "p
c") (byte-code "ˆ!!K;!!	\" 	!!K\"" [char count nil intern char-to-string execute-kbd-macro vi-redo-last-change-command] 10))

(defun vi-change-case (arg) "\
Change the case of the char after point." (interactive "*p") (byte-code "" [nil exit (byte-code "!``\\\"%!``\\\"% \"\"!" [arg nil looking-at "[a-z]" upcase-region "[A-Z]" downcase-region ding throw exit vi-set-last-change-command vi-change-case forward-char] 9)] 2))

(defun vi-ask-for-info (char) "\
Inquire status info. The next CHAR will specify the particular info requested." (interactive "c") (byte-code "ˆ\" 1\" 1\"& 1!r!" [char t nil char-equal 108 what-line 99 what-cursor-position 112 what-page message "Ask for: l(ine number), c(ursor position), p(age number)" vi-ask-for-info] 9))

(defun vi-mark-region (arg region) "\
Mark region approriately.  The next char REGION is d(efun),s(-exp),b(uffer),
p(aragraph), P(age), f(unction in C/Pascal etc.), w(ord), e(nd of sentence),
l(ines)." (interactive "p
c") (byte-code "È\"	!\"	!\"( \"5	!\"B	!\"O	!\"\\	!\"i	!\"v	!!r	\"" [region arg t nil char-equal 100 mark-defun 115 mark-sexp 98 mark-whole-buffer 112 mark-paragraph 80 mark-page 102 mark-c-function 119 mark-word 101 mark-end-of-sentence 108 vi-mark-lines message "Mark: d(efun),s(-exp),b(uf),p(arag),P(age),f(unct),w(ord),e(os),l(ines)" vi-mark-region] 22))

(defun vi-mark-lines (num) "\
Mark NUM of lines from current line as current region." (byte-code "! !" [num beginning-of-line 1 push-mark end-of-line] 4))

(defun vi-verify-spelling (arg unit) "\
Verify spelling for the objects specified by char UNIT : [b(uffer),
r(egion), s(tring), w(ord) ]." (interactive "P
c") (byte-code "Ĉ	
\" !F
\"" [prefix-arg arg unit t nil char-equal 98 call-interactively spell-buffer 114 spell-region 115 spell-string 119 spell-word message "Spell check: b(uffer), r(egion), s(tring), w(ord)" vi-verify-spelling] 12))

(defun vi-do-old-mode-C-c-command (arg) "\
This is a hack for accessing mode specific C-c commands in vi-mode." (interactive "P") (byte-code "Ĉ	r!P\"ɍ \")" [cmd vi-mode-old-local-map prefix-arg arg nil lookup-key "" char-to-string exit-vi-mode (byte-code "? 
\")" [cmd nil case-fold-search vi-mode-old-case-fold prefix-arg arg ding command-execute] 4) vi-back-to-old-mode command-execute] 6))

(defun vi-quote-words (arg char) "\
Quote ARG words from the word point is on with the pattern specified by the
CHAR. Currently, CHAR could be [,{,(,\",',`,<,*, etc." (interactive "*p
c") (byte-code "ˆ!\"?!r	#!?(!c\"9Љj\"F҉j\"Sԉj\"`։j\"j؉	!!c" [char arg nil string-match "[[({<\"'`*]" char-to-string message "Enter any of [,{,(,<,\",',`,* as quoting character." vi-set-last-change-command vi-quote-words looking-at "\\<" forward-word -1 char-equal 91 93 123 125 60 62 40 41 96 39 vi-end-of-word forward-char 1] 14))

(defun vi-locate-def nil "\
Locate definition in current file for the name before the point. It assumes
a `(def..' always starts at the beginning of a line." (interactive) (byte-code "!!`! !`\")!ebP#5? #!)" [name nil t buffer-substring vi-backward-blank-delimited-word 1 skip-chars-forward "^a-zA-Z" vi-end-of-blank-delimited-word forward-char skip-chars-backward set-mark-command re-search-forward "^(def[unvarconst ]*" message "No definition for \"%s\" in current file." ding] 13))

(defun vi-split-open-line (arg) "\
Insert a newline and leave point before it.
With arg, inserts that many newlines." (interactive "*p") (byte-code "ˆD#" [arg t nil vi-goto-insert-state 1 (lambda (arg) (byte-code "no?!	V)c

c)	S1!)" [flag arg fill-prefix forward-char -1 0 10 1] 4))] 4))