summaryrefslogtreecommitdiff
path: root/src/Fl_Text_Editor.cxx
diff options
context:
space:
mode:
authorMatthias Melcher <fltk@matthiasm.com>2010-11-03 22:01:43 +0000
committerMatthias Melcher <fltk@matthiasm.com>2010-11-03 22:01:43 +0000
commitcac40a9b024185cfa5f10d5e7845582ab30a5dd1 (patch)
tree186b289e6429408c98c7a6b27e4eacd7a06d69b5 /src/Fl_Text_Editor.cxx
parentddd4bbff1b07daf5510b1c9aa233876cae332264 (diff)
STR 2158: partially solved. This commit is huge, I admit. I recoded most of Fl_Text_Buffer and large chunks of Fl_Text_Display to make it UTF-8 safe. Rendering of all left-to-right scripts works well on OS X for all tested fonts. International input works AFAIK. Copy and paste of UTF-8 data works. ----> what's not working yet though is line wrapping. Also, text search for internationsl characters is not working yet.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7792 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_Text_Editor.cxx')
-rw-r--r--src/Fl_Text_Editor.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Fl_Text_Editor.cxx b/src/Fl_Text_Editor.cxx
index 76ce92ddd..dc4730fe2 100644
--- a/src/Fl_Text_Editor.cxx
+++ b/src/Fl_Text_Editor.cxx
@@ -255,7 +255,7 @@ int Fl_Text_Editor::kf_backspace(int, Fl_Text_Editor* e) {
if (!e->buffer()->selected() && e->move_left()) {
int l = 1;
// FIXME: character is ucs-4
- char c = e->buffer()->character(e->insert_position());
+ char c = e->buffer()->char_at(e->insert_position());
if (c & 0x80 && c & 0x40) {
l = fl_utf8len(c);
}
@@ -451,7 +451,7 @@ int Fl_Text_Editor::kf_delete(int, Fl_Text_Editor* e) {
if (!e->buffer()->selected()) {
int l = 1;
// FIXME: character is ucs-4
- char c = e->buffer()->character(e->insert_position());
+ char c = e->buffer()->char_at(e->insert_position());
if (c & 0x80 && c & 0x40) {
l = fl_utf8len(c);
}