mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Edit Book: When jumping to next occurrence of a word, take language into account
This commit is contained in:
parent
03c2c5ea89
commit
a39fed6350
@ -391,6 +391,8 @@ class TextEdit(PlainTextEdit):
|
||||
c.setPosition(c.anchor() + idx)
|
||||
c.setPosition(c.position() + string_length(word), c.KeepAnchor)
|
||||
if self.smarts.verify_for_spellcheck(c, self.highlighter):
|
||||
locale = self.spellcheck_locale_for_cursor(c)
|
||||
if not lang or (locale and lang == locale.langcode):
|
||||
self.setTextCursor(c)
|
||||
if center_on_cursor:
|
||||
self.centerCursor()
|
||||
|
Loading…
x
Reference in New Issue
Block a user