diff man/viper.texi @ 60168:d96e54250eea

* viper-cmd.el (viper-prefix-commands): make into a defconst. (viper-exec-buffer-search): use regexp-quote to quote the buffer string. (viper-minibuffer-setup-sentinel): make some variables buffer-local. (viper-skip-separators): bug fix. (viper-set-searchstyle-toggling-macros): allow to unset macros in a particular major mode. (viper-del-backward-char-in-replace): don't put deleted char on the kill ring. * viper-ex.el (viper-color-display-p): new function. (viper-has-face-support-p): use viper-color-display-p. * viper-keym.el (viper-gnus-modifier-map): new keymap. * viper-macs.el (viper-unrecord-kbd-macro): bug fix. * viper-util.el (viper-glob-unix-files): fix shell status check. (viper-file-remote-p): make equivalent to file-remote-p. * viper.el (viper-major-mode-modifier-list): use viper-gnus-modifier-map.
author Michael Kifer <kifer@cs.stonybrook.edu>
date Sat, 19 Feb 2005 19:32:47 +0000
parents b1ae5333057a
children a4c59075cac8 bf0d492ea2d5
line wrap: on
line diff
--- a/man/viper.texi	Sat Feb 19 18:54:24 2005 +0000
+++ b/man/viper.texi	Sat Feb 19 19:32:47 2005 +0000
@@ -2285,7 +2285,7 @@
 bind common keys to specialized commands.  This might make sense for modes
 that bind only a small number of common keys.  For instance, Viper subverts
 the Shell mode by changing the bindings for @kbd{C-m} and @kbd{C-d} using
-@code{viper-add-local-keys} described in section on customization
+@code{viper-add-local-keys} described in the section on customization
 (@pxref{Customization}).
 
 In some cases, some @emph{minor} modes might override certain essential
@@ -2294,7 +2294,7 @@
 @code{M-x viper-mode} will correct the situation.  Viper knows about
 several such minor modes and takes care of them, so the above trick
 is usually not necessary.  If you find that some minor mode, e.g.,
-@code{nasty-mode.el} interferes with Viper, putting the following in
+@code{nasty-mode} interferes with Viper, putting the following in
 @file{.viper} should fix the problem:
 @lisp
 (viper-harness-minor-mode "nasty-mode")
@@ -2305,7 +2305,7 @@
 
 It may not be always obvious which minor mode is at fault.  The only
 guidance here is to look into the file that defines the minor mode you are
-suspecting, say @code{nasty-mode.el}, and see if it has a variable called
+suspecting, say @file{nasty-mode.el}, and see if it has a variable called
 @code{nasty-mode-map}.  Then check if there is a statement of the form
 @lisp
 (define-key nasty-mode-map key function)
@@ -2316,6 +2316,18 @@
 suspicion is wrong, no harm is done if you harness a minor mode that
 doesn't need to be harnessed.
 
+It is recommended to harness even those minor modes that don't override
+Viper keys, but still have their own keymaps. A general way to
+make a minor mode, @code{my-mode},
+compatible with Viper is to have the file @file{my-mode.el} include the following code:
+
+@lisp
+(when (fboundp 'viper-harness-minor-mode)
+  (let ((lib (file-name-sans-extension
+               (file-name-nondirectory load-file-name))))
+    (viper-harness-minor-mode lib)))
+@end lisp
+
 @vindex @code{viper-want-emacs-keys-in-vi}
 @vindex @code{viper-want-emacs-keys-in-insert}
 @vindex @code{viper-always}
@@ -2371,11 +2383,19 @@
 @end example
 @findex @code{viper-set-searchstyle-toggling-macros}
 
+If you don't like this feature as a default, but would still like to have
+it in some major modes, you can do so by first unsetting it globally, as
+shown above, and then setting it in the desired major modes as follows:
+@example
+(viper-set-searchstyle-toggling-macros nil 'c-mode)
+(viper-set-searchstyle-toggling-macros nil 'lisp-mode)
+@end example
+
 @item Vi-isms in Emacs state
 Some people find it useful to use the Vi-style search key, `/', to invoke
 search in modes which Viper leaves in emacs-state.  These modes are:
-@code{dired-mode}, @code{mh-folder-mode}, @code{gnus-group-mode},
-@code{gnus-summary-mode}, @code{Info-mode}, and @code{Buffer-menu-mode}
+@code{dired-mode}, @code{mh-folder-mode},
+@code{Info-mode}, and @code{Buffer-menu-mode}
 (more may be added in the future).  So, in the above modes, Viper binds `/'
 so that it will behave Vi-style.  Furthermore, in those major modes, Viper
 binds `:' to invoke ex-style commands, like in vi-state.  And, as described
@@ -4470,6 +4490,7 @@
 gvr@@halcyon.com (George V.@: Reilly),
 hatazaki@@bach.convex.com (Takao Hatazaki),
 hpz@@ibmhpz.aug.ipp-garching.mpg.de (Hans-Peter Zehrfeld),
+irie@@t.email.ne.jp (Irie Tetsuya),
 jackr@@dblues.engr.sgi.com (Jack Repenning),
 jamesm@@bga.com (D.J.@: Miller II),
 jjm@@hplb.hpl.hp.com (Jean-Jacques Moreau),