Commit 1e70790f authored by Michael Kifer's avatar Michael Kifer
Browse files

new version

parent 99358b97
......@@ -243,6 +243,7 @@
(autoload 'ediff-buffers3 "ediff" "Compare three bufers" t)
(autoload 'ebuffers3 "ediff" "Compare three bufers" t)
(autoload 'erevision "ediff" "Compare versions of a file" t)
(autoload 'ediff-revision "ediff" "Compare versions of a file" t)
;; compare regions and windows
......@@ -317,6 +318,10 @@
"ediff-mult"
"Display the registry of active Ediff sessions."
t)
(autoload 'eregistry
"ediff-mult"
"Display the registry of active Ediff sessions."
t)
(autoload 'ediff-documentation
"ediff"
"Display Ediff's manual."
......
......@@ -328,53 +328,79 @@ that Ediff doesn't know about.")
;; Hook variables
(defvar ediff-before-setup-windows-hook nil
(defcustom ediff-before-setup-windows-hook nil
"*Hooks to run before Ediff sets its window configuration.
This can be used to save the previous window config, which can be restored
on ediff-quit or ediff-suspend.")
(defvar ediff-after-setup-windows-hook nil
on ediff-quit or ediff-suspend."
:type 'hook
:group 'ediff)
(defcustom ediff-after-setup-windows-hook nil
"*Hooks to run after Ediff sets its window configuration.
This can be used to set up control window or icon in a desired place.")
(defvar ediff-before-setup-control-frame-hook nil
This can be used to set up control window or icon in a desired place."
:type 'hook
:group 'ediff)
(defcustom ediff-before-setup-control-frame-hook nil
"*Hooks run before setting up the frame to display Ediff Control Panel.
Can be used to change control frame parameters to position it where it
is desirable.")
(defvar ediff-after-setup-control-frame-hook nil
is desirable."
:type 'hook
:group 'ediff)
(defcustom ediff-after-setup-control-frame-hook nil
"*Hooks run after setting up the frame to display Ediff Control Panel.
Can be used to move the frame where it is desired.")
(defvar ediff-startup-hook nil
"*Hooks to run in the control buffer after Ediff has been set up.")
(defvar ediff-select-hook nil
"*Hooks to run after a difference has been selected.")
(defvar ediff-unselect-hook nil
"*Hooks to run after a difference has been unselected.")
(defvar ediff-prepare-buffer-hook nil
"*Hooks called after buffers A, B, and C are set up.")
(defvar ediff-load-hook nil
"*Hook run after Ediff is loaded. Can be used to change defaults.")
Can be used to move the frame where it is desired."
:type 'hook
:group 'ediff)
(defcustom ediff-startup-hook nil
"*Hooks to run in the control buffer after Ediff has been set up."
:type 'hook
:group 'ediff)
(defcustom ediff-select-hook nil
"*Hooks to run after a difference has been selected."
:type 'hook
:group 'ediff)
(defcustom ediff-unselect-hook nil
"*Hooks to run after a difference has been unselected."
:type 'hook
:group 'ediff)
(defcustom ediff-prepare-buffer-hook nil
"*Hooks called after buffers A, B, and C are set up."
:type 'hook
:group 'ediff)
(defcustom ediff-load-hook nil
"*Hook run after Ediff is loaded. Can be used to change defaults."
:type 'hook
:group 'ediff)
(defvar ediff-mode-hook nil
(defcustom ediff-mode-hook nil
"*Hook run just after ediff-mode is set up in the control buffer.
This is done before any windows or frames are created. One can use it to
set local variables that determine how the display looks like.")
(defvar ediff-keymap-setup-hook nil
"*Hook run just after the default bindings in Ediff keymap are set up.")
set local variables that determine how the display looks like."
:type 'hook
:group 'ediff)
(defcustom ediff-keymap-setup-hook nil
"*Hook run just after the default bindings in Ediff keymap are set up."
:type 'hook
:group 'ediff)
(defvar ediff-display-help-hook nil
"*Hooks run after preparing the help message.")
(defvar ediff-suspend-hook (list 'ediff-default-suspend-function)
"*Hooks to run in the Ediff control buffer when Ediff is suspended.")
(defvar ediff-quit-hook (list 'ediff-cleanup-mess)
"*Hooks to run in the Ediff control buffer after finishing Ediff.")
(defvar ediff-cleanup-hook nil
(defcustom ediff-display-help-hook nil
"*Hooks run after preparing the help message."
:type 'hook
:group 'ediff)
(defcustom ediff-suspend-hook (list 'ediff-default-suspend-function)
"*Hooks to run in the Ediff control buffer when Ediff is suspended."
:type 'hook
:group 'ediff)
(defcustom ediff-quit-hook (list 'ediff-cleanup-mess)
"*Hooks to run in the Ediff control buffer after finishing Ediff."
:type 'hook
:group 'ediff)
(defcustom ediff-cleanup-hook nil
"*Hooks to run on exiting Ediff but before killing the control buffer.
This is a place to do various cleanups, such as deleting the variant buffers.
Ediff provides a function, `ediff-janitor', as one such possible hook.")
(defvar ediff-quit-merge-hook 'ediff-maybe-save-and-delete-merge
"*Hooks to run before quitting a merge job.
The most common use is to save and delete the merge buffer.")
Ediff provides a function, `ediff-janitor', as one such possible hook."
:type 'hook
:group 'ediff)
;; Error messages
(defconst ediff-KILLED-VITAL-BUFFER
......@@ -430,29 +456,39 @@ See the documentation string of `ediff-focus-on-regexp-matches' for details.")
(ediff-defvar-local ediff-hide-regexp-connective 'and "")
;; Copying difference regions between buffers.
(ediff-defvar-local ediff-killed-diffs-alist nil
"A list of killed diffs.
A diff is saved here if it is replaced by a diff
from another buffer. This alist has the form:
\((num (buff-object . diff) (buff-object . diff) (buff-object . diff)) ...),
where some buffer-objects may be missing.")
;;; Copying difference regions between buffers.
;; A list of killed diffs.
;; A diff is saved here if it is replaced by a diff
;; from another buffer. This alist has the form:
;; \((num (buff-object . diff) (buff-object . diff) (buff-object . diff)) ...),
;; where some buffer-objects may be missing.
(ediff-defvar-local ediff-killed-diffs-alist nil "")
;; Highlighting
;;(defvar ediff-before-flag-bol (if ediff-emacs-p "->>\n" (make-glyph "->>\n"))
(defvar ediff-before-flag-bol (if ediff-xemacs-p (make-glyph "->>") "->>")
"*Flag placed above the highlighted block of differences.
Must end with newline.")
;;(defvar ediff-after-flag-eol (if ediff-emacs-p "<<-\n" (make-glyph "<<-"))
(defvar ediff-after-flag-eol (if ediff-xemacs-p (make-glyph "<<-") "<<-")
"*Flag placed below the highlighted block of differences.
Must end with newline.")
(defvar ediff-before-flag-mol (if ediff-xemacs-p (make-glyph "->>") "->>")
"*Like ediff-before-flag, used when a difference starts in mid-line.")
(defvar ediff-after-flag-mol (if ediff-xemacs-p (make-glyph "<<-") "<<-")
"*Like ediff-after-flag, used when a difference starts in mid-line.")
(defcustom ediff-before-flag-bol (if ediff-xemacs-p (make-glyph "->>") "->>")
"*Flag placed before a highlighted block of differences, if block starts at beginning of a line."
:type 'string
:tag "Region before-flag at beginning of line"
:group 'ediff)
(defcustom ediff-after-flag-eol (if ediff-xemacs-p (make-glyph "<<-") "<<-")
"*Flag placed after a highlighted block of differences, if block ends at end of a line."
:type 'string
:tag "Region after-flag at end of line"
:group 'ediff)
(defcustom ediff-before-flag-mol (if ediff-xemacs-p (make-glyph "->>") "->>")
"*Flag placed before a highlighted block of differences, if block starts in mid-line."
:type 'string
:tag "Region before-flag in the middle of line"
:group 'ediff)
(defcustom ediff-after-flag-mol (if ediff-xemacs-p (make-glyph "<<-") "<<-")
"*Flag placed after a highlighted block of differences, if block ends in mid-line."
:type 'string
:tag "Region after-flag in the middle of line"
:group 'ediff)
(ediff-defvar-local ediff-use-faces t
......@@ -490,11 +526,13 @@ Use `setq-default' if setting it in .emacs")
(ediff-defvar-local ediff-quit-widened t
"*Non-nil means: when finished, Ediff widens buffers A/B.
Actually, Ediff restores the scope of visibility that existed at startup.")
(defvar ediff-keep-variants t
"*Nil means that non-modified variant buffers should be removed after some
interrogation.
(defcustom ediff-keep-variants t
"*Nil means that non-modified variant buffers should be removed at the end of the session after some interrogation.
Supplying a prefix argument to the quit command `q' temporarily reverses the
meaning of this variable.")
meaning of this variable."
:type 'boolean
:group 'ediff)
(ediff-defvar-local ediff-highlight-all-diffs t
"If nil, only the selected differences are highlighted.
......@@ -522,7 +560,7 @@ ediff-toggle-hilit. Use `setq-default' to set it.")
(ediff-defvar-local ediff-buffer-values-orig-C nil "")
;; The original values of ediff-protected-variables for buffer Ancestor
(ediff-defvar-local ediff-buffer-values-orig-Ancestor nil "")
;; Buffer-local variables to be saved then restored during Ediff sessions
;; Buffer-local variables to be saved then restored during Ediff sessions
(defconst ediff-protected-variables '(
;;buffer-read-only
......@@ -589,12 +627,14 @@ ediff-toggle-hilit. Use `setq-default' to set it.")
;; Priority of non-selected overlays.
(defvar ediff-shadow-overlay-priority 100 "")
(defvar ediff-version-control-package 'vc
(defcustom ediff-version-control-package 'vc
"Version control package used.
Currently, Ediff supports vc.el, rcs.el, pcl-cvs.el, and generic-sc.el. The
standard Emacs interface to RCS, CVS, SCCS, etc., is vc.el. However, some
people find the other two packages more convenient. Set this variable to the
appropriate symbol: `rcs', `pcl-cvs', or `generic-sc' if you so desire.")
appropriate symbol: `rcs', `pcl-cvs', or `generic-sc' if you so desire."
:type 'symbol
:group 'ediff)
(if ediff-xemacs-p
......@@ -1106,6 +1146,12 @@ If nil, Ediff tries to deduce the function from the binding of C-x C-q.
Normally, this is the `toggle-read-only' function, but, if version
control is used, it could be `vc-toggle-read-only' or `rcs-toggle-read-only'.")
(defcustom ediff-make-buffers-readonly-at-startup nil
"*Make all variant buffers read-only when Ediff starts up.
This property can be toggled interactively."
:type 'boolean
:group 'ediff)
;;; Misc
......@@ -1121,9 +1167,11 @@ as `ediff-merge-directory' or `ediff-merge-directory-revisions'.")
;; file where the result of the merge is to be saved. used internally
(ediff-defvar-local ediff-merge-store-file nil "")
(defvar ediff-no-emacs-help-in-control-buffer nil
(defcustom ediff-no-emacs-help-in-control-buffer nil
"*Non-nil means C-h should not invoke Emacs help in control buffer.
Instead, C-h jumps to previous difference.")
Instead, C-h would jump to previous difference."
:type 'boolean
:group 'ediff)
(defvar ediff-temp-file-prefix
(let ((env (or (getenv "TMPDIR")
......@@ -1155,12 +1203,13 @@ More precisely, a regexp to match any one such character.")
(defvar ediff-H-glyph (if ediff-xemacs-p (make-glyph "H")))
(ediff-defvar-local ediff-temp-file-A nil
"Temporary file used for refining difference regions in buffer A.")
(ediff-defvar-local ediff-temp-file-B nil
"Temporary file used for refining difference regions in buffer B.")
(ediff-defvar-local ediff-temp-file-C nil
"Temporary file used for refining difference regions in buffer C.")
;; Temporary file used for refining difference regions in buffer A.
(ediff-defvar-local ediff-temp-file-A nil "")
;; Temporary file used for refining difference regions in buffer B.
(ediff-defvar-local ediff-temp-file-B nil "")
;; Temporary file used for refining difference regions in buffer C.
(ediff-defvar-local ediff-temp-file-C nil "")
;;; In-line functions
......
......@@ -49,6 +49,12 @@
(require 'ediff-init)
(defcustom ediff-quit-merge-hook 'ediff-maybe-save-and-delete-merge
"*Hooks to run before quitting a merge job.
The most common use is to save and delete the merge buffer."
:type 'hook
:group 'ediff-merge)
(defcustom ediff-default-variant 'combined
"*The variant to be used as a default for buffer C in merging.
......
......@@ -50,28 +50,62 @@
(require 'ediff-init)
(defcustom ediff-patch-program "patch"
"*Name of the program that applies patches.
It is recommended to use GNU-compatible versions."
:type 'string
:group 'ediff-ptch)
(defcustom ediff-patch-options "-f"
"*Options to pass to ediff-patch-program.
Note: the `-b' option should be specified in `ediff-backup-specs'.
It is recommended to pass the `-f' option to the patch program, so it won't ask
questions. However, some implementations don't accept this option, in which
case the default value for this variable should be changed."
:type 'string
:group 'ediff-ptch)
(defvar ediff-last-dir-patch nil
"Last directory used by an Ediff command for file to patch.")
(defvar ediff-backup-extension
(if (memq system-type '(vax-vms axp-vms emx ms-dos windows-nt windows-95))
"_orig" ".orig")
;; the default backup extension
(defconst ediff-default-backup-extension
(if (memq system-type '(vax-vms axp-vms emx ms-dos))
"_orig" ".orig"))
(defcustom ediff-backup-extension ediff-default-backup-extension
"Backup extension used by the patch program.
See also `ediff-backup-specs'.")
See also `ediff-backup-specs'."
:type 'string
:group 'ediff-ptch)
(defcustom ediff-backup-specs (format "-b %s" ediff-backup-extension)
(defcustom ediff-backup-specs
(cond
((zerop (call-process ediff-patch-program nil nil nil "-z." "-b"))
;; GNU `patch' v. >= 2.2
(format "-z%s -b" ediff-backup-extension))
((zerop (call-process ediff-patch-program nil nil nil "-b"))
;; POSIX `patch' -- ediff-backup-extension must be ".orig"
(setq ediff-backup-extension ediff-default-backup-extension)
"-b")
(t
;; traditional `patch'
(format "-b %s" ediff-backup-extension)))
"*Backup directives to pass to the patch program.
Ediff requires that the old version of the file \(before applying the patch\)
is saved in a file named `the-patch-file.extension'. Usually `extension' is
be saved in a file named `the-patch-file.extension'. Usually `extension' is
`.orig', but this can be changed by the user and may depend on the system.
Therefore, Ediff needs to know the backup extension used by the patch program.
Some versions of the patch program let you specify `-b backup-extension'.
Other versions only permit `-b', which assumes some canned extension
\(usually `.orig'\).
Other versions only permit `-b', which assumes the extension `.orig'
\(in which case ediff-backup-extension MUST be also `.orig'\). The latest
versions of GNU patch require `-b -z backup-extension'.
Note that both `ediff-backup-extension' and `ediff-backup-specs'
must be properly set. If your patch program takes the option `-b',
must be set properly. If your patch program takes the option `-b',
but not `-b extension', the variable `ediff-backup-extension' must
still be set so Ediff will know which extension to use."
:type 'string
......@@ -89,26 +123,12 @@ still be set so Ediff will know which extension to use."
"\\|" ; GNU unified format diff 2-liner
"^--- \\([^ \t]+\\)[\t ]+.*\n\\+\\+\\+ \\([^ \t]+\\)"
"\\)")
"*Regexp matching filename 2-liners at the start of each context diff."
"*Regexp matching filename 2-liners at the start of each context diff.
You probably don't want to change that, unless you are using an obscure patch
program."
:type 'regexp
:group 'ediff-ptch)
(defcustom ediff-patch-program "patch"
"*Name of the program that applies patches.
It is recommended to use GNU-compatible versions."
:type 'string
:group 'ediff-ptch)
(defcustom ediff-patch-options "-f"
"*Options to pass to ediff-patch-program.
Note: the `-b' option should be specified in `ediff-backup-specs'.
It is recommended to pass the `-f' option to the patch program, so it won't ask
questions. However, some implementations don't accept this option, in which
case the default value for this variable should be changed."
:type 'string
:group 'ediff-ptch)
;; The buffer of the patch file. Local to control buffer.
(ediff-defvar-local ediff-patchbufer nil "")
......@@ -476,7 +496,7 @@ Else, read patch file into a new buffer."
(true-source-filename source-filename)
(target-filename source-filename)
target-buf buf-to-patch file-name-magic-p
patch-return-code ctl-buf backup-style aux-wind)
patch-return-code ctl-buf backup-style)
(if (string-match "-V" ediff-patch-options)
(error
......@@ -535,44 +555,33 @@ Else, read patch file into a new buffer."
(concat true-source-filename ediff-backup-extension)))
(progn
(with-output-to-temp-buffer ediff-msg-buffer
(princ (format "
Patch has failed OR the backup version of the patched file was not created by
the patch program.
(princ (format
"Patch program has failed due to a bad patch file OR
because it couldn't create the backup for the file to be patched.
One reason may be that the values of the variables
The former could be caused by a corrupt patch file or because the %S
program doesn't understand the format of the patch file in use.
The second problem might be due to an incompatibility among these settings:
ediff-patch-program = %S
ediff-patch-options = %S
ediff-backup-extension = %S
ediff-backup-specs = %S
are not appropriate for the program specified in the variable
ediff-patch-program = %S
Another reason could be that the %S program doesn't understand
the format of the patch file you used.
See Ediff on-line manual for more details on these variables.
\(Or use a GNU-compatible patch program and stay out of trouble.\)
Type any key to continue...
"
In particular, check the documentation for `ediff-backup-specs'. "
ediff-patch-program
ediff-patch-program
ediff-patch-options
ediff-backup-extension
ediff-backup-specs
ediff-patch-program
ediff-patch-program)))
)))
(beep 1)
(if (setq aux-wind (get-buffer-window ediff-msg-buffer))
(progn
(select-window aux-wind)
(goto-char (point-max))))
(read-char-exclusive)
(if aux-wind (bury-buffer)) ; ediff-msg-buffer
(if (setq aux-wind (get-buffer-window patch-diagnostics))
(progn
(select-window aux-wind)
(bury-buffer)))
(switch-to-buffer-other-window patch-diagnostics)
(error "Patch appears to have failed")))
;; If black magic is involved, apply patch to a temp copy of the
......
......@@ -101,6 +101,7 @@ This mode is entered through one of the following commands:
`ediff-patch-file'
`ediff-patch-buffer'
`epatch-buffer'
`erevision'
`ediff-revision'
Commands:
......@@ -404,7 +405,10 @@ to invocation.")
(or (memq control-buffer ediff-this-buffer-ediff-sessions)
(setq ediff-this-buffer-ediff-sessions
(cons control-buffer ediff-this-buffer-ediff-sessions)))
(if ediff-make-buffers-readonly-at-startup
(setq buffer-read-only t))
)
(ediff-eval-in-buffer ediff-buffer-B
(ediff-nuke-selective-display)
(run-hooks 'ediff-prepare-buffer-hook)
......@@ -414,7 +418,10 @@ to invocation.")
(or (memq control-buffer ediff-this-buffer-ediff-sessions)
(setq ediff-this-buffer-ediff-sessions
(cons control-buffer ediff-this-buffer-ediff-sessions)))
(if ediff-make-buffers-readonly-at-startup
(setq buffer-read-only t))
)
(if ediff-3way-job
(ediff-eval-in-buffer ediff-buffer-C
(ediff-nuke-selective-display)
......@@ -424,6 +431,8 @@ to invocation.")
(setq ediff-this-buffer-ediff-sessions
(cons control-buffer
ediff-this-buffer-ediff-sessions)))
(if ediff-make-buffers-readonly-at-startup
(setq buffer-read-only t))
))
(if (ediff-buffer-live-p ediff-ancestor-buffer)
......
......@@ -177,7 +177,7 @@ responsibility."
Expects three parameters: the control buffer, the desired width and height
of the control frame. It returns an association list
of the form \(\(top . <position>\) \(left . <position>\)\)"
:type 'boolean
:type 'function
:group 'ediff-window)
(defcustom ediff-control-frame-upward-shift (if ediff-xemacs-p 42 14)
......
......@@ -6,8 +6,8 @@
;; Created: February 2, 1994
;; Keywords: comparing, merging, patching, version control.
(defconst ediff-version "2.65" "The current version of Ediff")
(defconst ediff-date "May 1, 1997" "Date of last update")
(defconst ediff-version "2.66" "The current version of Ediff")
(defconst ediff-date "July 9, 1997" "Date of last update")
;; This file is part of GNU Emacs.
......@@ -109,6 +109,10 @@
(provide 'ediff)
;; Compiler pacifier
(defvar cvs-cookie-handle)
(defvar ediff-last-dir-patch)
(defvar ediff-patch-default-directory)
(and noninteractive
(eval-when-compile
(load-library "dired")
......@@ -136,26 +140,20 @@
(defcustom ediff-use-last-dir nil
"*If t, Ediff uses previous directory as default when reading file name."
"*If t, Ediff will use previous directory as default when reading file name."
:type 'boolean
:group 'ediff)
(defvar ediff-last-dir-A nil
"Last directory used by an Ediff command for file-A.")
(defvar ediff-last-dir-B nil
"Last directory used by an Ediff command for file-B.")
(defvar ediff-last-dir-C nil
"Last directory used by an Ediff command for file-C.")
(defvar ediff-last-dir-ancestor nil
"Last directory used by an Ediff command for the ancestor file.")
(defvar ediff-last-merge-autostore-dir
"Last directory used by an Ediff command as the output directory for merge.")
;; Some defvars to reduce the number of compiler warnings
(defvar cvs-cookie-handle)
(defvar ediff-last-dir-patch)
(defvar ediff-patch-default-directory)
;; end of compiler pacifier
;; Last directory used by an Ediff command for file-A.
(defvar ediff-last-dir-A nil)
;; Last directory used by an Ediff command for file-B.
(defvar ediff-last-dir-B nil)
;; Last directory used by an Ediff command for file-C.
(defvar ediff-last-dir-C nil)
;; Last directory used by an Ediff command for the ancestor file.
(defvar ediff-last-dir-ancestor nil)
;; Last directory used by an Ediff command as the output directory for merge.
(defvar ediff-last-merge-autostore-dir)
;; Used as a startup hook to set `_orig' patch file read-only.
......@@ -878,7 +876,7 @@ lines. For small regions, use `ediff-regions-wordwise'."
(ediff-regions-internal
(get-buffer buffer-A) reg-A-beg reg-A-end
(get-buffer buffer-B) reg-B-beg reg-B-end
startup-hooks 'ediff-regions-linewise nil))) ; no word mode
startup-hooks 'ediff-regions-linewise nil nil))) ; no word mode
;; compare region beg-A to end-A of buffer-A
;; to regions beg-B -- end-B in buffer-B.
......@@ -1235,6 +1233,10 @@ buffer. Use `vc.el' or `rcs.el' depending on `ediff-version-control-package'."
(intern (format "ediff-%S-internal" ediff-version-control-package))
rev1 rev2 startup-hooks)
))
;;;###autoload
(defalias 'erevision 'ediff-revision)
;; Test if version control package is loaded and load if not
......
......@@ -13,7 +13,8 @@
(defvar vip-minibuffer-vi-face)
(defvar vip-minibuffer-emacs-face)
(defvar viper-always)
(defvar vip-mode-string )
(defvar vip-mode-string)
(defvar vip-custom-file-name)
(defvar iso-accents-mode)
(defvar zmacs-region-stays)
(defvar mark-even-if-inactive)
......@@ -77,14 +78,15 @@
(defconst vip-movement-commands '(?b ?B ?e ?E ?f ?F ?G ?h ?H ?j ?k ?l
?H ?M ?L ?n ?t ?T ?w ?W ?$ ?%
?^ ?( ?) ?- ?+ ?| ?{ ?} ?[ ?] ?' ?`
?; ?, ?0 ?? ?/
?; ?, ?0 ?? ?/ ?\C-m ?\
)
"Movement commands")
;; define vip-movement-command-p
(vip-test-com-defun vip-movement-command)
(defconst vip-digit-commands '(?1 ?2 ?3 ?4 ?5 ?6 ?7 ?8 ?9)
"Digit commands")
;; Vi digit commands
(defconst vip-digit-commands '(?1 ?2 ?3 ?4 ?5 ?6 ?7 ?8 ?9))
;; define vip-digit-command-p
(vip-test-com-defun vip-digit-command)
......@@ -765,7 +767,7 @@ as a Meta key and any number of multiple escapes is allowed."
(defun vip-toggle-key-action ()
"Action bound to `vip-toggle-key'."
(interactive)
(if (and (< vip-expert-level 2) (equal vip-toggle-key "\C-z"))
(if (and (< viper-expert-level 2) (equal vip-toggle-key "\C-z"))
(if (vip-window-display-p)
(vip-iconify)
(suspend-emacs))
......@@ -1358,8 +1360,10 @@ If the prefix argument, ARG, is non-nil, it is used instead of `val'."
(setq vip-last-insertion (nth 4 vip-d-com)
vip-d-char (nth 4 vip-d-com)))
(funcall m-com (cons val com))
(if (and vip-keep-point-on-repeat (< save-point (point)))
(goto-char save-point)) ; go back to before repeat.
(cond ((and (< save-point (point)) vip-keep-point-on-repeat)
(goto-char save-point)) ; go back to before repeat.
((and (< save-point (point)) vip-ex-style-editing-in-insert)
(or (bolp) (backward-char 1))))
(if (and (eolp) (not (bolp)))
(backward-char 1))