This is the mail archive of the
glibc-linux@ricardo.ecn.wfu.edu
mailing list for the glibc project.
Re: charset for a locale
On Sun, Feb 25, 2001 at 05:28:59PM +0100, Andreas Jaeger wrote:
> #include <langinfo.h>
>
> ...
> prinf ("%s\n", nl_langinfo(CODESET));
> ...
>
Thank you! FWIW, CODESET is not documented in the main GNU libc 2.2
documentation for nl_langinfo, but it is mentioned in the gettext
documentation. Also, the nl_langinfo documentation says
in addition to the numeric and monetary formatting information,
information from the `LC_TIME' and `LC_MESSAGES' categories is
available.
with no mention of LC_CTYPE data.
Thanks again,
Andrew
PS. It would be convenient if a "--long" option to locale(1) would
dump these details. Or perhaps there should be a separate command
interface to nl_langinfo.