]> git.eshelyaron.com Git - emacs.git/commitdiff
(set-language-environment): Fix previous change.
authorRichard M. Stallman <rms@gnu.org>
Thu, 30 Apr 1998 03:20:24 +0000 (03:20 +0000)
committerRichard M. Stallman <rms@gnu.org>
Thu, 30 Apr 1998 03:20:24 +0000 (03:20 +0000)
Call standard-display-european-internal.
Call set-terminal-coding-system.

(standard-display-european-internal): New subroutine.

lisp/international/mule-cmds.el

index e0c4145ce45db3f75a222399bd46d1d0b53ddae2..ca5367d94188b798bae388a3233d0a49ce4585a2 100644 (file)
@@ -843,10 +843,12 @@ specifies the character set for the major languages of Western Europe."
   (if (null (get-language-info language-name 'setup-function))
       (error "Language environment not defined: %S" language-name))
   (unless default-enable-multibyte-characters
-    (or (member (downcase language)
+    (or (member (downcase language-name)
                '("latin-1" "latin-2" "latin-3" "latin-4" "latin-5"))
-       (error "Language environment `%s' not supported in unibyte mode"))
-    (standard-display-european 1 (downcase language)))
+       (error "Language environment `%s' not supported in unibyte mode"
+              language-name))
+    (set-terminal-coding-system (intern (downcase language-name)))
+    (standard-display-european-internal))
 
   (if current-language-environment
       (let ((func (get-language-info current-language-environment
@@ -858,6 +860,17 @@ specifies the character set for the major languages of Western Europe."
   (run-hooks 'set-language-environment-hook)
   (force-mode-line-update t))
 
+(defun standard-display-european-internal ()
+  ;; Actually set up direct output of non-ASCII characters.
+  (standard-display-8bit 160 255)
+  ;; Make non-line-break space display as a plain space.
+  ;; Most X fonts do the wrong thing for code 160.
+  (aset standard-display-table 160 [32])
+  ;; Most Windows programs send out apostrophe's as \222.  Most X fonts
+  ;; don't contain a character at that position.  Map it to the ASCII
+  ;; apostrophe.
+  (aset standard-display-table 146 [39]))
+
 (defun set-language-environment-coding-systems (language-name)
   "Do various coding system setups for language environment LANGUAGE-NAME."
   (let* ((priority (get-language-info language-name 'coding-priority))