From bea4b5e4db4e2795d7836d5d1e084292eb5caffe Mon Sep 17 00:00:00 2001 From: Jehan Date: Sun, 5 Jun 2016 23:09:47 +0200 Subject: [PATCH] app: the preedit_end mark must be created with right gravity. With left gravity, the mark is moved back 1 character to the left of the cursor, whereas with right gravity, it is right after newly-inserted text. This resulted sometimes into non-deleted preedit characters. I don't understand all the subtleties since the problem only occurred for the first character of a text layer, at least in my tests. Anyway now it should be good. --- app/tools/gimptexttool-editor.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/tools/gimptexttool-editor.c b/app/tools/gimptexttool-editor.c index 4a0e3745b7..bb05162123 100644 --- a/app/tools/gimptexttool-editor.c +++ b/app/tools/gimptexttool-editor.c @@ -1511,7 +1511,7 @@ gimp_text_tool_im_preedit_changed (GtkIMContext *context, gtk_text_buffer_get_insert (buffer)); text_tool->preedit_end = gtk_text_buffer_create_mark (buffer, "preedit-end", - &iter, TRUE); + &iter, FALSE); /* Move the cursor to the expected location. */ gtk_text_buffer_get_iter_at_mark (buffer, &iter, text_tool->preedit_start);