Markus Kuhn writes:
> I'd like to have in some standard tool a function that looks at
> nl_langinfo(CODESET) and then sends out the corresponding ISO 2022
> sequence to make sure the terminal knaows about the encoding of the
> current locale.

You can't have that. Why? All ISO 2022 escape sequences must be
registered at the ISO-IR registry. But some widely used encodings,
such as BIG5, BIG5HKSCS, GB18030, CP1251, are not ISO standardized and
thus have no such escape sequence.

H. Peter Anvin writes:

> What I would suggest is that any such API extensions we find are
> necessary should go into a library (libcharset, or something like
> that) which is independent from glibc (so people can use it without
> needing to upgrade glibc).

It already exists.
  ftp://ftp.ilog.fr/pub/Users/haible/gnu/libcharset-1.0.tar.gz
This library is also contained in GNU libiconv.

Bruno
-
Linux-UTF8:   i18n of Linux on all levels
Archive:      http://mail.nl.linux.org/lists/

Reply via email to