diff options
| author | Richard M. Stallman | 1993-08-10 04:18:28 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1993-08-10 04:18:28 +0000 |
| commit | e4b052bfbe5565534fb717f244f169f0e012e662 (patch) | |
| tree | bd456348ccc398ee524f15d6a73979bc19e9be6d | |
| parent | b4196a995689d74b03138c592cffa625819cd071 (diff) | |
| download | emacs-e4b052bfbe5565534fb717f244f169f0e012e662.tar.gz emacs-e4b052bfbe5565534fb717f244f169f0e012e662.zip | |
(tpu-gnu-map-key): Repaired the key name
generation code to work with the latest version of emacs.
| -rw-r--r-- | lisp/emulation/tpu-mapper.el | 22 |
1 files changed, 13 insertions, 9 deletions
diff --git a/lisp/emulation/tpu-mapper.el b/lisp/emulation/tpu-mapper.el index 1f7a63ed499..fadb2d104ab 100644 --- a/lisp/emulation/tpu-mapper.el +++ b/lisp/emulation/tpu-mapper.el | |||
| @@ -22,8 +22,6 @@ | |||
| 22 | ;; along with GNU Emacs; see the file COPYING. If not, write to | 22 | ;; along with GNU Emacs; see the file COPYING. If not, write to |
| 23 | ;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. | 23 | ;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. |
| 24 | 24 | ||
| 25 | ;;; Revision: $Id: tpu-mapper.el,v 1.1 1993/08/01 21:39:07 riepel Exp $ | ||
| 26 | |||
| 27 | ;;; Commentary: | 25 | ;;; Commentary: |
| 28 | 26 | ||
| 29 | ;; This emacs lisp program can be used to create an emacs lisp file that | 27 | ;; This emacs lisp program can be used to create an emacs lisp file that |
| @@ -71,7 +69,7 @@ | |||
| 71 | ;;; | 69 | ;;; |
| 72 | ;;; Revision Information | 70 | ;;; Revision Information |
| 73 | ;;; | 71 | ;;; |
| 74 | (defconst tpu-mapper-revision "$Revision: 1.1 $" | 72 | (defconst tpu-mapper-revision "$Revision: 1.3 $" |
| 75 | "Revision number of TPU-edt x-windows emacs key mapper.") | 73 | "Revision number of TPU-edt x-windows emacs key mapper.") |
| 76 | 74 | ||
| 77 | 75 | ||
| @@ -177,12 +175,14 @@ | |||
| 177 | ;;; | 175 | ;;; |
| 178 | ;;; Save <CR> for future reference | 176 | ;;; Save <CR> for future reference |
| 179 | ;;; | 177 | ;;; |
| 180 | (setq tpu-return-seq (read-key-sequence "Hit carriage-return <CR> to continue ")) | ||
| 181 | (cond | 178 | (cond |
| 182 | (tpu-lucid-emacs19-p | 179 | (tpu-lucid-emacs19-p |
| 180 | (setq tpu-return-seq (read-key-sequence "Hit carriage-return <CR> to continue ")) | ||
| 183 | (setq tpu-return (concat "[" (format "%s" (event-key (aref tpu-return-seq 0))) "]"))) | 181 | (setq tpu-return (concat "[" (format "%s" (event-key (aref tpu-return-seq 0))) "]"))) |
| 184 | (t | 182 | (t |
| 185 | (setq tpu-return (format "%s" tpu-return-seq)))) | 183 | (message "Hit carriage-return <CR> to continue ") |
| 184 | (setq tpu-return-seq (read-event)) | ||
| 185 | (setq tpu-return (concat "[" (format "%s" tpu-return-seq) "]")))) | ||
| 186 | 186 | ||
| 187 | 187 | ||
| 188 | ;;; | 188 | ;;; |
| @@ -206,8 +206,9 @@ | |||
| 206 | 206 | ||
| 207 | (defun tpu-gnu-map-key (ident descrip func gold-func) | 207 | (defun tpu-gnu-map-key (ident descrip func gold-func) |
| 208 | (interactive) | 208 | (interactive) |
| 209 | (setq tpu-key-seq (read-key-sequence (format "Press %s%s: " ident descrip))) | 209 | (message "Press %s%s: " ident descrip) |
| 210 | (setq tpu-key (format "%s" tpu-key-seq)) | 210 | (setq tpu-key-seq (read-event)) |
| 211 | (setq tpu-key (concat "[" (format "%s" tpu-key-seq) "]")) | ||
| 211 | (cond ((not (equal tpu-key tpu-return)) | 212 | (cond ((not (equal tpu-key tpu-return)) |
| 212 | (set-buffer "Keys") | 213 | (set-buffer "Keys") |
| 213 | (insert (format"(global-set-key %s %s)\n" tpu-key func)) | 214 | (insert (format"(global-set-key %s %s)\n" tpu-key func)) |
| @@ -348,8 +349,11 @@ | |||
| 348 | ;; | 349 | ;; |
| 349 | ") | 350 | ") |
| 350 | 351 | ||
| 351 | (insert (format "(setq tpu-help-enter \"%s\")\n" tpu-enter-seq)) | 352 | (cond (tpu-lucid-emacs19-p |
| 352 | (insert (format "(setq tpu-help-return \"%s\")\n" tpu-return-seq)) | 353 | (insert (format "(setq tpu-help-enter \"%s\")\n" tpu-enter-seq)) |
| 354 | (insert (format "(setq tpu-help-return \"%s\")\n" tpu-return-seq))) | ||
| 355 | (t | ||
| 356 | (insert (format "(setq tpu-help-enter \"%s\")\n" tpu-enter)))) | ||
| 353 | 357 | ||
| 354 | (append-to-buffer "Keys" 1 (point)) | 358 | (append-to-buffer "Keys" 1 (point)) |
| 355 | (set-buffer "Keys") | 359 | (set-buffer "Keys") |