Debian Codegraph @

data/syntax/abc.xml

raw
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE language>
3 <!-- Andrea Primiani - primiani at dag dot it
4 version1.10 - 12 december 2005 -->
5 <language name="ABC" version="8" kateversion="5.0" section="Other" extensions="*.abc;*.ABC" mimetype="text/vnd.abc" casesensitive="1" author="Andrea Primiani ([email protected])" license="LGPL">
6 <highlighting>
7 <contexts>
8 <context name="Normal" attribute="Normal Text" lineEndContext="#stay">
9 <!-- detects tuplet symbols e.g. (3 or (3:2:2-->
10 <RegExpr attribute="Tuplet" context="#stay" String="\([23456789]:?[23456789]?:?[23456789]?" />
11 <!-- detects quoted strings -->
12 <RangeDetect attribute="String" context="#stay" char="&quot;" char1="&quot;"/>
13 <!-- detects decorations delimited by ! ! symbols -->
14 <RangeDetect attribute="Decoration" context="#stay" char="!" char1="!" />
15 <!-- detects single header command delimited by [ and sends to Header context -->
16 <RegExpr attribute="Header" context="Header" String="\[[ABCGHILMNOQRSTUVZ]:" />
17 <!-- detects single header line inside a song without [] - ends at EOL-->
18 <RegExpr attribute="Header" context="Header2" String="[ABCGHILMNOPQRSTUVZ]:" />
19 <!-- detect beginning of header zone with X: and sends to Header context -->
20 <Detect2Chars attribute="Header" context="Header" char="X" char1=":" beginRegion="header" column="0"/>
21 <!-- detects bar beginning (or chord) symbols and sends to Bar context -->
22 <AnyChar attribute="Bar" context="Bar" String="|:[" />
23 <!-- detects ] if used to close chords -->
24 <DetectChar attribute="Bar" context="#stay" char="]" />
25 <!-- detects () for slurs -->
26 <!-- detects {} for gracings -->
27 <AnyChar attribute="Slur" context="#stay" String="(){}" />
28 <!-- detects W: and w: lyric lines -->
29 <Detect2Chars attribute="Lyrics" context="Lyrics" char="W" char1=":" />
30 <Detect2Chars attribute="Lyrics" context="Lyrics" char="w" char1=":" />
31 <!-- detects %% preprocessor lines and % comment lines-->
32 <Detect2Chars attribute="Preprocessor" context="Preprocessor" char="%" char1="%"/>
33 <DetectChar attribute="Comment" context="Comment" char="%" />
34 <!-- detects ^ _ = symbols before a note -->
35 <RegExpr attribute="Sharp" context="#stay" String="[_|\^]?[_|=|\^][A-Ga-g]" />
36 </context>
37 <!-- returns to Normal context at the end of line -->
38 <context name="Preprocessor" attribute="Preprocessor" lineEndContext="#pop" />
39 <context name="Lyrics" attribute="Lyrics" lineEndContext="#pop" />
40 <context name="Comment" attribute="Comment" lineEndContext="#pop">
41 <IncludeRules context="##Comments" />
42 </context>
43 <!-- returns to Normal context after the end of bar symbols or at EOL -->
44 <context name="Bar" attribute="Bar" lineEndContext="#pop" >
45 <DetectChar attribute="Normal Text" context="#pop" char="&quot;" />
46 <!-- the bar symbol ends when a note letter follows -->
47 <RegExpr attribute="Normal Text" context="#pop" String="[A-Ga-gZz]" />
48 <!-- the bar symbol ends after a white space -->
49 <DetectChar attribute="Normal Text" context="#pop" char=" " />
50 <!-- detects decorations delimited by ! ! symbols -->
51 <RangeDetect attribute="Decoration" context="#stay" char="!" char1="!" />
52 <!-- detects () for slurs -->
53 <AnyChar attribute="Slur" context="#stay" String="()" />
54 <!-- chomps all other bar symbols -->
55 <RegExpr attribute="Bar" context="#pop" String=":*\|*[1-9]|/*\|" />
56 </context>
57 <!-- returns to Normal context at the end of header -->
58 <context name="Header" attribute="Header" lineEndContext="#stay">
59 <!-- the header ends after K: line -->
60 <RegExpr attribute="Header" context="#pop" String="^K:.+" endRegion="header" column="0"/>
61 <!-- the single header command ends at the ] char -->
62 <DetectChar attribute="Header" context="#pop" char="]" />
63 </context>
64 <!-- the single header line ends at EOL -->
65 <context name="Header2" attribute="Header" lineEndContext="#pop" />
66 </contexts>
67 <itemDatas>
68 <itemData name="Normal Text" defStyleNum="dsNormal"/>
69 <itemData name="Comment" defStyleNum="dsComment"/>
70 <itemData name="Decoration" defStyleNum="dsFloat" color="#00bbaa" />
71 <itemData name="String" defStyleNum="dsString" bold="true"/>
72 <itemData name="Preprocessor" defStyleNum="dsString" italic="true"/>
73 <itemData name="Header" defStyleNum="dsFloat"/>
74 <itemData name="Slur" defStyleNum="dsDataType" bold="true"/>
75 <itemData name="Tuplet" defStyleNum="dsDataType" color="#bb00bb"/>
76 <itemData name="Lyrics" defStyleNum="dsDataType" color="#00bb00"/>
77 <itemData name="Bar" defStyleNum="dsChar" color="#0000ff"/>
78 <itemData name="Sharp" defStyleNum="dsNormal" color="#22bb66" bold="true"/>
79 </itemDatas>
80 </highlighting>
81 <general>
82 <comments>
83 <comment name="singleLine" start="%" position="afterwhitespace" />
84 </comments>
85 <keywords casesensitive="1" />
86 </general>
87 </language>
88 <!-- kate: replace-tabs off; -->