9 |
;; Author: Michael Kifer <kifer@cs.stonybrook.edu> |
;; Author: Michael Kifer <kifer@cs.stonybrook.edu> |
10 |
;; Keywords: emulations |
;; Keywords: emulations |
11 |
|
|
12 |
(defconst viper-version "3.11.5 of September 19, 2005" |
(defconst viper-version "3.11.5 of October 5, 2005" |
13 |
"The current version of Viper") |
"The current version of Viper") |
14 |
|
|
15 |
;; This file is part of GNU Emacs. |
;; This file is part of GNU Emacs. |
605 |
)) |
)) |
606 |
(viper-set-expert-level 'dont-change-unless))) |
(viper-set-expert-level 'dont-change-unless))) |
607 |
|
|
|
(if viper-xemacs-p |
|
|
(viper-make-variable-buffer-local 'bar-cursor)) |
|
608 |
(if (eq major-mode 'viper-mode) |
(if (eq major-mode 'viper-mode) |
609 |
(setq major-mode 'fundamental-mode)) |
(setq major-mode 'fundamental-mode)) |
610 |
|
|
625 |
|
|
626 |
;; This hook designed to enable Vi-style editing in comint-based modes." |
;; This hook designed to enable Vi-style editing in comint-based modes." |
627 |
(defun viper-comint-mode-hook () |
(defun viper-comint-mode-hook () |
628 |
(setq require-final-newline nil |
(set (make-local-variable 'require-final-newline) nil) |
629 |
viper-ex-style-editing nil |
(setq viper-ex-style-editing nil |
630 |
viper-ex-style-motion nil) |
viper-ex-style-motion nil) |
631 |
(viper-change-state-to-insert)) |
(viper-change-state-to-insert)) |
632 |
|
|
998 |
;; these are primarily advices and Vi-ish variable settings |
;; these are primarily advices and Vi-ish variable settings |
999 |
(defun viper-non-hook-settings () |
(defun viper-non-hook-settings () |
1000 |
|
|
|
;; This var is not local in Emacs, so we make it local. It must be local |
|
|
;; because although the stack of minor modes can be the same for all buffers, |
|
|
;; the associated *keymaps* can be different. In Viper, |
|
|
;; viper-vi-local-user-map, viper-insert-local-user-map, and others can have |
|
|
;; different keymaps for different buffers. Also, the keymaps associated |
|
|
;; with viper-vi/insert-state-modifier-minor-mode can be different. |
|
|
;; ***This is needed only in case emulation-mode-map-alists is not defined |
|
|
(unless |
|
|
(and (fboundp 'add-to-ordered-list) (boundp 'emulation-mode-map-alists)) |
|
|
(viper-make-variable-buffer-local 'minor-mode-map-alist)) |
|
|
|
|
1001 |
;; Viper changes the default mode-line-buffer-identification |
;; Viper changes the default mode-line-buffer-identification |
1002 |
(setq-default mode-line-buffer-identification '(" %b")) |
(setq-default mode-line-buffer-identification '(" %b")) |
1003 |
|
|
1005 |
(setq next-line-add-newlines nil |
(setq next-line-add-newlines nil |
1006 |
require-final-newline t) |
require-final-newline t) |
1007 |
|
|
|
(viper-make-variable-buffer-local 'require-final-newline) |
|
|
|
|
1008 |
;; don't bark when mark is inactive |
;; don't bark when mark is inactive |
1009 |
(if viper-emacs-p |
(if viper-emacs-p |
1010 |
(setq mark-even-if-inactive t)) |
(setq mark-even-if-inactive t)) |
1012 |
(setq scroll-step 1) |
(setq scroll-step 1) |
1013 |
|
|
1014 |
;; Variable displaying the current Viper state in the mode line. |
;; Variable displaying the current Viper state in the mode line. |
|
(viper-deflocalvar viper-mode-string viper-emacs-state-id) |
|
1015 |
(or (memq 'viper-mode-string global-mode-string) |
(or (memq 'viper-mode-string global-mode-string) |
1016 |
(setq global-mode-string |
(setq global-mode-string |
1017 |
(append '("" viper-mode-string) (cdr global-mode-string)))) |
(append '("" viper-mode-string) (cdr global-mode-string)))) |
1320 |
(provide 'viper) |
(provide 'viper) |
1321 |
|
|
1322 |
|
|
1323 |
;;; Local Variables: |
;; Local Variables: |
1324 |
;;; eval: (put 'viper-deflocalvar 'lisp-indent-hook 'defun) |
;; eval: (put 'viper-deflocalvar 'lisp-indent-hook 'defun) |
1325 |
;;; End: |
;; End: |
1326 |
|
|
1327 |
;;; arch-tag: 5f3e844c-c4e6-4bbd-9b73-63bdc14e7d79 |
;; arch-tag: 5f3e844c-c4e6-4bbd-9b73-63bdc14e7d79 |
1328 |
;;; viper.el ends here |
;;; viper.el ends here |