Warning, /frameworks/syntax-highlighting/data/syntax/context.xml is written in an unsupported language. File is not indexed.

0001 <?xml version="1.0" encoding="UTF-8"?>
0002 <!DOCTYPE language
0003 [
0004         <!-- The characters ! ? @ are "internal" or system macros, normally not usable, in general: user macros are just letters, see
0005         https://wiki.contextgarden.net/System_Macros/Scratch_Variables and https://www.mail-archive.com/ntg-context@ntg.nl/msg87737.html
0006         In practice any non-special character works, though english characters should be used, except for one character macros, they use any symbol -->
0007         <!ENTITY macro      "\\([[:alpha:]]+|[[:graph:]])">
0008 ]>
0009 <language
0010         name="ConTeXt"
0011         version="11"
0012         section="Markup"
0013         kateversion="5.79"
0014         priority="8"
0015         extensions="*.ctx;*.mkiv;*.mkvi;*.mkxl;*.mklx"
0016         mimetype="text/x-tex"
0017         casesensitive="1"
0018         author="Philipp A. (flying-sheep@web.de)"
0019         license="GPL"
0020 >
0021         <highlighting>
0022                 <list name="titles">
0023                         <item>\part</item>
0024                         <item>\chapter</item>
0025                         <item>\section</item>
0026                         <item>\subsection</item>
0027                         <item>\subsubsection</item>
0028                         <item>\subsubsubsection</item>
0029                         <item>\subsubsubsubsection</item>
0030                         <item>\title</item>
0031                         <item>\subject</item>
0032                         <item>\subsubject</item>
0033                         <item>\subsubsubject</item>
0034                         <item>\subsubsubsubject</item>
0035                         <item>\subsubsubsubsubject</item>
0036                 </list>
0037                 <list name="mathMacros">
0038                         <item>\m</item>
0039                         <item>\math</item>
0040                         <item>\mathematics</item>
0041                         <item>\formula</item>
0042                 </list>
0043                 <list name="startEnvironments">
0044                         <item>\bTABLEhead</item>
0045                         <item>\bTABLEnext</item>
0046                         <item>\bTABLEbody</item>
0047                         <item>\bTABLEfoot</item>
0048                         <item>\bTABLE</item>
0049                         <item>\bTR</item>
0050                         <item>\bTD</item>
0051                 </list>
0052                 <list name="stopEnvironments">
0053                         <item>\eTABLEhead</item>
0054                         <item>\eTABLEnext</item>
0055                         <item>\eTABLEbody</item>
0056                         <item>\eTABLEfoot</item>
0057                         <item>\eTABLE</item>
0058                         <item>\eTR</item>
0059                         <item>\eTD</item>
0060                 </list>
0061                 <list name="startMetaPost">
0062                         <item>\startMPinclusions</item>
0063                         <item>\startuseMPgraphic</item>
0064                         <item>\startreusableMPgraphic</item>
0065                         <item>\startstaticMPfigure</item>
0066                         <item>\startuniqueMPgraphic</item>
0067                         <item>\startMPpage</item>
0068                         <item>\startMPcode</item>
0069                         <item>\startMP</item>
0070                 </list>
0071                 <list name="stopMetaPost">
0072                         <item>\stopMPinclusions</item>
0073                         <item>\stopuseMPgraphic</item>
0074                         <item>\stopreusableMPgraphic</item>
0075                         <item>\stopstaticMPfigure</item>
0076                         <item>\stopuniqueMPgraphic</item>
0077                         <item>\stopMPpage</item>
0078                         <item>\stopMPcode</item>
0079                         <item>\stopMP</item>
0080                 </list>
0081 
0082                 <contexts>
0083                         <!-- Normal text -->
0084                         <context name="Normal Text" attribute="Normal Text" lineEndContext="#stay">
0085                                 <keyword      String="titles"        attribute="Section" context="#stay"/>
0086                                 <Detect2Chars char="$" char1="$"     attribute="Block" context="MathModeDisplay"/>
0087                                 <DetectChar   char="$"               attribute="Block" context="MathMode"/>
0088                                 <keyword      String="mathMacros"    attribute="Block" context="MathModeMacroFind"/>
0089                                 <StringDetect String="\startformula" attribute="Block" context="MathModeFormula" beginRegion="mathModeBlock"/>
0090                                 <StringDetect String="\starttyping"  attribute="Block" context="Verbatim"        beginRegion="typingBlock"/>
0091                                 <StringDetect String="\startluacode" attribute="Block" context="LuaCode"         beginRegion="luaBlock"/>
0092                                 <StringDetect String="\startLUA"     attribute="Block" context="LuaCode"         beginRegion="luaBlock"/>
0093                                 <StringDetect String="\startXML"     attribute="Block" context="XmlCode"         beginRegion="xmlBlock"/>
0094                                 <keyword      String="startMetaPost" attribute="Block" context="MetaPostCode"    beginRegion="metaPostBlock"/>
0095                                 <IncludeRules context="Common"/>
0096                         </context>
0097 
0098                         <!-- Comment -->
0099                         <context name="Comment" attribute="Comment" lineEndContext="#pop">
0100                                 <IncludeRules context="##Comments"/>
0101                         </context>
0102 
0103                         <!-- Math Modes -->
0104                         <context name="MathMode" attribute="Math" lineEndContext="#stay">
0105                                 <DetectChar   char="$"               attribute="Block" context="#pop"/>
0106                                 <StringDetect String="\stopformula"  attribute="Error" context="#stay" />
0107                                 <IncludeRules context="MathModeCommon"/>
0108                         </context>
0109                         <context name="MathModeMacroFind" attribute="Math" lineEndContext="#stay">
0110                                 <DetectChar   char="{"             attribute="Brace" context="#pop!MathModeMacro"/>
0111                                 <RegExpr      String="&macro;"     attribute="Macro" context="#pop"/> <!-- Single token -->
0112                                 <RegExpr      String="[[:graph:]]" attribute="Math"  context="#pop"/> <!-- Single token -->
0113                         </context>
0114                         <context name="MathModeMacro" attribute="Math" lineEndContext="#stay">
0115                                 <DetectChar   char="{"               attribute="Brace" context="MathModeMacro"/>
0116                                 <DetectChar   char="}"               attribute="Brace" context="#pop"/>
0117                                 <DetectChar   char="$"               attribute="Error" context="#stay"/>
0118                                 <StringDetect String="\stopformula"  attribute="Error" context="#stay"/>
0119                                 <IncludeRules context="MathModeCommon"/>
0120                         </context>
0121                         <context name="MathModeDisplay" attribute="Math" lineEndContext="#stay">
0122                                 <Detect2Chars char="$" char1="$"     attribute="Block" context="#pop"/>
0123                                 <DetectChar   char="$"               attribute="Error" context="#stay"/>
0124                                 <StringDetect String="\stopformula"  attribute="Error" context="#stay"/>
0125                                 <IncludeRules context="MathModeCommon"/>
0126                         </context>
0127                         <context name="MathModeFormula" attribute="Math" lineEndContext="#stay">
0128                                 <DetectChar   char="$"               attribute="Error" context="#stay"/>
0129                                 <StringDetect String="\stopformula"  attribute="Block" context="#pop" endRegion="mathModeBlock"/>
0130                                 <IncludeRules context="MathModeCommon"/>
0131                         </context>
0132                         <context name="MathModeCommon" attribute="Error" lineEndContext="#stay">
0133                                 <AnyChar      String="^_"            attribute="Brace" context="#stay"/>
0134                                 <StringDetect String="\startformula" attribute="Error" context="#stay"/>
0135                                 <StringDetect String="\text"         attribute="Block" context="MathModeTextFind"/>
0136                                 <IncludeRules context="Common"/>
0137                         </context>
0138                         <!--Math text-->
0139                         <context name="MathModeTextFind" attribute="Normal Text" lineEndContext="#stay" >
0140                                 <DetectChar char="{" attribute="Brace" context="#pop!MathModeText"/>
0141                         </context>
0142                         <context name="MathModeText" attribute="Normal Text" lineEndContext="#stay" >
0143                                 <DetectChar char="{" attribute="Brace" context="MathModeText"/>
0144                                 <DetectChar char="}" attribute="Brace" context="#pop"/>
0145                                 <IncludeRules context="Normal Text"/>
0146                         </context>
0147 
0148                         <!--Verbatim TODO: \startC support-->
0149                         <context name="Verbatim" attribute="Verbatim" lineEndContext="#stay">
0150                                 <StringDetect String="\starttyping" attribute="Verbatim" context="NestedVerbatim"/>
0151                                 <StringDetect String="\stoptyping"  attribute="Block"    context="#pop" endRegion="typingBlock"/>
0152                         </context>
0153 
0154                         <context name="NestedVerbatim" attribute="Verbatim" lineEndContext="#stay">
0155                                 <StringDetect String="\starttyping" attribute="Verbatim" context="NestedVerbatim"/>
0156                                 <StringDetect String="\stoptyping"  attribute="Verbatim" context="#pop"/>
0157                         </context>
0158 
0159                         <context name="MetaPostCode" attribute="Normal Text" lineEndContext="#stay">
0160                                 <keyword      String="stopMetaPost" attribute="Block" context="#pop" endRegion="metaPostBlock"/>
0161                                 <IncludeRules context="##Metapost/Metafont"/>
0162                         </context>
0163 
0164                         <context name="LuaCode" attribute="Normal Text" lineEndContext="#stay">
0165                                 <StringDetect String="\stopluacode" attribute="Block" context="#pop" endRegion="luaBlock"/>
0166                                 <StringDetect String="\stopLUA"     attribute="Block" context="#pop" endRegion="luaBlock"/>
0167                                 <IncludeRules context="##Lua"/>
0168                         </context>
0169 
0170                         <context name="XmlCode" attribute="Normal Text" lineEndContext="#stay">
0171                                 <StringDetect String="\stopXML"     attribute="Block" context="#pop" endRegion="xmlBlock"/>
0172                                 <IncludeRules context="##XML"/>
0173                         </context>
0174 
0175                         <!--Common-->
0176                         <context name="Common" attribute="Error" lineEndContext="#stay">
0177                                 <DetectChar char="%"                    attribute="Comment" context="Comment"/>
0178                                 <RegExpr String="\\start(?:[a-zA-Z_]+)" attribute="Block" context="#stay" beginRegion="block"/>
0179                                 <RegExpr String="\\stop(?:[a-zA-Z_]+)"  attribute="Block" context="#stay" endRegion="block"/>
0180                                 <keyword String="startEnvironments"     attribute="Block" context="#stay" beginRegion="block"/>
0181                                 <keyword String="stopEnvironments"      attribute="Block" context="#stay" endRegion="block"/>
0182                                 <RegExpr String="&macro;"               attribute="Macro" context="#stay"/>
0183                                 <DetectChar char="{"                    attribute="Brace" context="#stay" beginRegion="block"/>
0184                                 <DetectChar char="}"                    attribute="Brace" context="#stay" endRegion="block"/>
0185                         </context>
0186                 </contexts>
0187 
0188                 <itemDatas>
0189                         <itemData name="Normal Text" defStyleNum="dsNormal"                            /><!--(Hi, I’m text)-->
0190                         <itemData name="Comment"     defStyleNum="dsComment"                           /><!--(%Comment)-->
0191                         <itemData name="Section"     defStyleNum="dsKeyword"                           /><!--\section{(Fancy!)}-->
0192                         <itemData name="Brace"       defStyleNum="dsChar"         spellChecking="false"/><!--({})-->
0193                         <itemData name="Math"        defStyleNum="dsOthers"       spellChecking="false"/><!--($5$)-->
0194                         <itemData name="Macro"       defStyleNum="dsFunction"     spellChecking="false"/><!--(\foo)-->
0195                         <itemData name="Block"       defStyleNum="dsRegionMarker" spellChecking="false"/><!--\start(bar), \stop(bar)-->
0196                         <itemData name="Error"       defStyleNum="dsError"        spellChecking="false"/><!--$($$)-->
0197                         <itemData name="Verbatim"    defStyleNum="dsString"       spellChecking="false"/><!--\starttyping(eggs)\stoptyping, \definetyping[C] \startC(umm…)\stopC-->
0198                 </itemDatas>
0199         </highlighting>
0200 
0201         <general>
0202                 <keywords weakDeliminator="\" wordWrapDeliminator=",{}[]"/>
0203                 <comments>
0204                         <comment name="singleLine" start="%" />
0205                 </comments>
0206         </general>
0207 
0208         <spellchecking>
0209                 <encodings>
0210                         <encoding string="''" ignored="true" />
0211                 </encodings>
0212         </spellchecking>
0213 </language>
0214 
0215 <!-- kate: space-indent off; indent-width 4; -->