
On Tue, Aug 9, 2011 at 3:45 AM, Soares Chen Ruo Fei <crf@hypershell.org> wrote:
Currently Boost.Ustr provides limited support towards I/O. Due to portability issues I think it is very hard for Boost.Ustr alone to solve problems such as printing Unicode strings to the screen. In fact, I have no idea on how to print even raw Unicode strings onto the Windows terminal. (Any Windows expert knows how to solve this?)
On Windows, you can use WriteConsoleW() with GetStdHandle(STD_OUTPUT_HANDLE). I have no clue how this will behave if your stdlib buffers output. In VC++ specifically (2005 and up) you can do _setmode(_fileno(stdout), _O_U16TEXT), and wprintf() and wcout will behave properly for all Unicode text. You still need to set the console's font to one supporting Unicode glyphs, though. -- Cory Nelson http://int64.org