Mercurial > emacs
comparison lisp/international/mule.el @ 34688:8f397d03b992
(set-keyboard-coding-system): Doc fix.
(keyboard-coding-system): New option.
author | Dave Love <fx@gnu.org> |
---|---|
date | Mon, 18 Dec 2000 17:10:08 +0000 |
parents | 8fffee49b42e |
children | 31e8fba26248 |
comparison
equal
deleted
inserted
replaced
34687:48e5a31a2ff0 | 34688:8f397d03b992 |
---|---|
991 See also the command `set-keyboard-coding-system'.") | 991 See also the command `set-keyboard-coding-system'.") |
992 | 992 |
993 (defun set-keyboard-coding-system (coding-system) | 993 (defun set-keyboard-coding-system (coding-system) |
994 "Set coding system for keyboard input to CODING-SYSTEM. | 994 "Set coding system for keyboard input to CODING-SYSTEM. |
995 In addition, this command enables Encoded-kbd minor mode. | 995 In addition, this command enables Encoded-kbd minor mode. |
996 \(If CODING-SYSTEM is nil, Encoded-kbd mode is turned off.) | 996 \(If CODING-SYSTEM is nil, Encoded-kbd mode is turned off -- see |
997 `encoded-kbd-mode'.) | |
997 For a list of possible values of CODING-SYSTEM, use \\[list-coding-systems]. | 998 For a list of possible values of CODING-SYSTEM, use \\[list-coding-systems]. |
998 The default is determined by the selected language environment | 999 The default is determined by the selected language environment |
999 or by the previous use of this command." | 1000 or by the previous use of this command." |
1000 (interactive | 1001 (interactive |
1001 (list (let ((default (if (and (not (keyboard-coding-system)) | 1002 (list (let ((default (if (and (not (keyboard-coding-system)) |
1010 (setq coding-system default-keyboard-coding-system)) | 1011 (setq coding-system default-keyboard-coding-system)) |
1011 (if coding-system | 1012 (if coding-system |
1012 (setq default-keyboard-coding-system coding-system)) | 1013 (setq default-keyboard-coding-system coding-system)) |
1013 (set-keyboard-coding-system-internal coding-system) | 1014 (set-keyboard-coding-system-internal coding-system) |
1014 (encoded-kbd-mode (if coding-system 1 0))) | 1015 (encoded-kbd-mode (if coding-system 1 0))) |
1016 | |
1017 (defcustom keyboard-coding-system nil | |
1018 "Specify coding system for keyboard input. | |
1019 If you set this on a terminal which can't distinguish Meta keys from | |
1020 8-bit characters, you will have to use ESC to type Meta characters. | |
1021 See Info node `Specify Coding' and Info node `Single-Byte Character Support'. | |
1022 | |
1023 Setting this variable directly does not take effect; | |
1024 use either M-x customize or \\[set-keyboard-coding-system]." | |
1025 :type '(coding-system :tag "Coding system") | |
1026 :link '(info-link "(emacs)Specify Coding") | |
1027 :link '(info-link "(emacs)Single-Byte Character Support") | |
1028 :set (lambda (symbol value) | |
1029 ;; Don't load encoded-kbd-mode unnecessarily. | |
1030 (if (or value (boundp 'encoded-kbd-mode)) | |
1031 (set-keyboard-coding-system value) | |
1032 (set-default 'keyboard-coding-system nil))) ; must initialize | |
1033 :version "21.1" | |
1034 :group 'keyboard | |
1035 :group 'mule) | |
1015 | 1036 |
1016 (defun set-buffer-process-coding-system (decoding encoding) | 1037 (defun set-buffer-process-coding-system (decoding encoding) |
1017 "Set coding systems for the process associated with the current buffer. | 1038 "Set coding systems for the process associated with the current buffer. |
1018 DECODING is the coding system to be used to decode input from the process, | 1039 DECODING is the coding system to be used to decode input from the process, |
1019 ENCODING is the coding system to be used to encode output to the process. | 1040 ENCODING is the coding system to be used to encode output to the process. |