From 74bc4127392dfcfa7fb40f3b2beb9aa3a9d385d5 Mon Sep 17 00:00:00 2001 From: "Veronica K. B. Olsen" Date: Sun, 6 Oct 2019 15:57:45 +0200 Subject: [PATCH] Updated debug info --- nw/gui/doceditor.py | 3 +++ nw/gui/searchbar.py | 6 +----- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/nw/gui/doceditor.py b/nw/gui/doceditor.py index 8018438c..d1034121 100644 --- a/nw/gui/doceditor.py +++ b/nw/gui/doceditor.py @@ -547,6 +547,9 @@ class GuiDocEditor(QTextEdit): theCursor.endEditBlock() theCursor.setPosition(xPos) self.setTextCursor(theCursor) + logger.verbose("Replaced occurrence of '%s' with '%s' on line %d" % ( + searchFor, replWith, theCursor.blockNumber() + )) if searchFor != "": self._findNext() return diff --git a/nw/gui/searchbar.py b/nw/gui/searchbar.py index 90ceab42..479ca9dd 100644 --- a/nw/gui/searchbar.py +++ b/nw/gui/searchbar.py @@ -81,15 +81,11 @@ class GuiSearchBar(QFrame): ## def setSearchText(self, theText): - if not self.isVisible(): self.setVisible(True) - self.searchBox.setText(theText) self.searchBox.setFocus(True) - - logger.debug("Setting search text to '%s'" % theText) - + logger.verbose("Setting search text to '%s'" % theText) return True def setReplaceText(self, theText):