diff --git a/nw/core/project.py b/nw/core/project.py index 96e22103..b3a2661f 100644 --- a/nw/core/project.py +++ b/nw/core/project.py @@ -113,7 +113,7 @@ class NWProject(): CUSTOM, and always have parent handle set to None. """ if not self.projTree.checkRootUnique(rootClass): - self.makeAlert("Duplicate root item detected!", nwAlert.ERROR) + self.makeAlert("Duplicate root item detected.", nwAlert.ERROR) return None newItem = NWItem(self) newItem.setName(rootName) @@ -995,7 +995,7 @@ class NWProject(): # Report status if len(orphanFiles) > 0: self.makeAlert( - "Found %d orphaned file(s) in project folder!" % len(orphanFiles), + "Found %d orphaned file(s) in project folder." % len(orphanFiles), nwAlert.WARN ) else: diff --git a/nw/gui/dialogs/projectsettings.py b/nw/gui/dialogs/projectsettings.py index 8d501585..a49193d1 100644 --- a/nw/gui/dialogs/projectsettings.py +++ b/nw/gui/dialogs/projectsettings.py @@ -362,7 +362,9 @@ class GuiProjectEditStatus(QWidget): self.listBox.takeItem(iRow) self.colChanged = True else: - self.theParent.makeAlert("Cannot delete status item that is in use.",nwAlert.ERROR) + self.theParent.makeAlert( + "Cannot delete status item that is in use.", nwAlert.ERROR + ) return def _saveItem(self): diff --git a/nw/gui/elements/doctree.py b/nw/gui/elements/doctree.py index 2c81cf91..02db9bde 100644 --- a/nw/gui/elements/doctree.py +++ b/nw/gui/elements/doctree.py @@ -396,7 +396,7 @@ class GuiDocTree(QTreeWidget): trItemP.takeChild(tIndex) del self.theProject.projTree[tHandle] else: - self.makeAlert(["Cannot delete folder.","It is not empty."], nwAlert.ERROR) + self.makeAlert("Cannot delete folder. It is not empty.", nwAlert.ERROR) return False elif nwItemS.itemType == nwItemType.ROOT: @@ -407,7 +407,7 @@ class GuiDocTree(QTreeWidget): self.theParent.mainMenu.setAvailableRoot() self.theProject.setProjectChanged(True) else: - self.makeAlert(["Cannot delete root folder.","It is not empty."], nwAlert.ERROR) + self.makeAlert("Cannot delete root folder. It is not empty.", nwAlert.ERROR) return False return True diff --git a/nw/gui/icons.py b/nw/gui/icons.py index a57f3029..d4ac4ef5 100644 --- a/nw/gui/icons.py +++ b/nw/gui/icons.py @@ -249,7 +249,9 @@ class GuiIcons: try: confParser.read_file(open(themeConf, mode="r", encoding="utf8")) except Exception as e: - self.theParent.makeAlert(["Could not load theme config file.",str(e)],nwAlert.ERROR) + self.theParent.makeAlert( + ["Could not load theme config file.",str(e)], nwAlert.ERROR + ) continue themeName = "" if confParser.has_section("Main"): diff --git a/nw/gui/theme.py b/nw/gui/theme.py index 5b4893a6..04a00c0e 100644 --- a/nw/gui/theme.py +++ b/nw/gui/theme.py @@ -284,7 +284,9 @@ class GuiTheme: try: confParser.read_file(open(themeConf, mode="r", encoding="utf8")) except Exception as e: - self.theParent.makeAlert(["Could not load theme config file.",str(e)],nwAlert.ERROR) + self.theParent.makeAlert( + ["Could not load theme config file.",str(e)], nwAlert.ERROR + ) continue themeName = "" if confParser.has_section("Main"): @@ -314,7 +316,9 @@ class GuiTheme: try: confParser.read_file(open(syntaxPath, mode="r", encoding="utf8")) except Exception as e: - self.theParent.makeAlert(["Could not load syntax file.",str(e)],nwAlert.ERROR) + self.theParent.makeAlert( + ["Could not load syntax file.",str(e)], nwAlert.ERROR + ) return [] syntaxName = "" if confParser.has_section("Main"): diff --git a/nw/guimain.py b/nw/guimain.py index 69090ac9..38471f97 100644 --- a/nw/guimain.py +++ b/nw/guimain.py @@ -553,7 +553,7 @@ class GuiMain(QMainWindow): if self.docEditor.theHandle is None: self.makeAlert( - ["Please open a document to import the text file into."], + "Please open a document to import the text file into.", nwAlert.ERROR ) return False @@ -782,7 +782,7 @@ class GuiMain(QMainWindow): 0 = info, 1 = warning, and 2 = error. """ if isinstance(theMessage, list): - popMsg = " ".join(theMessage) + popMsg = "
".join(theMessage) logMsg = theMessage else: popMsg = theMessage