Mercurial > emacs
comparison lisp/emulation/viper-util.el @ 106192:a2ee981efbec
2009-11-22 Michael Kifer <kifer@cs.stonybrook.edu>
* viper-cmd.el: use viper-last-command-char instead of
last-command-char/last-command-event.
(viper-prefix-arg-value): do correct conversion of event-char for
XEmacs.
* viper-util.el, viper.el: use viper-last-command-char instead of
last-command-char/last-command-event.
* ediff-init.el, ediff-mult.el, ediff-util.el: relpace
last-command-char and last-command-event with (ediff-last-command-char) everywhere.
* ediff-vers.el (ediff-rcs-get-output-buffer): make sure the buffer is
created in fundamental mode.
* ediff.el (ediff-version): revert the change of interactive-p to
called-interactively-p.
author | Michael Kifer <kifer@cs.stonybrook.edu> |
---|---|
date | Sun, 22 Nov 2009 03:14:14 +0000 |
parents | 328150f0cf76 |
children | 1d1d5d9bd884 |
comparison
equal
deleted
inserted
replaced
106191:baf1843cbc25 | 106192:a2ee981efbec |
---|---|
172 (t | 172 (t |
173 (viper-change-cursor-color | 173 (viper-change-cursor-color |
174 (viper-frame-value viper-vi-state-cursor-color) | 174 (viper-frame-value viper-vi-state-cursor-color) |
175 frame)))) | 175 frame)))) |
176 | 176 |
177 ;; By default, saves current frame cursor color in the | 177 ;; By default, saves current frame cursor color before changing viper state |
178 ;; viper-saved-cursor-color-in-replace-mode property of viper-replace-overlay | |
179 (defun viper-save-cursor-color (before-which-mode) | 178 (defun viper-save-cursor-color (before-which-mode) |
180 (if (and (viper-window-display-p) (viper-color-display-p)) | 179 (if (and (viper-window-display-p) (viper-color-display-p)) |
181 (let ((color (viper-get-cursor-color))) | 180 (let ((color (viper-get-cursor-color))) |
182 (if (and (stringp color) (viper-color-defined-p color) | 181 (if (and (stringp color) (viper-color-defined-p color) |
182 ;; there is something fishy in that the color is not saved if | |
183 ;; it is the same as frames default cursor color. need to be | |
184 ;; checked. | |
183 (not (string= color | 185 (not (string= color |
184 (viper-frame-value | 186 (viper-frame-value |
185 viper-replace-overlay-cursor-color)))) | 187 viper-replace-overlay-cursor-color)))) |
186 (modify-frame-parameters | 188 (modify-frame-parameters |
187 (selected-frame) | 189 (selected-frame) |
1045 (intern (char-to-string basis))))) | 1047 (intern (char-to-string basis))))) |
1046 (if mod | 1048 (if mod |
1047 (append mod (list basis)) | 1049 (append mod (list basis)) |
1048 basis)))) | 1050 basis)))) |
1049 | 1051 |
1052 (defun viper-last-command-char () | |
1053 (if (featurep 'xemacs) | |
1054 (event-to-character last-command-event) | |
1055 last-command-event)) | |
1056 | |
1050 (defun viper-key-to-emacs-key (key) | 1057 (defun viper-key-to-emacs-key (key) |
1051 (let (key-name char-p modifiers mod-char-list base-key base-key-name) | 1058 (let (key-name char-p modifiers mod-char-list base-key base-key-name) |
1052 (cond ((featurep 'xemacs) key) | 1059 (cond ((featurep 'xemacs) key) |
1053 | 1060 |
1054 ((symbolp key) | 1061 ((symbolp key) |