From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: AIDA Shinra Newsgroups: gmane.emacs.devel Subject: Re: Feature request: multibyte user-full-name Date: Tue, 14 Mar 2006 12:18:14 +0900 Message-ID: References: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII X-Trace: sea.gmane.org 1142306471 27356 80.91.229.2 (14 Mar 2006 03:21:11 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 14 Mar 2006 03:21:11 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Mar 14 04:21:01 2006 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1FJ03Y-0000bN-IW for ged-emacs-devel@m.gmane.org; Tue, 14 Mar 2006 04:18:44 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FJ03X-0003NQ-VW for ged-emacs-devel@m.gmane.org; Mon, 13 Mar 2006 22:18:44 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1FJ03M-0003ND-RH for emacs-devel@gnu.org; Mon, 13 Mar 2006 22:18:32 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1FJ03K-0003N1-O5 for emacs-devel@gnu.org; Mon, 13 Mar 2006 22:18:32 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FJ03K-0003My-IY for emacs-devel@gnu.org; Mon, 13 Mar 2006 22:18:30 -0500 Original-Received: from [203.141.155.228] (helo=mx-old.j10n.org) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA:32) (Exim 4.52) id 1FJ07Q-0004Ro-Rs for emacs-devel@gnu.org; Mon, 13 Mar 2006 22:22:45 -0500 Original-Received: from korea.j10n.org.j10n.org (korea.j10n.org [IPv6:2002:cb8d:9be4:1:203:93ff:feef:5060]) (authenticated bits=0) by mx-old.j10n.org (8.13.1/8.13.1) with ESMTP id k2E3IEWl004677 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 14 Mar 2006 12:18:20 +0900 (JST) (envelope-from shinra@j10n.org) Original-To: Kenichi Handa In-Reply-To: User-Agent: Wanderlust/2.12.2 (99 Luftballons) SEMI/1.14.6 (Maruoka) FLIM/1.14.7 (=?ISO-8859-4?Q?Sanj=F2?=) APEL/10.6 MULE XEmacs/21.4 (patch 17) (Jumbo Shrimp) (powerpc-apple-darwin7.8.0) 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:51586 Archived-At: > > Hello, > > user-full-name might contain non-ASCII characters. For example, > > pw_gecos is encoded in UTF-8 on Darwin. > > > No technical problems exist except in which coding system should Emacs > > decode the username. We have three options: > > > 1. Introduce something like directory-system-coding-system and guess > > it in set-locale-environment. > > > 2. Apply file-name-coding-system and pray that it works. > > > 3. Hardcode for each platform. > > Why do you think that pw_gecos is related to something like > directory or file name? About 1: "directory system" is my miswording. I meant "directory service". About 2: *Pray* that an operating system and/or administrator adopt the same encoding. > Anyway, as far as a system allows users to switch locale, I > think, pw_gecos must adopt locale-independent encoding, thus > the possible encoding is one of UTF-*. And, considering > backward compatibility, it should be UTF-8. Then, how about > we always decode it by utf-8 (only if it contains a byte > with MSB set) while falling back to locale-coding-system > (invalid utf-8 sequence is found), and see if that works on > any systems? How does GNU/Linux encode it? A site administrator might choose an encoding other than UTF-8 even if it is locale-dependent... > By the way, does the mis-decoding of user-full-name lead to > any serious error? I can't determine your "serious" means but user-full-name is widely used anyway.