From: Doug Ewell (doug@ewellic.org)
Date: Wed Aug 27 2008 - 22:08:21 CDT
"Unknown Umut" <js underscore bach at freenet dot de> wrote:
> I am trying to print utf-8 strings with colors in ansi-c with help of
> wchar.h and friends. I get any language(japanese, german etc), no
> problem but not in colored. The ansi color notation that i am used to,
> \033[0;34m
> \033[0;35m
> doesn't work with unicode( in wprintf). Now my question is,
> as the coding of colors in ansi consist of characters whose decimal
> value less than 255 and unicode backward-compatible is, why would my
> wprintf attempts fail?
It shouldn't make any difference, as you said (though the magic value is
128 and not 255).
Just out of curiosity, what operating environment are you working in?
Modern versions of Windows, for example, don't seem to honor ANSI X3.64
escape codes even if you use ANSI.SYS. I wanted to do this in XP and
ended up writing a utility that does all the emulation.
-- Doug Ewell * Thornton, Colorado, USA * RFC 4645 * UTN #14 http://www.ewellic.org http://www1.ietf.org/html.charters/ltru-charter.html http://www.alvestrand.no/mailman/listinfo/ietf-languages ˆ
This archive was generated by hypermail 2.1.5 : Wed Aug 27 2008 - 22:11:38 CDT