Changeset View
Changeset View
Standalone View
Standalone View
data/syntax/java-properties.xml
- This file was added.
1 | <?xml version="1.0" encoding="UTF-8"?> | ||||
---|---|---|---|---|---|
2 | <!DOCTYPE language SYSTEM "language.dtd"> | ||||
3 | <language name="Java Properties" version="2" kateversion="5.0" section="Other" extensions="*.properties" author="Matthias Böhm (MatthiasBoehm87 _at_ gmail.com)" license="MIT"> | ||||
4 | <highlighting> | ||||
5 | <contexts> | ||||
6 | <context name="key" attribute="Key" lineEndContext="#stay"> | ||||
7 | <RegExpr String="^[=:]$" attribute="Separator" context="key" column="0"/> | ||||
8 | <DetectChar char="=" attribute="Separator" context="value" column="0"/> | ||||
9 | <DetectChar char=":" attribute="Separator" context="value" column="0"/> | ||||
10 | <DetectChar char="#" attribute="Comment" context="comment" firstNonSpace="true"/> | ||||
11 | <DetectChar char="!" attribute="Comment" context="comment" firstNonSpace="true"/> | ||||
12 | <RegExpr String="(?:[^=:\s\\]|\\.)*\s*(?==|:)" attribute="Key" context="separator"/> | ||||
13 | <RegExpr String="(?:[^=:\s\\]|\\.)+\s+(?=\S)" attribute="Key" context="value"/> | ||||
14 | </context> | ||||
15 | <context name="separator" attribute="Key" lineEndContext="#pop" > | ||||
16 | <LineContinue char="=" attribute="Separator" context="#pop" /> | ||||
17 | <LineContinue char=":" attribute="Separator" context="#pop" /> | ||||
18 | <AnyChar String="=:" attribute="Separator" context="#pop!value"/> | ||||
19 | </context> | ||||
20 | <context name="value" attribute="Value" lineEndContext="#stay"> | ||||
21 | <RegExpr String="(?:[^\\]|\\.)*$" attribute="Value" context="#pop!continueWithKey"/> | ||||
22 | <RegExpr String="(?:[^\\]|\\.)*\\$" attribute="Value" context="#pop!continueWithValue"/> | ||||
23 | </context> | ||||
24 | <context name="continueWithKey" attribute="Key" lineEndContext="#pop!key" /> | ||||
25 | <context name="continueWithValue" attribute="Value" lineEndContext="#pop!value" /> | ||||
26 | <context name="comment" attribute="Comment" lineEndContext="#pop" /> | ||||
27 | </contexts> | ||||
28 | <itemDatas> | ||||
29 | <itemData name="Key" spellChecking="false" defStyleNum="dsOthers"/> | ||||
30 | <itemData name="Value" spellChecking="false" defStyleNum="dsString"/> | ||||
31 | <itemData name="Comment" spellChecking="true" defStyleNum="dsComment"/> | ||||
32 | <itemData name="Separator" spellChecking="false" defStyleNum="dsVariable"/> | ||||
33 | </itemDatas> | ||||
34 | </highlighting> | ||||
35 | <general> | ||||
36 | <comments> | ||||
37 | <comment name="singleLine" start="!"/> | ||||
38 | <comment name="singleLine" start="#"/> | ||||
39 | </comments> | ||||
40 | </general> | ||||
41 | </language> |