From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Kenichi Handa Newsgroups: gmane.emacs.devel Subject: Re: Emacs, Chinese language environment, and Japanese fonts Date: Thu, 15 Sep 2005 12:52:36 +0900 Message-ID: References: <87psrb9xhj.fsf@pacem.orebokech.com> <8eae5a660509141954430abc8f@mail.gmail.com> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 (generated by SEMI 1.14.3 - "Ushinoya") Content-Type: text/plain; charset=US-ASCII X-Trace: sea.gmane.org 1126757411 29036 80.91.229.2 (15 Sep 2005 04:10:11 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 15 Sep 2005 04:10:11 +0000 (UTC) Cc: romain@orebokech.com, emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Sep 15 06:10:09 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1EFl4S-0006eV-Vb for ged-emacs-devel@m.gmane.org; Thu, 15 Sep 2005 06:10:01 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1EFl4S-0001eb-30 for ged-emacs-devel@m.gmane.org; Thu, 15 Sep 2005 00:10:00 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1EFl1S-0007qs-OZ for emacs-devel@gnu.org; Thu, 15 Sep 2005 00:06:54 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1EFl1N-0007no-Ne for emacs-devel@gnu.org; Thu, 15 Sep 2005 00:06:50 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1EFl1M-0007nU-V1 for emacs-devel@gnu.org; Thu, 15 Sep 2005 00:06:49 -0400 Original-Received: from [192.47.44.130] (helo=tsukuba.m17n.org) by monty-python.gnu.org with esmtp (TLS-1.0:DHE_RSA_3DES_EDE_CBC_SHA:24) (Exim 4.34) id 1EFl1H-0004cM-DF for emacs-devel@gnu.org; Thu, 15 Sep 2005 00:06:44 -0400 Original-Received: from nfs.m17n.org (nfs.m17n.org [192.47.44.7]) by tsukuba.m17n.org (8.13.4/8.13.4/Debian-3) with ESMTP id j8F3qbXp023122; Thu, 15 Sep 2005 12:52:37 +0900 Original-Received: from etlken (etlken.m17n.org [192.47.44.125]) by nfs.m17n.org (8.13.4/8.13.4/Debian-3) with ESMTP id j8F3qbB1011551; Thu, 15 Sep 2005 12:52:37 +0900 Original-Received: from handa by etlken with local (Exim 3.36 #1 (Debian)) id 1EFknc-0000vv-00; Thu, 15 Sep 2005 12:52:36 +0900 Original-To: lidaobing@gmail.com In-reply-to: <8eae5a660509141954430abc8f@mail.gmail.com> (message from LI Daobing on Thu, 15 Sep 2005 10:54:42 +0800) User-Agent: SEMI/1.14.3 (Ushinoya) FLIM/1.14.2 (Yagi-Nishiguchi) APEL/10.2 Emacs/22.0.50 (i686-pc-linux-gnu) MULE/5.0 (SAKAKI) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:42946 Archived-At: In article <8eae5a660509141954430abc8f@mail.gmail.com>, LI Daobing writes: > I am very glad to reproduce this bug to you: > my env: > locale: LANG=en_US.UTF-8 > emacs-snapshot: emacs-snapshot-gtk in debian version 1:20050908-1 As your locale is en_US.UTF-8, Emacs doen't know to which charset to decode that character from UTF-8. The default is to prefer JIS. If you prefer Chinese, why don't you use, for instance, zh_CN.UTF-8? By the way, you wrote: > I prefer it is bug, becase this bug still happen even when I use > (set-language-environment "Chinese-GB"). You must change the lang. env. before you read a UTF-8 file. Have you tried it? I agree that it's not good that saving and reading with the same coding system doesn't give you the same character. But, that is the limitation of the current Emacs, and can't be solved easily. If you really have to be in English language environment but prefer Chinese, please try this in your .emacs. (set-language-environment "Chinese-GB") (set-language-environment "English") --- Kenichi Handa handa@m17n.org