B
Bren
Hi all,
I wonder if anyone knows of a string class out there that can do on
demand conversion from wchar_t to char?
We are writing an app that will need to be localized and cross
platform. At this point we are going with Unicode and wchar_t arrays.
I am considering using the string class.
We also use a lot of third party libraries, most of which prefer
ordinary char arrays.
I am hoping to find a class or macro that can do in-place conversion
of wchar_t to char arrays, ideally something similar to the MS W2A/A2W
macros. A string class that could accept/manage a wchar_t string and
return a char* with a call similar to c_str() would also be great as
well.
We are currently using a function which accepts a char* to an
allocated string and converts a wchar_t string into it, but this
requires code before (to alloc) and after (to free) every call. I'm
hoping for something a little easier to use.
Any suggestions?
I wonder if anyone knows of a string class out there that can do on
demand conversion from wchar_t to char?
We are writing an app that will need to be localized and cross
platform. At this point we are going with Unicode and wchar_t arrays.
I am considering using the string class.
We also use a lot of third party libraries, most of which prefer
ordinary char arrays.
I am hoping to find a class or macro that can do in-place conversion
of wchar_t to char arrays, ideally something similar to the MS W2A/A2W
macros. A string class that could accept/manage a wchar_t string and
return a char* with a call similar to c_str() would also be great as
well.
We are currently using a function which accepts a char* to an
allocated string and converts a wchar_t string into it, but this
requires code before (to alloc) and after (to free) every call. I'm
hoping for something a little easier to use.
Any suggestions?