Also remove the debuggui feature, as the functionality os handled otherwise if still needed

This commit is contained in:
Veronica K. B. Olsen
2019-11-03 15:14:34 +01:00
parent 5e79ec40f2
commit f6bc1f32e5
7 changed files with 1 additions and 28 deletions
-8
View File
@@ -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
-1
View File
@@ -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
-1
View File
@@ -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
+1 -3
View File
@@ -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)
-1
View File
@@ -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
-13
View File
@@ -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("<b>Document:</b> {: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
##
-1
View File
@@ -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