apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martin Sebor <se...@roguewave.com>
Subject Re: Problem with iconv charsets...
Date Mon, 25 Jun 2007 21:52:39 GMT
William A. Rowe, Jr. wrote:
> William A. Rowe, Jr. wrote:
>> Some thoughts;
>>
>>  * At run-time this should probably be determined by parsing first the
>>    LC_CTYPE, or LC_ALL in it's absense, or the fallback to the LANG
>>    envvar if neither LC_ variable is defined.  The codepage follows
>>    the period, e.g. LANG=en_US.UTF-8 would be parsed as 'UTF-8'.
> 
> FYI - I pondered LC_COLLATE, but it didn't seem to particularly apply.
> 
> The obvious question, if LC_CTYPE specifies a language/no charset, then
> do we drill down to LC_ALL, LANG etc?

The character set of a locale is determined by the LC_CTYPE
category. On POSIX platforms it can be retrieved by passing
the CODESET constant to nl_langinfo().

Martin

Mime
View raw message