On Thu, 25 May 2000, Henry Nelson wrote:

> > > even offer them as choices in a menu.  With NLS you're mostly interested
> > > in TEXTDOMAIN and TEXTDOMAINDIR, not LANG, as I am sure you are aware.
> > 
> > Well, *I* am not aware of that.  Can you explain, please?  Why would
> > you mess with TEXTDOMAIN*, how do you do it, and why is that
> 
> TEXTDOMAINDIR and TEXTDOMAIN are environment variables used by gettext()
> to determine the path to message catalogues and the domain (=language)
> to use.  Essentially it tells gettext() where the *.mo file is.  Thus, you
> can have multiple message catalogues available (e.g., one for regular users
> and another for public-access users, or one for experienced users and one
> for novices) and chose which one to display on the basis of the environment
> variable.

Thank you.  I was vaguely aware that such mechanisms exist, but have never
used them.

> I disagree that LANG should be the major criterion for deciding the message
> catalogue to use.  

The way I see it, if you want to decide based on local vs guest user,
or experienced vs novice user, then use TEXTDOMAIN*.  But if you need
to select a catalogue based on locale (i.e. here: user's language and
character set), then use LANG [*] - that's what it is there for.

In a "standard" installation with NLS, there will only be one valid
TEXTDOMAINDIR and TEXTDOMAINDIR pair, but several possible LANG tags
that correspond to different message catalogues.

[*] More exactly, LC_ALL or LC_MESSAGES or LANG - the way gettext already
does it!

  Klaus


; To UNSUBSCRIBE: Send "unsubscribe lynx-dev" to [EMAIL PROTECTED]

Reply via email to