# HG changeset patch # User Pavel Jank # Date 1002693444 0 # Node ID 32f917f3edf781b9ac3ca6fc07c054ba20e5a9a1 # Parent 8ac87a0f3b3ddb22a907c8bd49468ccf62533f71 use defalias instead of fset for user-visible commands. diff -r 8ac87a0f3b3d -r 32f917f3edf7 lisp/emulation/tpu-edt.el --- a/lisp/emulation/tpu-edt.el Tue Oct 09 12:15:09 2001 +0000 +++ b/lisp/emulation/tpu-edt.el Wed Oct 10 05:57:24 2001 +0000 @@ -783,52 +783,56 @@ ;;; Command and Function Aliases ;;; ;;;###autoload -(fset 'tpu-edt-mode 'tpu-edt-on) -(fset 'TPU-EDT-MODE 'tpu-edt-on) +(defalias 'tpu-edt-mode 'tpu-edt-on) +(defalias 'TPU-EDT-MODE 'tpu-edt-on) ;;;###autoload -(fset 'tpu-edt 'tpu-edt-on) -(fset 'TPU-EDT 'tpu-edt-on) +(defalias 'tpu-edt 'tpu-edt-on) +(defalias 'TPU-EDT 'tpu-edt-on) -(fset 'exit 'tpu-exit) -(fset 'EXIT 'tpu-exit) +;; Note: The following functions have no `tpu-' prefix. This is unavoidable. +;; The real TPU/edt editor has interactive commands with these names, +;; so tpu-edt.el users expect things like M-x exit RET and M-x help RET +;; to work. Therefore it really is necessary to define these functions, +;; even in cases where they redefine existing Emacs functions. -(fset 'Get 'tpu-get) -(fset 'GET 'tpu-get) +(defalias 'exit 'tpu-exit) +(defalias 'EXIT 'tpu-exit) + +(defalias 'Get 'tpu-get) +(defalias 'GET 'tpu-get) -(fset 'include 'tpu-include) -(fset 'INCLUDE 'tpu-include) +(defalias 'include 'tpu-include) +(defalias 'INCLUDE 'tpu-include) + +(defalias 'quit 'tpu-quit) +(defalias 'QUIT 'tpu-quit) -(fset 'quit 'tpu-quit) -(fset 'QUIT 'tpu-quit) +(defalias 'spell 'tpu-spell-check) +(defalias 'SPELL 'tpu-spell-check) -(fset 'spell 'tpu-spell-check) -(fset 'SPELL 'tpu-spell-check) +(defalias 'what\ line 'tpu-what-line) +(defalias 'WHAT\ LINE 'tpu-what-line) + +(defalias 'replace 'tpu-lm-replace) +(defalias 'REPLACE 'tpu-lm-replace) -(fset 'what\ line 'tpu-what-line) -(fset 'WHAT\ LINE 'tpu-what-line) +(defalias 'help 'tpu-help) +(defalias 'HELP 'tpu-help) + +(defalias 'set\ cursor\ free 'tpu-set-cursor-free) +(defalias 'SET\ CURSOR\ FREE 'tpu-set-cursor-free) -(fset 'replace 'tpu-lm-replace) -(fset 'REPLACE 'tpu-lm-replace) +(defalias 'set\ cursor\ bound 'tpu-set-cursor-bound) +(defalias 'SET\ CURSOR\ BOUND 'tpu-set-cursor-bound) -;; Apparently TPU users really expect to do M-x help RET to get help. -;; So it is really necessary to redefine this. -(fset 'help 'tpu-help) -(fset 'HELP 'tpu-help) +(defalias 'set\ scroll\ margins 'tpu-set-scroll-margins) +(defalias 'SET\ SCROLL\ MARGINS 'tpu-set-scroll-margins) ;; Real TPU error messages end in periods. ;; Define this to avoid openly flouting Emacs coding standards. (defalias 'tpu-error 'error) -(fset 'set\ cursor\ free 'tpu-set-cursor-free) -(fset 'SET\ CURSOR\ FREE 'tpu-set-cursor-free) - -(fset 'set\ cursor\ bound 'tpu-set-cursor-bound) -(fset 'SET\ CURSOR\ BOUND 'tpu-set-cursor-bound) - -(fset 'set\ scroll\ margins 'tpu-set-scroll-margins) -(fset 'SET\ SCROLL\ MARGINS 'tpu-set-scroll-margins) - ;; Around emacs version 18.57, function line-move was renamed to ;; next-line-internal. If we're running under an older emacs,