[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: UTF-8 curses
On Tue, 26 Oct 1999, Bruno Haible wrote:
> Edmund Grimley Evans writes:
> > Unfortunately, mbtowc and wctomb use a locale-dependent multibyte
> > representation, which is no good for processing e-mail, and I probably
> > don't want to reset the locale, either. Never mind, I can reimplement
> > those functions anyway.
>
> I'd suggest one of the following approaches:
>
> - Do a setlocale(LC_CTYPE,"en_US.UTF-8") once and for all at the start
> of your program. You can then assume that mbtowc/wctomb deals with
> UTF-8 and Unicode, and use iconv to get the data into that format.
> But this will likely not work well if you use curses, because it
> will trick curses into thinking it were running in an UTF-8 xterm,
> when in fact it is not.
Why would a curses be tricked into thinking such a thing? Are there
know curses implementations that act that way? Is that required by
some standard that a curses has to react that way?
Also, UTF-8 environment != UTF-8 xterm.
Klaus
-
Linux-UTF8: i18n of Linux on all levels
Archive: http://mail.nl.linux.org/lists/