QScintilla/Lexers/LexerHTML.py

changeset 945
8cd4d08fa9f6
parent 791
9ec2ac20e54e
child 948
fe7b94ed01ec
diff -r 1b59c4ba121e -r 8cd4d08fa9f6 QScintilla/Lexers/LexerHTML.py
--- a/QScintilla/Lexers/LexerHTML.py	Fri Mar 11 08:55:14 2011 +0100
+++ b/QScintilla/Lexers/LexerHTML.py	Fri Mar 11 16:51:57 2011 +0100
@@ -12,8 +12,9 @@
 from .Lexer import Lexer
 import Preferences
 
+
 class LexerHTML(QsciLexerHTML, Lexer):
-    """ 
+    """
     Subclass to implement some additional lexer dependant methods.
     """
     def __init__(self, parent=None):
@@ -26,8 +27,8 @@
         Lexer.__init__(self)
         
         self.streamCommentString = {
-            'start' : '<!-- ',
-            'end'   : ' -->'
+            'start': '<!-- ',
+            'end': ' -->'
         }
     
     def initProperties(self):
@@ -50,20 +51,20 @@
         
         @return flag indicating a comment style (boolean)
         """
-        return style in [QsciLexerHTML.HTMLComment, 
-                         QsciLexerHTML.ASPXCComment, 
-                         QsciLexerHTML.SGMLComment, 
-                         QsciLexerHTML.SGMLParameterComment, 
-                         QsciLexerHTML.JavaScriptComment, 
-                         QsciLexerHTML.JavaScriptCommentDoc, 
-                         QsciLexerHTML.JavaScriptCommentLine, 
-                         QsciLexerHTML.ASPJavaScriptComment, 
-                         QsciLexerHTML.ASPJavaScriptCommentDoc, 
-                         QsciLexerHTML.ASPJavaScriptCommentLine, 
-                         QsciLexerHTML.VBScriptComment, 
-                         QsciLexerHTML.ASPVBScriptComment, 
-                         QsciLexerHTML.PythonComment, 
-                         QsciLexerHTML.ASPPythonComment, 
+        return style in [QsciLexerHTML.HTMLComment,
+                         QsciLexerHTML.ASPXCComment,
+                         QsciLexerHTML.SGMLComment,
+                         QsciLexerHTML.SGMLParameterComment,
+                         QsciLexerHTML.JavaScriptComment,
+                         QsciLexerHTML.JavaScriptCommentDoc,
+                         QsciLexerHTML.JavaScriptCommentLine,
+                         QsciLexerHTML.ASPJavaScriptComment,
+                         QsciLexerHTML.ASPJavaScriptCommentDoc,
+                         QsciLexerHTML.ASPJavaScriptCommentLine,
+                         QsciLexerHTML.VBScriptComment,
+                         QsciLexerHTML.ASPVBScriptComment,
+                         QsciLexerHTML.PythonComment,
+                         QsciLexerHTML.ASPPythonComment,
                          QsciLexerHTML.PHPComment]
     
     def isStringStyle(self, style):
@@ -72,36 +73,36 @@
         
         @return flag indicating a string style (boolean)
         """
-        return style in [QsciLexerHTML.HTMLDoubleQuotedString, 
-                         QsciLexerHTML.HTMLSingleQuotedString, 
-                         QsciLexerHTML.SGMLDoubleQuotedString, 
-                         QsciLexerHTML.SGMLSingleQuotedString, 
-                         QsciLexerHTML.JavaScriptDoubleQuotedString, 
-                         QsciLexerHTML.JavaScriptSingleQuotedString, 
-                         QsciLexerHTML.JavaScriptUnclosedString, 
-                         QsciLexerHTML.ASPJavaScriptDoubleQuotedString, 
-                         QsciLexerHTML.ASPJavaScriptSingleQuotedString, 
-                         QsciLexerHTML.ASPJavaScriptUnclosedString, 
-                         QsciLexerHTML.VBScriptString, 
-                         QsciLexerHTML.VBScriptUnclosedString, 
-                         QsciLexerHTML.ASPVBScriptString, 
-                         QsciLexerHTML.ASPVBScriptUnclosedString, 
-                         QsciLexerHTML.PythonDoubleQuotedString, 
-                         QsciLexerHTML.PythonSingleQuotedString, 
-                         QsciLexerHTML.PythonTripleDoubleQuotedString, 
-                         QsciLexerHTML.PythonTripleSingleQuotedString, 
-                         QsciLexerHTML.ASPPythonDoubleQuotedString, 
-                         QsciLexerHTML.ASPPythonSingleQuotedString, 
-                         QsciLexerHTML.ASPPythonTripleDoubleQuotedString, 
-                         QsciLexerHTML.ASPPythonTripleSingleQuotedString, 
-                         QsciLexerHTML.PHPDoubleQuotedString, 
+        return style in [QsciLexerHTML.HTMLDoubleQuotedString,
+                         QsciLexerHTML.HTMLSingleQuotedString,
+                         QsciLexerHTML.SGMLDoubleQuotedString,
+                         QsciLexerHTML.SGMLSingleQuotedString,
+                         QsciLexerHTML.JavaScriptDoubleQuotedString,
+                         QsciLexerHTML.JavaScriptSingleQuotedString,
+                         QsciLexerHTML.JavaScriptUnclosedString,
+                         QsciLexerHTML.ASPJavaScriptDoubleQuotedString,
+                         QsciLexerHTML.ASPJavaScriptSingleQuotedString,
+                         QsciLexerHTML.ASPJavaScriptUnclosedString,
+                         QsciLexerHTML.VBScriptString,
+                         QsciLexerHTML.VBScriptUnclosedString,
+                         QsciLexerHTML.ASPVBScriptString,
+                         QsciLexerHTML.ASPVBScriptUnclosedString,
+                         QsciLexerHTML.PythonDoubleQuotedString,
+                         QsciLexerHTML.PythonSingleQuotedString,
+                         QsciLexerHTML.PythonTripleDoubleQuotedString,
+                         QsciLexerHTML.PythonTripleSingleQuotedString,
+                         QsciLexerHTML.ASPPythonDoubleQuotedString,
+                         QsciLexerHTML.ASPPythonSingleQuotedString,
+                         QsciLexerHTML.ASPPythonTripleDoubleQuotedString,
+                         QsciLexerHTML.ASPPythonTripleSingleQuotedString,
+                         QsciLexerHTML.PHPDoubleQuotedString,
                          QsciLexerHTML.PHPSingleQuotedString]
     
     def defaultKeywords(self, kwSet):
         """
         Public method to get the default keywords.
         
-        @param kwSet number of the keyword set (integer) 
+        @param kwSet number of the keyword set (integer)
         @return string giving the keywords (string) or None
         """
-        return QsciLexerHTML.keywords(self, kwSet)
\ No newline at end of file
+        return QsciLexerHTML.keywords(self, kwSet)

eric ide

mercurial