Mercurial > emacs
comparison lisp/term/wyse50.el @ 64651:af1c58687bdd
* term/apollo.el (terminal-init-apollo): New function containing
all former top level forms in the file.
* term/bobcat.el (terminal-init-bobcat):
* term/cygwin.el (terminal-init-cygwin):
* term/iris-ansi.el (terminal-init-iris-ansi):
* term/linux.el (terminal-init-linux):
* term/news.el (terminal-init-news):
* term/rxvt.el (terminal-init-rxvt):
* term/sun.el (terminal-init-sun):
* term/tvi970.el (terminal-init-tvi970):
* term/vt100.el (terminal-init-vt100):
* term/vt102.el (terminal-init-vt102):
* term/vt125.el (terminal-init-vt125):
* term/vt200.el (terminal-init-vt200):
* term/vt201.el (terminal-init-vt201):
* term/vt220.el (terminal-init-vt220):
* term/vt240.el (terminal-init-vt240):
* term/vt300.el (terminal-init-vt300):
* term/vt320.el (terminal-init-vt320):
* term/vt400.el (terminal-init-vt400):
* term/vt420.el (terminal-init-vt420):
* term/wyse50.el (terminal-init-wyse50):
* term/xterm.el (terminal-init-xterm): Likewise.
* term/README: Describe the terminal-init-* functionality.
* startup.el (command-line): After loading the terminal
initialization file call the corresponding terminal initialization
function.
author | Dan Nicolaescu <dann@ics.uci.edu> |
---|---|
date | Wed, 27 Jul 2005 18:02:08 +0000 |
parents | a8fa7c632ee4 |
children | 34bd8e434dd7 890cc78a5a24 |
comparison
equal
deleted
inserted
replaced
64650:82d9ac62ed1d | 64651:af1c58687bdd |
---|---|
1 ;;; wyse50.el --- terminal support code for Wyse 50 -*- no-byte-compile: t -*- | 1 ;;; wyse50.el --- terminal support code for Wyse 50 -*- no-byte-compile: t -*- |
2 | 2 |
3 ;; Copyright (C) 1989, 1993, 1994 Free Software Foundation, Inc. | 3 ;; Copyright (C) 1989, 1993, 1994, 2005 Free Software Foundation, Inc. |
4 | 4 |
5 ;; Author: Daniel Pfeiffer <occitan@esperanto.org>, | 5 ;; Author: Daniel Pfeiffer <occitan@esperanto.org>, |
6 ;; Jim Blandy <jimb@occs.cs.oberlin.edu> | 6 ;; Jim Blandy <jimb@occs.cs.oberlin.edu> |
7 ;; Keywords: terminals | 7 ;; Keywords: terminals |
8 | 8 |
35 ;; feed (!!). Thus, you have to unbind some commonly-used Emacs keys to | 35 ;; feed (!!). Thus, you have to unbind some commonly-used Emacs keys to |
36 ;; enable the arrows. | 36 ;; enable the arrows. |
37 | 37 |
38 ;;; Code: | 38 ;;; Code: |
39 | 39 |
40 (define-key function-key-map "\C-a" (make-keymap)) | 40 (defun terminal-init-wyse50 () |
41 (mapcar (function (lambda (key-definition) | 41 "Terminal initialization function for wyse50." |
42 (define-key function-key-map | 42 (define-key function-key-map "\C-a" (make-keymap)) |
43 (car key-definition) (nth 1 key-definition)))) | 43 (mapcar (function (lambda (key-definition) |
44 '( | 44 (define-key function-key-map |
45 ;; These might be set up by termcap and terminfo | 45 (car key-definition) (nth 1 key-definition)))) |
46 ("\C-k" [up]) | 46 '( |
47 ("\C-j" [down]) | 47 ;; These might be set up by termcap and terminfo |
48 ("\C-l" [right]) | 48 ("\C-k" [up]) |
49 ("\C-h" [left]) | 49 ("\C-j" [down]) |
50 ("\^a@\^m" [f1]) | 50 ("\C-l" [right]) |
51 ("\^aA\^m" [f2]) | 51 ("\C-h" [left]) |
52 ("\^aB\^m" [f3]) | 52 ("\^a@\^m" [f1]) |
53 ("\^aC\^m" [f4]) | 53 ("\^aA\^m" [f2]) |
54 ("\^aD\^m" [f5]) | 54 ("\^aB\^m" [f3]) |
55 ("\^aE\^m" [f6]) | 55 ("\^aC\^m" [f4]) |
56 ("\^aF\^m" [f7]) | 56 ("\^aD\^m" [f5]) |
57 ("\^aG\^m" [f8]) | 57 ("\^aE\^m" [f6]) |
58 ("\^aH\^m" [f9]) | 58 ("\^aF\^m" [f7]) |
59 ("\^aG\^m" [f8]) | |
60 ("\^aH\^m" [f9]) | |
59 | 61 |
60 ;; These might be set up by terminfo | 62 ;; These might be set up by terminfo |
61 ("\eK" [next]) | 63 ("\eK" [next]) |
62 ("\eT" [clearline]) | 64 ("\eT" [clearline]) |
63 ("\^^" [home]) | 65 ("\^^" [home]) |
64 ("\e\^^" [end]) | 66 ("\e\^^" [end]) |
65 ("\eQ" [insert]) | 67 ("\eQ" [insert]) |
66 ("\eE" [insertline]) | 68 ("\eE" [insertline]) |
67 ("\eR" [deleteline]) | 69 ("\eR" [deleteline]) |
68 ("\eP" [print]) | 70 ("\eP" [print]) |
69 ("\er" [replace]) | 71 ("\er" [replace]) |
70 ("\^aI\^m" [f10]) | 72 ("\^aI\^m" [f10]) |
71 ("\^aJ\^m" [f11]) | 73 ("\^aJ\^m" [f11]) |
72 ("\^aK\^m" [f12]) | 74 ("\^aK\^m" [f12]) |
73 ("\^aL\^m" [f13]) | 75 ("\^aL\^m" [f13]) |
74 ("\^aM\^m" [f14]) | 76 ("\^aM\^m" [f14]) |
75 ("\^aN\^m" [f15]) | 77 ("\^aN\^m" [f15]) |
76 ("\^aO\^m" [f16]) | 78 ("\^aO\^m" [f16]) |
77 ("\^a`\^m" [f17]) | 79 ("\^a`\^m" [f17]) |
78 ("\^aa\^m" [f18]) | 80 ("\^aa\^m" [f18]) |
79 ("\^ab\^m" [f19]) | 81 ("\^ab\^m" [f19]) |
80 ("\^ac\^m" [f20]) | 82 ("\^ac\^m" [f20]) |
81 ("\^ad\^m" [f21]) | 83 ("\^ad\^m" [f21]) |
82 ("\^ae\^m" [f22]) | 84 ("\^ae\^m" [f22]) |
83 ("\^af\^m" [f23]) | 85 ("\^af\^m" [f23]) |
84 ("\^ag\^m" [f24]) | 86 ("\^ag\^m" [f24]) |
85 ("\^ah\^m" [f25]) | 87 ("\^ah\^m" [f25]) |
86 ("\^ai\^m" [f26]) | 88 ("\^ai\^m" [f26]) |
87 ("\^aj\^m" [f27]) | 89 ("\^aj\^m" [f27]) |
88 ("\^ak\^m" [f28]) | 90 ("\^ak\^m" [f28]) |
89 ("\^al\^m" [f29]) | 91 ("\^al\^m" [f29]) |
90 ("\^am\^m" [f30]) | 92 ("\^am\^m" [f30]) |
91 ("\^an\^m" [f31]) | 93 ("\^an\^m" [f31]) |
92 ("\^ao\^m" [f32]) | 94 ("\^ao\^m" [f32]) |
93 | 95 |
94 ;; Terminfo may know about these, but X won't | 96 ;; Terminfo may know about these, but X won't |
95 ("\eI" [key-stab]) ;; Not an X keysym | 97 ("\eI" [key-stab]) ;; Not an X keysym |
96 ("\eJ" [key-snext]) ;; Not an X keysym | 98 ("\eJ" [key-snext]) ;; Not an X keysym |
97 ("\eY" [key-clear]) ;; Not an X keysym | 99 ("\eY" [key-clear]) ;; Not an X keysym |
98 | 100 |
99 ;; These are totally strange :-) | 101 ;; These are totally strange :-) |
100 ("\eW" [?\C-?]) ;; Not an X keysym | 102 ("\eW" [?\C-?]) ;; Not an X keysym |
101 ("\^a\^k\^m" [funct-up]) ;; Not an X keysym | 103 ("\^a\^k\^m" [funct-up]) ;; Not an X keysym |
102 ("\^a\^j\^m" [funct-down]) ;; Not an X keysym | 104 ("\^a\^j\^m" [funct-down]) ;; Not an X keysym |
103 ("\^a\^l\^m" [funct-right]) ;; Not an X keysym | 105 ("\^a\^l\^m" [funct-right]) ;; Not an X keysym |
104 ("\^a\^h\^m" [funct-left]) ;; Not an X keysym | 106 ("\^a\^h\^m" [funct-left]) ;; Not an X keysym |
105 ("\^a\^m\^m" [funct-return]) ;; Not an X keysym | 107 ("\^a\^m\^m" [funct-return]) ;; Not an X keysym |
106 ("\^a\^i\^m" [funct-tab]) ;; Not an X keysym | 108 ("\^a\^i\^m" [funct-tab]) ;; Not an X keysym |
107 )) | 109 )) |
110 | |
111 ;; Miscellaneous hacks | |
112 | |
113 ;; This is an ugly hack for a nasty problem: | |
114 ;; Wyse 50 takes one character cell to store video attributes (which seems to | |
115 ;; explain width 79 rather than 80, column 1 is not used!!!). | |
116 ;; On killing (C-x C-c) the end inverse code (on column 1 of line 24) | |
117 ;; of the mode line is overwritten AFTER all the y-or-n questions. | |
118 ;; This causes the attribute to remain in effect until the mode line has | |
119 ;; scrolled of the screen. Suspending (C-z) does not cause this problem. | |
120 ;; On such terminals, Emacs should sacrifice the first and last character of | |
121 ;; each mode line, rather than a whole screen column! | |
122 (add-hook 'kill-emacs-hook | |
123 (function (lambda () (interactive) | |
124 (send-string-to-terminal | |
125 (concat "\ea23R" (1+ (frame-width)) "C\eG0")))))) | |
108 | 126 |
109 (defun enable-arrow-keys () | 127 (defun enable-arrow-keys () |
110 "To be called by term-setup-hook. Overrides 6 Emacs standard keys | 128 "To be called by term-setup-hook. Overrides 6 Emacs standard keys |
111 whose functions are then typed as follows: | 129 whose functions are then typed as follows: |
112 C-a Funct Left-arrow | 130 C-a Funct Left-arrow |
129 ("\C-l" nil) | 147 ("\C-l" nil) |
130 ("\C-h" nil) | 148 ("\C-h" nil) |
131 ("\er" nil))) | 149 ("\er" nil))) |
132 (fset 'enable-arrow-keys nil)) | 150 (fset 'enable-arrow-keys nil)) |
133 | 151 |
134 | |
135 ;;; Miscellaneous hacks | |
136 | |
137 ;;; This is an ugly hack for a nasty problem: | |
138 ;;; Wyse 50 takes one character cell to store video attributes (which seems to | |
139 ;;; explain width 79 rather than 80, column 1 is not used!!!). | |
140 ;;; On killing (C-x C-c) the end inverse code (on column 1 of line 24) | |
141 ;;; of the mode line is overwritten AFTER all the y-or-n questions. | |
142 ;;; This causes the attribute to remain in effect until the mode line has | |
143 ;;; scrolled of the screen. Suspending (C-z) does not cause this problem. | |
144 ;;; On such terminals, Emacs should sacrifice the first and last character of | |
145 ;;; each mode line, rather than a whole screen column! | |
146 (add-hook 'kill-emacs-hook | |
147 (function (lambda () (interactive) | |
148 (send-string-to-terminal | |
149 (concat "\ea23R" (1+ (frame-width)) "C\eG0"))))) | |
150 | |
151 ;;; arch-tag: b6a05d37-eead-4cf6-b997-0f956c68881c | 152 ;;; arch-tag: b6a05d37-eead-4cf6-b997-0f956c68881c |
152 ;;; wyse50.el ends here | 153 ;;; wyse50.el ends here |