* calc/calc-sel.el, calc/calc-store.el, calc/calc-stuff.el:
* calc/calc-units.el, calc/calc-yank.el, calc/calc.el:
* emacs-lisp/lisp.el, emacs-lisp/re-builder.el:
+ * emulation/vi.el, emulation/vip.el, emulation/viper-cmd.el:
* eshell/em-smart.el, eshell/esh-mode.el:
* international/mule-cmds.el:
+ * mail/mailabbrev.el:
* net/tramp.el:
* play/mpuz.el:
* progmodes/ada-mode.el, progmodes/antlr-mode.el, progmodes/cc-align.el:
(defun vi-undefined ()
(interactive)
(message "Command key \"%s\" is undefined in Evi."
- (single-key-description last-command-char))
+ (single-key-description last-command-event))
(ding))
(defun vi-unimplemented ()
(interactive)
(message "Command key \"%s\" is not implemented in Evi."
- (single-key-description last-command-char))
+ (single-key-description last-command-event))
(ding))
;;;;;
(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."
- (cond ((char-equal mark-char last-command-char) ; `` or ''
+ (cond ((char-equal mark-char last-command-event) ; `` or ''
(exchange-point-and-mark) (if line-flag (back-to-indentation)))
((char-equal mark-char ?@) ; jump and pop mark
(set-mark-command t) (if line-flag (back-to-indentation)))
"Replace char after point by CHAR. Repeat COUNT times."
(interactive "p\nc")
(delete-char count nil) ; don't save in kill ring
- (setq last-command-char char)
+ (setq last-command-event char)
(self-insert-command count)
(vi-set-last-change-command 'vi-replace-1-char count char))
the key bindings of the operators being fixed."
(interactive "P")
(catch 'vi-exit-op
- (let ((this-op-char last-command-char))
- (setq last-command-char (read-char))
- (setq this-command (lookup-key vi-com-map (char-to-string last-command-char)))
+ (let ((this-op-char last-command-event))
+ (setq last-command-event (read-char))
+ (setq this-command (lookup-key vi-com-map (char-to-string last-command-event)))
(if (not (eq this-command 'vi-digit-argument))
(setq prefix-arg arg)
(vi-digit-argument arg)
- (setq last-command-char (read-char))
- (setq this-command (lookup-key vi-com-map (char-to-string last-command-char))))
- (cond ((char-equal this-op-char last-command-char) ; line op
+ (setq last-command-event (read-char))
+ (setq this-command (lookup-key vi-com-map (char-to-string last-command-event))))
+ (cond ((char-equal this-op-char last-command-event) ; line op
(vi-execute-op this-op-char 'next-line
(cons (1- (vi-prefix-numeric-value prefix-arg))
(vi-prefix-char-value prefix-arg))))
(defun vip-digit-argument (arg)
"Begin numeric argument for the next command."
(interactive "P")
- (vip-prefix-arg-value last-command-char nil
+ (vip-prefix-arg-value last-command-event nil
(if (consp arg) (cdr arg) nil)))
(defun vip-command-argument (arg)
(interactive "P")
(condition-case conditions
(vip-prefix-arg-com
- last-command-char
+ last-command-event
(cond ((null arg) nil)
((consp arg) (car arg))
((numberp arg) arg)
ARG is used as the prefix value for the executed command. If
EVENTS is a list of events, which become the beginning of the command."
(interactive "P")
- (if (viper= last-command-char ?\\)
+ (if (viper= last-command-event ?\\)
(message "Switched to EMACS state for the next command..."))
(viper-escape-to-state arg events 'emacs-state))
last-command-char (event-to-character last-command-event))
;; Emacs represents them as sequences (str or vec)
(setq last-command-event
- (viper-copy-event (viper-seq-last-elt key))
- last-command-char last-command-event))
+ (viper-copy-event (viper-seq-last-elt key))))
(if (commandp com)
;; pretend that current state is the state we excaped to
;; then execute it with funcall and clear prefix-arg in order to not
;; confuse subsequent commands
(progn
- ;; last-command-char is the char we want emacs to think was typed
+ ;; last-command-event is the char we want emacs to think was typed
;; last. If com is not nil, the viper-digit-argument command was
;; called from within viper-prefix-arg command, such as `d', `w',
;; etc., i.e., the user typed, say, d2. In this case, `com' would be
;; viper-escape-to-vi (which is indicated by the fact that the
;; current state is not vi-state), then `event-char' represents the
;; vi command to be executed (e.g., `d', `w', etc). Again,
- ;; last-command-char must make emacs believe that this is the command
+ ;; last-command-event must make emacs believe that this is the command
;; we typed.
(cond ((eq event-char 'return) (setq event-char ?\C-m))
((eq event-char 'delete) (setq event-char ?\C-?))
((eq event-char 'backspace) (setq event-char ?\C-h))
((eq event-char 'space) (setq event-char ?\ )))
- (setq last-command-char (or com event-char))
+ (setq last-command-event (or com event-char))
(setq func (viper-exec-form-in-vi
`(key-binding (char-to-string ,event-char))))
(funcall func prefix-arg)
(if cmd-to-exec-at-end
(progn
- (setq last-command-char char)
(setq last-command-event
(viper-copy-event
(if (featurep 'xemacs) (character-to-event char) char)))
(interactive "P")
(viper-leave-region-active)
(viper-prefix-arg-value
- last-command-char (if (consp arg) (cdr arg) nil)))
+ last-command-event (if (consp arg) (cdr arg) nil)))
(defun viper-command-argument (arg)
"Accept a motion command as an argument."
(let ((viper-intermediate-command 'viper-command-argument))
(condition-case nil
(viper-prefix-arg-com
- last-command-char
+ last-command-event
(cond ((null arg) nil)
((consp arg) (car arg))
((integerp arg) arg)
"Exit minibuffer Viper way."
(interactive)
(let (command)
- (setq command (local-key-binding (char-to-string last-command-char)))
+ (setq command (local-key-binding (char-to-string last-command-event)))
(run-hooks 'viper-minibuffer-exit-hook)
(if command
(command-execute command)
;; convoluted. Instead of viper-command-argument, keymaps should bind the
;; actual commands. E.g., "dw" should be bound to a generic command
;; viper-delete that will delete things based on the value of
-;; last-command-char. This would greatly simplify the logic and the code.
+;; last-command-event. This would greatly simplify the logic and the code.
;;
;; 2. Somebody should venture to write a customization package a la
;; options.el that would allow the user to change values of variables
;;; mailabbrev.el --- abbrev-expansion of mail aliases
;; Copyright (C) 1985, 1986, 1987, 1992, 1993, 1996, 1997, 2000, 2001,
-;; 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
+;; 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009
+;; Free Software Foundation, Inc.
;; Author: Jamie Zawinski <jwz@lucid.com; now jwz@jwz.org>
;; Maintainer: FSF
;; when the user types -.) Check the character's syntax in
;; the usual syntax table.
- (or (and (integerp last-command-char)
+ (or (and (integerp last-command-event)
;; Some commands such as M-> may want to expand first.
(equal this-command 'self-insert-command)
- (or (eq (char-syntax last-command-char) ?_)
+ (or (eq (char-syntax last-command-event) ?_)
;; Don't expand on @.
- (memq last-command-char '(?@ ?. ?% ?! ?_ ?-))))
+ (memq last-command-event '(?@ ?. ?% ?! ?_ ?-))))
;; Use this table so that abbrevs can have hyphens in them.
(with-syntax-table mail-abbrev-syntax-table
(funcall expand))))