Discussion:
wxTextFile and Unicode
(too old to reply)
Joachim Wiesemann
2009-12-29 10:02:22 UTC
Permalink
Hi,

I want to create and write a wxTextFile as Unicode (UTF16). Reading
Unicode (UTF16) works fine, just writing always writes UTF8. (I'm using
2.8.10 and Unicode build.)

Is there any trick how to do this?

Joachim
--
Dr. Joachim Wiesemann
http://jwiesemann.com/ Electrical Engineering, Usability
Vadim Zeitlin
2010-01-24 11:14:41 UTC
Permalink
Post by Joachim Wiesemann
I want to create and write a wxTextFile as Unicode (UTF16). Reading
Unicode (UTF16) works fine, just writing always writes UTF8. (I'm using
2.8.10 and Unicode build.)
Is there any trick how to do this?
Pass a wxMBConvUTF16 (or wxMBConvUTF16LE if you want your data to be
portable to big endian platforms) as second argument to
wxTextFile::Write().

Regards,
VZ
--
TT-Solutions: wxWidgets consultancy and technical support
http://www.tt-solutions.com/
Loading...