Damson/assets/syntax/groovy.xml
astar76 11c1a7808b Build the syntax definitions into the app
Highlighting relied on the syntax-highlighting package, so removing it
left every file uncoloured. The 462 definitions now live in assets/syntax
and are compressed into the binary at build time, unpacked per language
when used. User .xml files still add to or replace them, and the licence
each file declares is recorded in assets/syntax/LICENSES.md.

Also moves files to the trash without needing gio.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-06 20:35:27 -06:00

1 line
No EOL
9.7 KiB
XML

<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE language><language name="Groovy" version="12" kateversion="5.79" section="Sources" extensions="*.groovy;*.gradle;*.gvy;Jenkinsfile" license="LGPL" author="Chris Reeves ([email protected])"><highlighting><list name="java15"><include>java15##Java</include></list><list name="keywords"><item>abstract</item><item>as</item><item>assert</item><item>class</item><item>default</item><item>enum</item><item>extends</item><item>false</item><item>implements</item><item>import</item><item>in</item><item>instanceof</item><item>interface</item><item>native</item><item>new</item><item>null</item><item>package</item><item>super</item><item>this</item><item>throws</item><item>trait</item><item>true</item><item>var</item></list><list name="control flow"><item>break</item><item>case</item><item>catch</item><item>continue</item><item>do</item><item>else</item><item>finally</item><item>for</item><item>goto</item><item>if</item><item>return</item><item>switch</item><item>throw</item><item>try</item><item>while</item></list><list name="types"><item>boolean</item><item>byte</item><item>char</item><item>def</item><item>double</item><item>float</item><item>int</item><item>long</item><item>short</item><item>void</item></list><contexts><context name="Normal" attribute="Normal Text"><DetectSpaces/><DetectChar char="." attribute="Symbol" context="Dot" lookAhead="1"/><DetectChar char="{" attribute="Symbol" context="AfterSymbol" beginRegion="Brace1"/><DetectChar char="}" attribute="Symbol" context="AfterSymbol" endRegion="Brace1"/><IncludeRules context="##Javadoc"/><StringDetect String="//" attribute="Comment" context="Commentar 1"/><StringDetect String="/*" attribute="Comment" context="Commentar 2" beginRegion="Comment"/><AnyChar String="()[]&amp;|+,-/*&lt;=>;!%?:~^" attribute="Symbol" context="AfterSymbol"/><AnyChar String="0123456789" context="Number" lookAhead="1"/><DetectChar char="'" attribute="String" context="StringSQ"/><DetectChar char='"' attribute="String" context="StringDQ"/><StringDetect String="$/" attribute="String" context="StringDollarSlashy"/><keyword String="keywords" attribute="Keyword"/><keyword String="control flow" attribute="Control Flow"/><keyword String="types" attribute="Data Type"/><keyword String="java15" attribute="Java15"/><RegExpr String="\b[_a-zA-Z]\w*(?=[\s]*(/\*\s*\d+\s*\*/\s*)?[(])" attribute="Function"/><DetectIdentifier attribute="Normal Text"/></context><context name="StringEscapedChar" attribute="String" lineEndContext="#pop"><HlCStringChar attribute="String Char" context="#pop"/><RegExpr String="\\u[0-9a-fA-F]{4}" attribute="String Char" context="#pop"/><RegExpr String="\\(u[0-9a-fA-F]*|.)?" attribute="Error" context="#pop"/></context><context name="AfterSymbol" attribute="Normal Text" fallthroughContext="#pop"><DetectSpaces attribute="Normal Text"/><StringDetect String="//" attribute="Comment" context="#pop!Commentar 1"/><DetectChar char="/" attribute="String" context="#pop!StringSlashy"/></context><context name="Commentar 1" attribute="Comment" lineEndContext="#pop"><DetectSpaces/><IncludeRules context="##Comments"/></context><context name="Interpolation" attribute="String" fallthroughContext="#pop"><DetectChar char="{" attribute="String Interpolation" context="#pop!InInterpolation"/><DetectIdentifier attribute="String Interpolation" context="#pop!InterpolationIdent"/></context><context name="StringIn3DQ" attribute="String"><DetectChar char="$" attribute="String Interpolation" context="Interpolation"/><DetectChar char="\" context="StringEscapedChar" lookAhead="1"/><StringDetect String='"""' attribute="String" context="#pop"/></context><context name="StringIn3SQ" attribute="String"><DetectChar char="\" context="StringEscapedChar" lookAhead="1"/><StringDetect String="'''" attribute="String" context="#pop"/></context><context name="FindFloat" attribute="Normal Text"><RegExpr String="(\b(?:[0-9]++(_++[0-9]++)*+)(\.(((?:[0-9]++(_++[0-9]++)*+)(?:[eE][-+]?(?:[0-9]++(_++[0-9]++)*+))?+|(?:[eE][-+]?(?:[0-9]++(_++[0-9]++)*+)))[fFdD]?\b|[dDfFgG]\b)?|(?:[eE][-+]?(?:[0-9]++(_++[0-9]++)*+))[fFdD]?\b|[dDfFgG]\b)|\.(?:[0-9]++(_++[0-9]++)*+)(?:[eE][-+]?(?:[0-9]++(_++[0-9]++)*+))?[dDfFgG]?\b)|\b0[xX]((?:[0-9a-fA-F]++(_++[0-9a-fA-F]++)*+)\.?+(?:[0-9a-fA-F]++(_++[0-9a-fA-F]++)*+)?+|\.(?:[0-9a-fA-F]++(_++[0-9a-fA-F]++)*+)?)[pP][-+]?(?:[0-9]++(_++[0-9]++)*+)[dDfFgG]?\b" attribute="Float" context="#pop"/></context><context name="InInterpolation" attribute="String Interpolation"><DetectChar char="}" attribute="String Interpolation" context="#pop"/><IncludeRules context="Normal"/></context><context name="InterpolationIdent" attribute="String Interpolation" fallthroughContext="#pop" lineEndContext="#pop"><DetectChar char="." attribute="Symbol" context="InterpolationMember"/></context><context name="StringSlashy" attribute="String"><DetectChar char="$" attribute="String Interpolation" context="Interpolation"/><DetectChar char="\" context="StringSlashyEscapedChar" lookAhead="1"/><DetectChar char="/" attribute="String" context="#pop"/></context><context name="Commentar 2" attribute="Comment"><StringDetect String="*/" attribute="Comment" context="#pop" endRegion="Comment"/><DetectSpaces/><IncludeRules context="##Comments"/></context><context name="Dot" attribute="Normal Text"><IncludeRules context="FindFloat"/><DetectChar char="." attribute="Symbol" context="#pop!Member"/></context><context name="InterpolationDollarSlashy" attribute="String"><StringDetect String="${" attribute="String Interpolation" context="#pop!InInterpolation"/><StringDetect String="$$" attribute="String Char" context="#pop"/><StringDetect String="$/" attribute="String Char" context="#pop"/><RegExpr String="\$[_a-zA-Z]\w*" attribute="String Interpolation" context="#pop!InterpolationIdent"/><DetectChar char="$" attribute="String" context="#pop"/></context><context name="InterpolationMember" attribute="String Interpolation" fallthroughContext="#pop#pop"><DetectIdentifier attribute="String Interpolation" context="#pop"/></context><context name="Member" attribute="Normal Text" fallthroughContext="#pop"><DetectSpaces attribute="Normal Text"/><RegExpr String="\b[_a-zA-Z]\w*(?=[\s]*(/\*\s*\d+\s*\*/\s*)?[({'&#34;])" attribute="Function" context="#pop"/><StringDetect String="//" attribute="Comment" context="#pop!Commentar 1"/><DetectChar char="/" attribute="String" context="#pop!StringSlashy"/></context><context name="Number" attribute="Normal Text"><IncludeRules context="FindFloat"/><RegExpr String="\b0[xX](?:[0-9a-fA-F]++(_++[0-9a-fA-F]++)*+)[lL]?\b" attribute="Hex" context="#pop"/><RegExpr String="\b0[bB][01]++(_++[01]++)*+[gGiIlL]?\b" attribute="Binary" context="#pop"/><RegExpr String="\b0_*+[0-7]++(_++[0-7_]++)*+[gGiIlL]?\b" attribute="Octal" context="#pop"/><RegExpr String="\b(0|[1-9][0-9]*+(_++[0-9_]++)*+)[gGiIlL]?\b" attribute="Decimal" context="#pop"/><AnyChar String="0123456789" attribute="Error" context="#pop"/></context><context name="String3DQ" attribute="String" fallthroughContext="#pop!StringIn3DQ" lineEndContext="#pop!StringIn3DQ"><LineContinue attribute="Symbol" context="#pop!StringIn3DQ"/></context><context name="String3SQ" attribute="String" fallthroughContext="#pop!StringIn3SQ" lineEndContext="#pop!StringIn3SQ"><LineContinue attribute="Symbol" context="#pop!StringIn3SQ"/></context><context name="StringDQ" attribute="String" fallthroughContext="#pop!StringInDQ" lineEndContext="#pop"><StringDetect String='""' attribute="String" context="#pop!String3DQ"/><DetectChar char='"' attribute="String" context="#pop"/></context><context name="StringDollarSlashy" attribute="String"><DetectChar char="$" context="InterpolationDollarSlashy" lookAhead="1"/><StringDetect String="/$" attribute="String" context="#pop"/></context><context name="StringInDQ" attribute="String" lineEndContext="#pop"><DetectChar char="$" attribute="String Interpolation" context="Interpolation"/><DetectChar char="\" context="StringEscapedChar" lookAhead="1"/><DetectChar char='"' attribute="String" context="#pop"/></context><context name="StringInSQ" attribute="String" lineEndContext="#pop"><DetectChar char="\" context="StringEscapedChar" lookAhead="1"/><DetectChar char="'" attribute="String" context="#pop"/></context><context name="StringSQ" attribute="String" fallthroughContext="#pop!StringInSQ" lineEndContext="#pop"><StringDetect String="''" attribute="String" context="#pop!String3SQ"/><DetectChar char="'" attribute="String" context="#pop"/></context><context name="StringSlashyEscapedChar" attribute="String" lineEndContext="#pop"><StringDetect String="\/" attribute="String" context="#pop"/><IncludeRules context="StringEscapedChar"/></context></contexts><itemDatas><itemData name="Normal Text" defStyleNum="dsNormal"/><itemData name="Keyword" defStyleNum="dsKeyword"/><itemData name="Control Flow" defStyleNum="dsControlFlow" spellChecking="0"/><itemData name="Function" defStyleNum="dsFunction"/><itemData name="Data Type" defStyleNum="dsDataType"/><itemData name="Decimal" defStyleNum="dsDecVal" spellChecking="0"/><itemData name="Octal" defStyleNum="dsBaseN" spellChecking="0"/><itemData name="Hex" defStyleNum="dsBaseN" spellChecking="0"/><itemData name="Binary" defStyleNum="dsBaseN" spellChecking="0"/><itemData name="Float" defStyleNum="dsFloat" spellChecking="0"/><itemData name="String" defStyleNum="dsString"/><itemData name="String Char" defStyleNum="dsSpecialChar"/><itemData name="String Interpolation" defStyleNum="dsSpecialString"/><itemData name="Comment" defStyleNum="dsComment"/><itemData name="Symbol" defStyleNum="dsOperator"/><itemData name="Java15" defStyleNum="dsBuiltIn" bold="1" italic="0"/><itemData name="Error" defStyleNum="dsError" spellChecking="0"/></itemDatas></highlighting><general><comments><comment name="singleLine" start="//"/><comment name="multiLine" start="/*" end="*/" region="Comment"/></comments><keywords casesensitive="1"/></general></language>