From 3901e7dd4ca498672c64ae62312a8c19a9369677 Mon Sep 17 00:00:00 2001 From: prculley Date: Sun, 26 Feb 2017 09:11:31 -0600 Subject: [PATCH] Fix unodoableentry for international characters Gtk has some parameters in bytes, some in characters; they cannot be combined. --- gramps/gui/widgets/undoableentry.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gramps/gui/widgets/undoableentry.py b/gramps/gui/widgets/undoableentry.py index 8c91ce026..9ed0df194 100644 --- a/gramps/gui/widgets/undoableentry.py +++ b/gramps/gui/widgets/undoableentry.py @@ -177,8 +177,8 @@ class UndoableEntry(Gtk.Entry, Gtk.Editable): self.undo_stack.append(prev_insert) self.undo_stack.append(undo_action) break - self.get_buffer().insert_text(position, text, length) - return position + length + self.get_buffer().insert_text(position, text, len(text)) + return position + len(text) def _on_delete_text(self, editable, start, end): def can_be_merged(prev, cur):