<?xml version="1.0"?>
<!-- syntaxdefinition for Python by Hueyan Chen -->

<SyntaxDefinition name="Python" extensions=".py">

    <Environment>
        <Custom name="TypeReference" bold="false" italic="false" color="#04ABAB" />
        <Custom name="UnknownEntity" bold="false" italic="false" color="#AB0404" />
    </Environment>

    <Properties>
        <Property name="LineComment" value="#"/>
    </Properties>

    <Digits name="Digits" bold="false" italic="false" color="DarkBlue"/>

    <RuleSets>
        <RuleSet ignorecase="false">
            <Delimiters>@@^*()-+=\/[]{}"' ,:;	</Delimiters>

            <Span name="LineComment" bold="false" italic="false" color="Green" stopateol="true">
                <Begin>#</Begin>
            </Span>

            <Span name="StringDouble" bold="false" italic="false" color="Magenta" stopateol="true">
                <Begin>"@!""@</Begin>
                <End>"</End>
            </Span>
            <Span name="StringSingle" bold="false" italic="false" color="Magenta" stopateol="true">
                <Begin>&apos;@!&apos;&apos;@</Begin>
                <End>&apos;</End>
            </Span>
            <Span name="StringBlockDouble" bold="false" italic="false" color="Magenta" stopateol="false">
                <Begin>"""</Begin>
                <End>"""</End>
            </Span>
            <Span name="StringBlockSingle" bold="false" italic="false" color="Magenta" stopateol="false">
                <Begin>&apos;&apos;&apos;</Begin>
                <End>&apos;&apos;&apos;</End>
            </Span>

            <Span name="Decorator" bold="true" italic="false" color="MidnightBlue" stopateol="true">
                <Begin>@@</Begin>
            </Span>

            <MarkPrevious bold="true" italic="false" color="MidnightBlue">(</MarkPrevious>

            <KeyWords name="KnownValues" bold="true" italic="false" color="DarkCyan">
                <Key word="True" />
                <Key word="False" />
                <Key word="None" />
            </KeyWords>

            <KeyWords name="Keywords" bold="true" italic="false" color="Blue">
                <Key word="and" />
                <Key word="as" />
                <Key word="assert" />
                <Key word="break" />
                <Key word="class" />
                <Key word="continue" />
                <Key word="def" />
                <Key word="del" />
                <Key word="elif" />
                <Key word="else" />
                <Key word="except" />
                <Key word="finally" />
                <Key word="for" />
                <Key word="from" />
                <Key word="global" />
                <Key word="if" />
                <Key word="import" />
                <Key word="in" />
                <Key word="is" />
                <Key word="lambda" />
                <Key word="nonlocal" />
                <Key word="not" />
                <Key word="or" />
                <Key word="pass" />   
                <Key word="raise" />
                <Key word="return" />
                <Key word="try" />
                <Key word="while" />
                <Key word="with" />
                <Key word="yield" />
            </KeyWords>
            
            <KeyWords name="BuitinFunctions" bold="true" italic="false" color="DarkMagenta">
                <Key word="abs" />
                <Key word="all" />
                <Key word="any" />
                <Key word="ascii" />
                <Key word="bin" />
                <Key word="bool" />
                <Key word="bytearray" />  
                <Key word="callable" />
                <Key word="chr" />
                <Key word="classmethod" />
                <Key word="compile" />
                <Key word="complex" />
                <Key word="delattr" />
                <Key word="dict" />
                <Key word="dir" />
                <Key word="divmod" />
                <Key word="enumerate" />
                <Key word="eval" />
                <Key word="exec" />
                <Key word="filter" />
                <Key word="float" />  
                <Key word="format" />
                <Key word="frozenset" />
                <Key word="getattr" />
                <Key word="globals" />
                <Key word="hasattr" />
                <Key word="hash" />
                <Key word="help" />               
                <Key word="hex" />
                <Key word="id" />
                <Key word="input" />
                <Key word="int" />
                <Key word="isinstance" />
                <Key word="issubclass" />
                <Key word="iter" />  
                <Key word="len" />
                <Key word="list" />
                <Key word="locals" />
                <Key word="map" />
                <Key word="max" />
                <Key word="memoryview" />
                <Key word="min" />
                <Key word="next" />
                <Key word="object" />
                <Key word="oct" />
                <Key word="open" />
                <Key word="ord" />
                <Key word="pow" />
                <Key word="print" />  
                <Key word="property" />
                <Key word="range" />
                <Key word="repr" />
                <Key word="reversed" />
                <Key word="round" />
                <Key word="set" />
                <Key word="setattr" />  
                <Key word="slice" />
                <Key word="sorted" />
                <Key word="staticmethod" />
                <Key word="str" />  
                <Key word="sum" />
                <Key word="super" />
                <Key word="tuple" />
                <Key word="type" />
                <Key word="vars" />
                <Key word="zip" />
                <Key word="__import__" />
            </KeyWords>
            
            <KeyWords name="Punctuations" bold="false" italic="false" color="DarkGreen">
				        <Key word = "," />
				        <Key word = "." />
                <Key word = ":" />
				        <Key word = "(" />
				        <Key word = ")" />
				        <Key word = "[" />
				        <Key word = "]" />
				        <Key word = "{" />
				        <Key word = "}" />
				        <Key word = "+" />
				        <Key word = "-" />
				        <Key word = "/" />
			        	<Key word = "%" />
				        <Key word = "*" />
				        <Key word = "&lt;" />
				        <Key word = "&gt;" />
				        <Key word = "^" />
				        <Key word = "=" />
                <Key word = "!" />
				        <Key word = "~" />
				        <Key word = "|" />
			        	<Key word = "&amp;" />
			      </KeyWords>
        </RuleSet>

    </RuleSets>
</SyntaxDefinition>

