Discussion:
Rubbish text
Mike Lischke
2013-09-27 14:00:23 UTC
Permalink
Neil,

have you ever inspected a Scintilla window with some text (say, in utf-8) using Spy++ (Windows that is)? It shows all chinese letters, so very likely the encoding is wrong. Not a serious problem, but might show up with screen readers too. Verified with my own application and Notepad++.

Mike
--
www.soft-gems.net
--
You received this message because you are subscribed to the Google Groups "scintilla-interest" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scintilla-interest+***@googlegroups.com.
To post to this group, send email to scintilla-***@googlegroups.com.
Visit this group at http://groups.google.com/group/scintilla-interest.
For more options, visit https://groups.google.com/groups/opt_out.
Neil Hodgson
2013-09-27 21:39:40 UTC
Permalink
Post by Mike Lischke
have you ever inspected a Scintilla window with some text (say, in utf-8) using Spy++ (Windows that is)? It shows all chinese letters, so very likely the encoding is wrong. Not a serious problem, but might show up with screen readers too. Verified with my own application and Notepad++.
Originally Scintilla implemented some of the message API from the system edit and rich edit controls. New APIs more suited to Scintilla were then implemented and the old messages deprecated. Since they were deprecated, they were not updated to handle the case where Scintilla is a Unicode window and expected to yield UTF-16.

If this is important to you then add code so that WM_GETTEXT and WM_GETTEXTLENGTH check IsWindowUnicode and produce / count UTF-16.

Neil
--
You received this message because you are subscribed to the Google Groups "scintilla-interest" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scintilla-interest+***@googlegroups.com.
To post to this group, send email to scintilla-***@googlegroups.com.
Visit this group at http://groups.google.com/group/scintilla-interest.
For more options, visit https://groups.google.com/groups/opt_out.
Mike Lischke
2013-09-30 07:08:51 UTC
Permalink
Post by Neil Hodgson
Post by Mike Lischke
have you ever inspected a Scintilla window with some text (say, in utf-8) using Spy++ (Windows that is)? It shows all chinese letters, so very likely the encoding is wrong. Not a serious problem, but might show up with screen readers too. Verified with my own application and Notepad++.
Originally Scintilla implemented some of the message API from the system edit and rich edit controls. New APIs more suited to Scintilla were then implemented and the old messages deprecated. Since they were deprecated, they were not updated to handle the case where Scintilla is a Unicode window and expected to yield UTF-16.
If this is important to you then add code so that WM_GETTEXT and WM_GETTEXTLENGTH check IsWindowUnicode and produce / count UTF-16.
Well, not really important. Just thought Scintilla should be correct there too, since obviously these APIs are sometimes still used.

Mike
--
www.soft-gems.net
--
You received this message because you are subscribed to the Google Groups "scintilla-interest" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scintilla-interest+***@googlegroups.com.
To post to this group, send email to scintilla-***@googlegroups.com.
Visit this group at http://groups.google.com/group/scintilla-interest.
For more options, visit https://groups.google.com/groups/opt_out.
Continue reading on narkive:
Loading...