1 ;; internal.el -- setup support for PC keyboards and screens, internal terminal
3 ;; Copyright (C) 1993, 1994 Free Software Foundation, Inc.
5 ;; Author: Morten Welinder <terra@diku.dk>
8 ;; This file is part of SXEmacs.
10 ;; SXEmacs is free software: you can redistribute it and/or modify
11 ;; it under the terms of the GNU General Public License as published by
12 ;; the Free Software Foundation, either version 3 of the License, or
13 ;; (at your option) any later version.
15 ;; SXEmacs is distributed in the hope that it will be useful,
16 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
17 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 ;; GNU General Public License for more details.
20 ;; You should have received a copy of the GNU General Public License
21 ;; along with this program. If not, see <http://www.gnu.org/licenses/>.
22 ;; ---------------------------------------------------------------------------
23 ;; screen setup -- that's easy!
24 (standard-display-8bit 127 254)
25 ;; ---------------------------------------------------------------------------
26 ;; keyboard setup -- that's simple!
27 (set-input-mode nil nil 0)
28 (define-key function-key-map [backspace] "\177") ; Normal behavior for BS
29 (define-key function-key-map [delete] "\C-d") ; ... and Delete
30 (define-key function-key-map [tab] [?\t])
31 (define-key function-key-map [linefeed] [?\n])
32 (define-key function-key-map [clear] [11])
33 (define-key function-key-map [return] [13])
34 (define-key function-key-map [escape] [?\e])
35 (define-key function-key-map [M-backspace] [?\M-\d])
36 (define-key function-key-map [M-delete] [?\M-\d])
37 (define-key function-key-map [M-tab] [?\M-\t])
38 (define-key function-key-map [M-linefeed] [?\M-\n])
39 (define-key function-key-map [M-clear] [?\M-\013])
40 (define-key function-key-map [M-return] [?\M-\015])
41 (define-key function-key-map [M-escape] [?\M-\e])
43 ;; ---------------------------------------------------------------------------
44 ;; We want to do this when Emacs is started because it depends on the
49 (modify-syntax-entry ch sy text-mode-syntax-table)
50 (if-boundp 'tex-mode-syntax-table
51 (modify-syntax-entry ch sy tex-mode-syntax-table))
52 (modify-syntax-entry ch sy (standard-syntax-table))
54 (table (standard-case-table))
55 ;; The following are strings of letters, first lower then upper case.
56 ;; This will look funny on terminals which display other code pages.
58 (with-boundp 'dos-codepage
61 "
\87\80\81\9a\82\90\83¶
\84\8e\85·
\86\8fÆÇ µ
\88Ò
\89Ó
\8aÔ
\8bØ
\8c×
\8dÞ¡Ö
\91\92\93â
\94\99\95ã¢à
\9b\9d\96ê£é
\97ë
\98Yìí¡I£é¤¥ÐÑçè")
63 "
\87\80\81\9a\82\90\83A
\84\8e\85A
\86\8f\88E
\89E
\8aE
\8bI
\8cI
\8dI
\91\92\93O
\94\99\95O
\96U£U
\98Y
\9b\9d A¡I¢O£U¤¥")
65 (t "
\87\80\81\9a\82\90\83A
\84\8e\85A
\86\8f\88E
\89E
\8aE
\8bI
\8cI
\8dI
\91\92\93O
\94\99\95O
\96U£U
\98Y A¡I¢O£U¤¥")))))
68 (funcall modify i "_")
72 (while (< i (length chars))
73 (let ((ch1 (aref chars i))
74 (ch2 (aref chars (1+ i))))
76 (declare-fboundp (set-case-syntax-pair ch2 ch1 table)))
79 (mapcar (lambda (b) (set-buffer b) (set-case-table table))
81 (set-standard-case-table table))