Page 1 of 1

problem on compiling project with unicode chars

Posted: Sun Jul 01, 2012 4:02 pm
by eriX

I use some unicode-chars like ä,ö,ü in my project. (Labels, wxMessageBox etc.)
If I start to compile my project, the compiler stops with the error "Illegal byte sequence"

I can't figure out where this problem comes from...

I've tried to convert my .cpp source files with Notepad++ to UTF-8 without BOM.
This would fix the unicode-chars in the generated code from the form-designer,
but the chars I write in my functions are displayed wrong if I use the program.

I have no idea what I could do to help myself, because all settings match to unicode support.

I use the latest wxDevC++ IDE.

I hope you can help me!

Thanks a lot!


Re: problem on compiling project with unicode chars

Posted: Wed Jul 04, 2012 1:52 am
by tbreina
Are you using wxT() or _() for the string wrapper?

For example,

Code: Select all

_("Text label")

Code: Select all

wxT("Text label")
I think _() will work for unicode characters. To change this, go to Tools->Designer Options->Code Generation Options->String Internationalization. Select the second option in the drop down box (_). Then, change something on the form to re-generate the code.