QScintilla/Editor.py

changeset 730
772666a0a05d
parent 728
3ee110082fb7
child 741
137cc6344b48
--- a/QScintilla/Editor.py	Fri Nov 19 08:52:51 2010 +0100
+++ b/QScintilla/Editor.py	Fri Nov 19 19:32:32 2010 +0100
@@ -4608,15 +4608,18 @@
                     errorAnnotations.append(
                         self.trUtf8("Error: {0}").format(self.syntaxerrors[handle]))
             
+            wLen = len(warningAnnotations)
+            eLen = len(errorAnnotations)
             annotations = []
-            if len(warningAnnotations):
+            
+            if wLen:
                 annotationWarningTxt = "\n".join(warningAnnotations)
-                if len(errorAnnotations) > 0:
+                if eLen:
                     annotationWarningTxt += "\n"
                 annotations.append(QsciStyledText(annotationWarningTxt, 
                     self.annotationWarningStyle))
             
-            if len(errorAnnotations) > 0:
+            if eLen:
                 annotationErrorTxt = "\n".join(errorAnnotations)
                 annotations.append(QsciStyledText(annotationErrorTxt, 
                     self.annotationErrorStyle))

eric ide

mercurial