Mercurial > emacs
changeset 11546:66db15ec8ad8
Don't turn on tpu-edt mode.
(tpu-gnu-emacs19-p): Function deleted. Callers changed.
(tpu-load-xkeys): Use file name .tpu-keys by default.
(tpu-gnu-emacs18-p): Function deleted.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Tue, 25 Apr 1995 00:37:27 +0000 |
parents | a91fcb58e8d2 |
children | a39d8ae4ed2e |
files | lisp/emulation/tpu-edt.el |
diffstat | 1 files changed, 17 insertions(+), 29 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/emulation/tpu-edt.el Mon Apr 24 22:36:08 1995 +0000 +++ b/lisp/emulation/tpu-edt.el Tue Apr 25 00:37:27 1995 +0000 @@ -59,17 +59,11 @@ ;;; o tpu-update-mode-line o mode line section ;;; (defconst tpu-emacs19-p (not (string-lessp emacs-version "19")) - "Non-NIL if we are running Lucid or GNU Emacs version 19.") - -(defconst tpu-gnu-emacs18-p (not tpu-emacs19-p) - "Non-NIL if we are running GNU Emacs version 18.") + "Non-nil if we are running Lucid Emacs or version 19.") (defconst tpu-lucid-emacs19-p (and tpu-emacs19-p (string-match "Lucid" emacs-version)) - "Non-NIL if we are running Lucid Emacs version 19.") - -(defconst tpu-gnu-emacs19-p (and tpu-emacs19-p (not tpu-lucid-emacs19-p)) - "Non-NIL if we are running GNU Emacs version 19.") + "Non-nil if we are running Lucid Emacs version 19.") ;;; @@ -99,7 +93,7 @@ (and tpu-lucid-emacs19-p (defvar minibuffer-local-ns-map (make-sparse-keymap) - "Hack to give Lucid emacs the same maps as GNU emacs.")) + "Hack to give Lucid Emacs the same maps as ordinary Emacs.")) ;;; @@ -224,12 +218,12 @@ (cond (tpu-emacs19-p (force-mode-line-update)) (t (set-buffer-modified-p (buffer-modified-p)) (sit-for 0)))) -(cond (tpu-gnu-emacs19-p +(cond (tpu-lucid-emacs19-p + (add-hook 'zmacs-deactivate-region-hook 'tpu-update-mode-line) + (add-hook 'zmacs-activate-region-hook 'tpu-update-mode-line)) + (tpu-emacs19-p (add-hook 'activate-mark-hook 'tpu-update-mode-line) - (add-hook 'deactivate-mark-hook 'tpu-update-mode-line)) - (tpu-lucid-emacs19-p - (add-hook 'zmacs-deactivate-region-hook 'tpu-update-mode-line) - (add-hook 'zmacs-activate-region-hook 'tpu-update-mode-line))) + (add-hook 'deactivate-mark-hook 'tpu-update-mode-line))) ;;; @@ -303,15 +297,15 @@ (defun tpu-mark nil "TPU-edt version of the mark function. Return the appropriate value of the mark for the current -version of emacs." +version of Emacs." (cond (tpu-lucid-emacs19-p (mark (not zmacs-regions))) - (tpu-gnu-emacs19-p (and mark-active (mark (not transient-mark-mode)))) + (tpu-emacs19-p (and mark-active (mark (not transient-mark-mode)))) (t (mark)))) (defun tpu-set-mark (pos) - "TPU-edt verion of the set-mark function. + "TPU-edt verion of the `set-mark' function. Sets the mark at POS and activates the region acording to the -current version of emacs." +current version of Emacs." (set-mark pos) (and tpu-lucid-emacs19-p pos (zmacs-activate-region))) @@ -326,7 +320,7 @@ (defun tpu-y-or-n-p (prompt &optional not-yes) "Prompt for a y or n answer with positive default. Optional second argument NOT-YES changes default to negative. -Like emacs y-or-n-p, also accepts space as y and DEL as n." +Like Emacs `y-or-n-p', but also accepts space as y and DEL as n." (message (format "%s[%s]" prompt (if not-yes "n" "y"))) (let ((doit t)) (while doit @@ -2089,16 +2083,16 @@ (defun tpu-load-xkeys (file) "Load the TPU-edt X-windows key definitions FILE. If FILE is nil, try to load a default file. The default file names are -~/.tpu-lucid-keys for Lucid emacs, and ~/.tpu-gnu-keys for GNU emacs." +`~/.tpu-lucid-keys' for Lucid emacs, and `~/.tpu-keys' for Emacs." (interactive "fX key definition file: ") (cond (file (setq file (expand-file-name file))) (tpu-xkeys-file (setq file (expand-file-name tpu-xkeys-file))) - (tpu-gnu-emacs19-p - (setq file (expand-file-name "~/.tpu-gnu-keys"))) (tpu-lucid-emacs19-p - (setq file (expand-file-name "~/.tpu-lucid-keys")))) + (setq file (expand-file-name "~/.tpu-lucid-keys"))) + (tpu-emacs19-p + (setq file (expand-file-name "~/.tpu-keys")))) (cond ((file-readable-p file) (load-file file)) (t @@ -2175,12 +2169,6 @@ (use-global-map global-map) (setq tpu-edt-mode nil)))) - -;;; -;;; Turn on TPU-edt and announce it as a feature -;;; -(tpu-edt-mode) - (provide 'tpu-edt) ;;; tpu-edt.el ends here