Added capability to the syntax checker dialog to show all errors/warnings in an editor when the file entry is double activated.

Wed, 07 Nov 2012 17:51:32 +0100

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Wed, 07 Nov 2012 17:51:32 +0100
changeset 2195
d6cbd81fb692
parent 2194
0fce40af66b8
child 2196
b5ca7665e928

Added capability to the syntax checker dialog to show all errors/warnings in an editor when the file entry is double activated.

Plugins/CheckerPlugins/SyntaxChecker/SyntaxCheckerDialog.py file | annotate | diff | comparison | revisions
changelog file | annotate | diff | comparison | revisions
--- a/Plugins/CheckerPlugins/SyntaxChecker/SyntaxCheckerDialog.py	Wed Nov 07 11:52:17 2012 +0100
+++ b/Plugins/CheckerPlugins/SyntaxChecker/SyntaxCheckerDialog.py	Wed Nov 07 17:51:32 2012 +0100
@@ -344,6 +344,20 @@
                 editor.toggleFlakesWarning(lineno, True, error)
             else:
                 editor.toggleSyntaxError(lineno, index, True, error, show=True)
+        else:
+            fn = Utilities.normabspath(itm.data(0, self.filenameRole))
+            vm = e5App().getObject("ViewManager")
+            vm.openSourceFile(fn)
+            editor = vm.getOpenEditor(fn)
+            for index in range(itm.childCount()):
+                citm = itm.child(index)
+                lineno = citm.data(0, self.lineRole)
+                index = citm.data(0, self.indexRole)
+                error = citm.data(0, self.errorRole)
+                if citm.data(0, self.warningRole):
+                    editor.toggleFlakesWarning(lineno, True, error)
+                else:
+                    editor.toggleSyntaxError(lineno, index, True, error, show=True)
         
     @pyqtSlot()
     def on_showButton_clicked(self):
--- a/changelog	Wed Nov 07 11:52:17 2012 +0100
+++ b/changelog	Wed Nov 07 17:51:32 2012 +0100
@@ -7,6 +7,9 @@
      Python 2 and Python 3 debuggers
 - Debug Viewer
   -- added a viewer for call trace logs
+- Syntax Checker
+  -- added capability to the syntax checker dialog to show all errors/warnings
+     in an editor when the file entry is double activated
 - User Interface
   -- changed the layout of the right side widgets and added a sub menu
      for the switching between the 'inner' windows.

eric ide

mercurial