Damson/assets/syntax/antlr.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
3.3 KiB
XML

<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE language><language name="ANTLR" section="Sources" version="2" kateversion="5.62" extensions="*.g4" mimetype="" priority="1" author="Andrzej Borucki ([email protected])" license="MIT"><highlighting><list name="keywords"><item>catch</item><item>finally</item><item>fragment</item><item>grammar</item><item>import</item><item>lexer</item><item>locals</item><item>mode</item><item>parser</item><item>private</item><item>protected</item><item>public</item><item>returns</item><item>throws</item></list><contexts><context name="Normal" attribute="Normal Text"><DetectSpaces/><IncludeRules context="match keywords"/><IncludeRules context="match attributes"/><IncludeRules context="match symbol"/><IncludeRules context="find literal"/><IncludeRules context="find charset"/><IncludeRules context="MatchComment"/><DetectIdentifier/></context><context name="Comment 1" attribute="Comment" lineEndContext="#pop"><LineContinue attribute="Comment"/><IncludeRules context="##Comments"/></context><context name="Comment 2" attribute="Comment"><StringDetect String="*/" attribute="Comment" context="#pop" endRegion="Comment"/><IncludeRules context="##Comments"/></context><context name="MatchComment" attribute="Normal Text" fallthroughContext="#pop" lineEndContext="#pop"><StringDetect String="//" attribute="Comment" context="#pop!Comment 1"/><StringDetect String="/*" attribute="Comment" context="#pop!Comment 2" beginRegion="Comment"/></context><context name="find charset" attribute="Normal Text" lineEndContext="#pop"><DetectChar char="[" attribute="Charset" context="match charset"/></context><context name="find literal" attribute="Normal Text" lineEndContext="#pop"><DetectChar char="'" attribute="String" context="match literal"/></context><context name="match attributes" attribute="Normal Text" lineEndContext="#pop"><RegExpr String="(options|tokens|channels)(?=([\s]*{))" attribute="Attribute"/></context><context name="match charset" attribute="Charset" lineEndContext="#pop"><StringDetect String="\\" attribute="Charset"/><StringDetect String="\]" attribute="Charset"/><DetectChar char="]" attribute="Charset" context="#pop"/></context><context name="match keywords" attribute="Normal Text" lineEndContext="#pop"><keyword String="keywords" attribute="Keyword"/></context><context name="match literal" attribute="String" lineEndContext="#pop"><StringDetect String="\\" attribute="String"/><StringDetect String="\'" attribute="String"/><DetectChar char="'" attribute="String" context="#pop"/></context><context name="match symbol" attribute="Normal Text"><StringDetect String="->" attribute="Symbol"/><AnyChar String="{};=,:|*?()+~" attribute="Symbol"/></context></contexts><itemDatas><itemData name="Normal Text" defStyleNum="dsNormal" spellChecking="0"/><itemData name="Comment" defStyleNum="dsComment"/><itemData name="Keyword" defStyleNum="dsKeyword" spellChecking="0"/><itemData name="String" defStyleNum="dsString" spellChecking="0"/><itemData name="Charset" defStyleNum="dsChar" spellChecking="0"/><itemData name="Attribute" defStyleNum="dsAttribute" spellChecking="0"/><itemData name="Symbol" defStyleNum="dsOperator" spellChecking="0"/></itemDatas></highlighting><general><comments><comment name="singleLine" start="//" position="afterwhitespace"/><comment name="multiLine" start="/*" end="*/" region="Comment"/></comments></general></language>