From 11d62a8e6bd56a5e7c6777980f7f44eeebbdadf2 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Tue, 4 May 2021 10:50:45 +0530 Subject: [PATCH] Fix #1927011 [[Enhancement] Place the cursor at the end of the Edit notes for highlight window](https://bugs.launchpad.net/calibre/+bug/1927011) --- src/pyj/read_book/highlights.pyj | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/pyj/read_book/highlights.pyj b/src/pyj/read_book/highlights.pyj index 42fb169a3a..33f7bd7ccb 100644 --- a/src/pyj/read_book/highlights.pyj +++ b/src/pyj/read_book/highlights.pyj @@ -359,7 +359,6 @@ class EditNotesAndColors: # {{{ onclick=def(ev): ev.stopPropagation();, id=unique_id(), E.div( E.textarea( - current_notes or '', placeholder=_('Add notes for this highlight. Double click or long tap on a highlight to read its notes.'), rows='10', spellcheck='true', style='width: 90%;', onkeydown=handle_keypress, @@ -406,6 +405,8 @@ class EditNotesAndColors: # {{{ self.set_visibility_of_remove_button() window.setTimeout(self.notes_edit.focus.bind(self.notes_edit), 0) + if current_notes: + self.notes_edit.value = current_notes def hide_add_style(self, new_style): c = self.container