I need a good Unicode library for C++. I need:
As far as I know the best library is ICU. However, I can't find normal developer friendly API documentation with examples. Also as far as I see, it is not too friendly with modern C++ design, work with STL and so on. Like this:
std::string msg;
unistring umsg.from_utf8(msg);
unistring::word_iterator wi;
for(wi=umsg.words().begin(),n=0;wi!=usmg.words().wi_end(),n<10;++wi,++n)
;
msg=umsg.substr(umsg.words().begin(),wi).to_utf8();
cout<<_("Five 10 words are ")<<msg;
Is there a good STL friendly ICU wrapper released under Open Source license? Preferred is a license permissive like MIT or Boost, but others, like LGPLv2 compatible, are OK as well.
Is there another high quality library similar to ICU?
Platform: Unix/POSIX, Windows support is not required.
Edit: unfortunately I wasn't logged in, so I can't make accept an answer. I have attached the answer by myself.
This question was asked quite a long time before by myself. There was no such library.
So I had written C++ friendly Boost.Locale library that wraps ICU.
Edit Now part of Boost: see Boost.Locale documentation
The wxWidgets GUI toolkit has some rather nice string classes and unicode support. You don't need to build/use GUI classes if you don't want to. See here for details.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With