User forums > General (but related to Code::Blocks)

Support multi-byte character in editor of C::B???

(1/2) > >>

heromyth:
For example, to support Chinese. It seems that I have to modify the scintilla in STC. I want to know whether  there is other way. :roll:

rickg22:
Yes, it's called Unicode.

The bad news is, it's not supported yet :-(
The good news is, we're working on it ;-)

heromyth:
Thanks for your works.
I don't think it must to use Unicode. Like wxTextCtrl that doesn't use Unicode, it seems to support multi-byte edit-operation(for example, input, delete, choice, copy etc.).

My problem in C:B is that I must press Backspace/Delete twice to delete a Chinese character, not like english character, just press once to delete it.

rickg22:
wxWidgets has native unicode support, but programs must be adapted to use it.

Codeblocks isn't adapted (yet), and this makes linking fail (or worse, crashing) when the wxWidgets library is compiled with unicode support. I'm sure that when we do that, you'll be able to edit chinese with no problem.

heromyth:
Maybe we can refer to SciTE (see http://scintilla.sourceforge.net/SciTEDoc.html about code.page), which also depends on scintilla. In SciTE, I can edit Chinese perfectly through adding

--- Code: --- code.page=936
 character.set=134
--- End code ---

to SciTEGlobal.properties, not using unicode. Of course, we can add code.page=65001 for using unicode. Both work well in Windows.

For GTK+ in Linux, it seems that just using unicode can solve my question. So using unicode in C:B seems to be the best way.

Navigation

[0] Message Index

[#] Next page

Go to full version