Lars Gullik Bjønnes <[EMAIL PROTECTED]> writes: > | | Can't we use std::basic_string<char_type>? > | Only if you create the proper char_traits<char_type>. > Except on Linux (and others, but not win) where wstring really is a > basic_string<ucs-4> (ucs-4 == wchar_t)
You mean wchar_t == uint32? UCS-4 is the encoding, no? > So perhaps we can use that, and have a fallback on platforms where > wchar_t is 16bit. Do it the same way on all platforms; let's have no second class citizens. Anyway, your answer raises the question: why not "borrow" the linux gcc char_traits<uint32> implementation and use that on Windows? typedef boost::uint32 lyx::char_type; #ifdef _WIN32 // native Windows, Cygwin typedef borrowed_gcc_char_traits<lyx::char_type> lyx::uchar_traits; #else if defined POSIX // Linux, Mac, other *nixes. typedef std::char_traits<lyx::char_type> lyx::uchar_traits; #endif typedef std::basic_string<lyx::char_type, lyx::uchar_traits> lyx::ustring; What do I miss? Angus