diff --git a/nw/__init__.py b/nw/__init__.py index 96aeadf8..6be830af 100644 --- a/nw/__init__.py +++ b/nw/__init__.py @@ -80,7 +80,6 @@ def main(sysArgs=None): "help", "debug", "verbose", - "debuggui", "quiet", "time", "logfile=", @@ -100,7 +99,6 @@ def main(sysArgs=None): " -v, --version Print program version and exit.\n" " -d, --debug Print debug output.\n" " --verbose Increase verbosity of debug output.\n" - " -D, --debuggui Shows additional debug GUI elements. Includes -d.\n" " -q, --quiet Disable output to command line. Does not affect log file.\n" " -t, --time Shows time stamp in logging output.\n" " -l, --logfile= Specify log file.\n" @@ -124,7 +122,6 @@ def main(sysArgs=None): showTime = False confPath = None testMode = False - debugGUI = False spellTool = None qtStyle = "Fusion" @@ -162,14 +159,9 @@ def main(sysArgs=None): testMode = True elif inOpt in ("--spell"): spellTool = inArg - elif inOpt in ("-D","--debuggui"): - debugLevel = logging.DEBUG - debugStr = "{name:>30}:{lineno:<4d} {levelname:8} {message:}" - debugGUI = True # Set Config Options CONFIG.showGUI = not testMode - CONFIG.debugGUI = debugGUI CONFIG.debugInfo = debugLevel < logging.INFO CONFIG.spellTool = spellTool diff --git a/nw/config.py b/nw/config.py index 2e0baacb..30d65cdf 100644 --- a/nw/config.py +++ b/nw/config.py @@ -40,7 +40,6 @@ class Config: self.appName = nw.__package__ self.appHandle = nw.__package__.lower() self.showGUI = True - self.debugGUI = False self.debugInfo = False self.spellTool = None diff --git a/nw/gui/elements/docdetails.py b/nw/gui/elements/docdetails.py index 888e295e..a38f9ac6 100644 --- a/nw/gui/elements/docdetails.py +++ b/nw/gui/elements/docdetails.py @@ -32,7 +32,6 @@ class GuiDocDetails(QFrame): logger.debug("Initialising DocDetails ...") self.mainConf = nw.CONFIG - self.debugGUI = self.mainConf.debugGUI self.theParent = theParent self.theProject = theProject diff --git a/nw/gui/elements/doctree.py b/nw/gui/elements/doctree.py index bc53ab59..9b4bc750 100644 --- a/nw/gui/elements/doctree.py +++ b/nw/gui/elements/doctree.py @@ -35,7 +35,6 @@ class GuiDocTree(QTreeWidget): logger.debug("Initialising DocTree ...") self.mainConf = nw.CONFIG - self.debugGUI = self.mainConf.debugGUI self.theParent = theParent self.theTheme = theParent.theTheme self.theProject = theProject @@ -52,8 +51,7 @@ class GuiDocTree(QTreeWidget): self.setIndentation(13) self.setColumnCount(4) self.setHeaderLabels(["Label","Words","Flags","Handle"]) - if not self.debugGUI: - self.hideColumn(self.C_HANDLE) + self.hideColumn(self.C_HANDLE) treeHead = self.headerItem() treeHead.setTextAlignment(self.C_COUNT,Qt.AlignRight) diff --git a/nw/gui/elements/viewdetails.py b/nw/gui/elements/viewdetails.py index d283cd20..5880d008 100644 --- a/nw/gui/elements/viewdetails.py +++ b/nw/gui/elements/viewdetails.py @@ -31,7 +31,6 @@ class GuiDocViewDetails(QWidget): logger.debug("Initialising DocViewDetails ...") self.mainConf = nw.CONFIG - self.debugGUI = self.mainConf.debugGUI self.theParent = theParent self.theProject = theProject self.currHandle = None diff --git a/nw/gui/statusbar.py b/nw/gui/statusbar.py index cbd02b70..00170b8c 100644 --- a/nw/gui/statusbar.py +++ b/nw/gui/statusbar.py @@ -60,9 +60,6 @@ class GuiMainStatus(QStatusBar): self.docChanged.setFixedWidth(16) self.docChanged.setToolTip("Document Changes Saved") - self.boxDocHandle = QLabel() - self.boxDocHandle.setFrameStyle(QFrame.Panel | QFrame.Sunken); - # Add Them self.addPermanentWidget(self.docChanged) self.addPermanentWidget(self.boxCounts) @@ -70,8 +67,6 @@ class GuiMainStatus(QStatusBar): self.addPermanentWidget(self.projChanged) self.addPermanentWidget(self.boxStats) self.addPermanentWidget(self.boxTime) - if self.mainConf.debugGUI: - self.addPermanentWidget(self.boxDocHandle) self.setSizeGripEnabled(True) @@ -90,7 +85,6 @@ class GuiMainStatus(QStatusBar): self.setRefTime(None) self.setStats(0,0) self.setCounts(0,0,0) - self.setDocHandle(None) self.setProjectStatus(None) self.setDocumentStatus(None) self._updateTime() @@ -134,13 +128,6 @@ class GuiMainStatus(QStatusBar): self.boxCounts.setText("Document: {:d} : {:d} : {:d}".format(cC,wC,pC)) return - def setDocHandle(self, theHandle): - if theHandle is None: - self.boxDocHandle.setText("0000000000000") - else: - self.boxDocHandle.setText("%13s" % theHandle) - return - ## # Internal Functions ## diff --git a/nw/project/document.py b/nw/project/document.py index ad531fb3..e54a72f0 100644 --- a/nw/project/document.py +++ b/nw/project/document.py @@ -82,7 +82,6 @@ class NWDoc(): if showStatus: self.theParent.statusBar.setStatus("Opened Document: %s" % self.theItem.itemName) - self.theParent.statusBar.setDocHandle(tHandle) return theDoc