boost::unicode::utf_locale_transcoder
// In header: <boost/unicode/utf_codecs.hpp> struct utf_locale_transcoder { // types typedef wchar_t input_type; typedef char output_type; typedef codecvt_out_converter< input_type, output_type >::max_output max_output; // construct/copy/destruct utf_locale_transcoder(std::locale = std::locale(getenv("LANG"))); // public member functions template<typename In, typename Out> Out ltr(In &, In, Out); template<typename In, typename Out> Out rtl(In, In &, Out); std::locale loc; };