From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: =?UTF-8?B?SmFuIERqw6Rydg==?= Newsgroups: gmane.emacs.devel Subject: Re: set-locale-environement: strange default detection Date: Wed, 18 Jul 2007 13:04:42 +0200 Message-ID: <469DF3CA.4040704@swipnet.se> References: <867ioynheb.fsf@lola.quinscape.zz> <86ps2qm1de.fsf@lola.quinscape.zz> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: sea.gmane.org 1184756761 13837 80.91.229.12 (18 Jul 2007 11:06:01 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 18 Jul 2007 11:06:01 +0000 (UTC) Cc: Sascha Wilde , Thomas Arendsen Hein , emacs-devel@gnu.org To: David Kastrup Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Jul 18 13:05:50 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1IB7LG-0001Sg-4I for ged-emacs-devel@m.gmane.org; Wed, 18 Jul 2007 13:05:44 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IB7LF-0002nm-MC for ged-emacs-devel@m.gmane.org; Wed, 18 Jul 2007 07:05:13 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IB7LB-0002lO-Lw for emacs-devel@gnu.org; Wed, 18 Jul 2007 07:05:09 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IB7L9-0002ja-Hx for emacs-devel@gnu.org; Wed, 18 Jul 2007 07:05:09 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IB7L9-0002jJ-Dd for emacs-devel@gnu.org; Wed, 18 Jul 2007 07:05:07 -0400 Original-Received: from av10-1-sn2.hy.skanova.net ([81.228.8.181]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1IB7L8-0003iA-NN for emacs-devel@gnu.org; Wed, 18 Jul 2007 07:05:06 -0400 Original-Received: by av10-1-sn2.hy.skanova.net (Postfix, from userid 502) id C99C137E86; Wed, 18 Jul 2007 13:05:05 +0200 (CEST) Original-Received: from smtp4-1-sn2.hy.skanova.net (smtp4-1-sn2.hy.skanova.net [81.228.8.92]) by av10-1-sn2.hy.skanova.net (Postfix) with ESMTP id 98FA137E50; Wed, 18 Jul 2007 13:05:05 +0200 (CEST) Original-Received: from husetbladh.homeip.net (81-235-205-78-no59.tbcn.telia.com [81.235.205.78]) by smtp4-1-sn2.hy.skanova.net (Postfix) with ESMTP id 677C637E45; Wed, 18 Jul 2007 13:05:05 +0200 (CEST) User-Agent: Thunderbird 1.5.0.12 (X11/20070604) In-Reply-To: <86ps2qm1de.fsf@lola.quinscape.zz> X-detected-kernel: Linux 2.4-2.6 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:75057 Archived-At: David Kastrup skrev: > Sascha Wilde writes: >=20 >> David Kastrup wrote: >>> Sascha Wilde writes: >>>> a friend of mine (unfortunately a vim user, but a nice guy otherwise= ), >>>> tried emacs on Gnu/Linux and was surprised that `C-h t' presented hi= m >>>> the German version of the tutorial. >> [...] >>> The problem is that we don't have finegrained support. For the >>> purpose of talking to the user, LC_MESSAGES is relevant. But Emacs s= o >>> rarely has the opportunity to talk anything but English to the user >>> that we simply have no reasonable interface into this for now. >> So maybe we should check for LANG, LC_ALL and maybe LC_MESSAGES in >> tutorial.el itself. >=20 > Possibly. I am not sure whether environment variables tell the whole > story, and in a readable way (there are locale system calls, too), but > they would probably cover 90% of the cases. >=20 The locale man page says the order should be LC_ALL, LC_MESSAGES, LANG: 1. If there is a non-null environment variable LC_ALL, the val= ue of LC_ALL is used. 2. If an environment variable with the same name as one of the= cat=E2=80=90 egories above exists and is non-null, its value is used for= that category. 3. If there is a non-null environment variable LANG, the valu= e of LANG is used. Jan D.