emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Better language detection for tutorial


From: Sascha Wilde
Subject: Re: Better language detection for tutorial
Date: Mon, 23 Jul 2007 22:29:16 +0200
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1.50 (gnu/linux)

Eli Zaretskii <address@hidden> wrote:
>> From: Sascha Wilde <address@hidden>
>> Eli Zaretskii <address@hidden> wrote:
>> >> From: Sascha Wilde <address@hidden>
>> >> 
>> >> !                    (or (tutorial-get-language)
>> >> !                        (if (get-language-info 
>> >> current-language-environment 'tutorial)
>> >> !                            current-language-environment
>> >> !                          "English"))))
>> >
>> > I think this is in wrong order: the `tutorial' property of the
>> > language environment should have higher priority than what the new
>> > function `tutorial-get-language' returns.
>> 
>> I highly doubt that, for all my tests (more complex locale setups,
>> that is) the tutorial property of the language environment yields
>> an unexpected (IMO wrong) language.
>
> Please tell the details, then.  It's hard to argue with unspecified
> results of unnamed tests.

Please read my initial mail <address@hidden> for a
complete, real world example.

[...]
> In general, the tutorial property of the language environment should
> be more accurate, since it is specific to Emacs, and specific to the
> situation (i.e., reading the tutorial).  By contrast, the locale
> environment variables are general and not limited to Emacs, so they
> might be wrong for Emacs where general needs conflict with Emacs
> tutorial needs.

The opposite is true: the LC_* environment variables provide a
universal way to define what i18n variant (language, data formatting
etc.) the user wants for specific aspects of applications.

A well behaved application should respect these settings.  But
currently Emacs potentially displays the tutorial in an language
unrelated to LC_MESSAGES, which is not what a user familiar with
locale settings would expect.

>> I haven't checked where and how it is set, but it seems to
>> ignore/misinterpret the LC environment, too.
>
> If by ``it'' you mean the tutorial property,

I do...

> then it does not depend on any environment variables,

which is an bug IMO, unless the user has chosen to set the tutorial
language explicit in Emacs.

> it is set explicitly in the language data base used by Emacs.
[...]

So the tutorial language is set based on the
current-language-environment, which is in turn determined (if not set
explicitly) in a way, disregarding the users choice for ui messages
language.  This is no good.

Making the tutorial property higher priority than my
`tutorial-get-language' would make my patch nearly useless...

cheers
sascha
-- 
Sascha Wilde

A conclusion is simply the place where someone got tired of thinking.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]