mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Edit book: When searching for text in the editor, center the found text on screen
This is a dummy commit, the actual change was accidentally included in the previous commit.
This commit is contained in:
parent
db71b29026
commit
3c10e66274
@ -270,6 +270,7 @@ class TextEdit(QPlainTextEdit):
|
|||||||
c.setPosition(start)
|
c.setPosition(start)
|
||||||
c.setPosition(end, c.KeepAnchor)
|
c.setPosition(end, c.KeepAnchor)
|
||||||
self.setTextCursor(c)
|
self.setTextCursor(c)
|
||||||
|
# Center search result on screen
|
||||||
self.centerCursor()
|
self.centerCursor()
|
||||||
return True
|
return True
|
||||||
|
|
||||||
@ -324,6 +325,7 @@ class TextEdit(QPlainTextEdit):
|
|||||||
c.setPosition(start)
|
c.setPosition(start)
|
||||||
c.setPosition(end, c.KeepAnchor)
|
c.setPosition(end, c.KeepAnchor)
|
||||||
self.setTextCursor(c)
|
self.setTextCursor(c)
|
||||||
|
# Center search result on screen
|
||||||
self.centerCursor()
|
self.centerCursor()
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user