]> code.delx.au - gnu-emacs/blobdiff - lisp/emulation/viper-mous.el
Merge from origin/emacs-25
[gnu-emacs] / lisp / emulation / viper-mous.el
index eda1a7ec9373b8bb90352910b270df388905f499..b95a341f8eeca8d14a12727eacc1130467115a31 100644 (file)
@@ -1,6 +1,6 @@
 ;;; viper-mous.el --- mouse support for Viper
 
-;; Copyright (C) 1994-1997, 2001-2012 Free Software Foundation, Inc.
+;; Copyright (C) 1994-1997, 2001-2016 Free Software Foundation, Inc.
 
 ;; Author: Michael Kifer <kifer@cs.stonybrook.edu>
 ;; Package: viper
 (defvar viper-s-string)
 (defvar viper-re-search)
 
-;; loading happens only in non-interactive compilation
-;; in order to spare non-viperized emacs from being viperized
-(if noninteractive
-    (eval-when-compile
-      (require 'viper-cmd)
-      ))
-;; end pacifier
-
 (require 'viper-util)
+;; end pacifier
 
 
 (defgroup viper-mouse nil
@@ -140,6 +133,10 @@ considered related."
     (posn-point (event-start click))))
 
 
+
+(declare-function viper-backward-char-carefully "viper-cmd" (&optional arg))
+(declare-function viper-forward-char-carefully "viper-cmd" (&optional arg))
+
 (defun viper-surrounding-word (count click-count)
    "Returns word surrounding point according to a heuristic.
 COUNT indicates how many regions to return.
@@ -148,7 +145,7 @@ If CLICK-COUNT is 2,then `word' is a Word in Vi sense.
 If the character clicked on is a non-separator and is non-alphanumeric but
 is adjacent to an alphanumeric symbol, then it is considered alphanumeric
 for the purpose of this command.  If this character has a matching
-character, such as `\(' is a match for `\)', then the matching character is
+character, such as `(' is a match for `)', then the matching character is
 also considered alphanumeric.
 For convenience, in Lisp modes, `-' is considered alphanumeric.
 
@@ -253,7 +250,7 @@ On single or double click, returns the word as determined by
 With prefix argument, N, insert that many words.
 This command must be bound to a mouse click.
 The double-click action of the same mouse button must not be bound
-\(or it must be bound to the same function\).
+\(or it must be bound to the same function).
 See `viper-surrounding-word' for the definition of a word in this case."
   (interactive "e\nP")
   (if viper-frame-of-focus     ;; to handle clicks in another frame
@@ -335,12 +332,14 @@ See `viper-surrounding-word' for the definition of a word in this case."
          viper-current-click-count
        0))))
 
+(declare-function viper-forward-word "viper-cmd" (arg))
+(declare-function viper-adjust-window "viper-cmd" ())
 
 (defun viper-mouse-click-search-word (click arg)
    "Find the word clicked or double-clicked on.  Word may be in another window.
 With prefix argument, N, search for N-th occurrence.
 This command must be bound to a mouse click.  The double-click action of the
-same button must not be bound \(or it must be bound to the same function\).
+same button must not be bound \(or it must be bound to the same function).
 See `viper-surrounding-word' for the details on what constitutes a word for
 this command."
   (interactive "e\nP")