I am trying to write my own syntax highlighting for gtksourceview. If it's done it should highlight guitar chords in a text file. This is my unfinished file:
<?xml version="1.0" encoding="UTF-8"?>
<language id="tab" _name="Tab" version="2.0" _section="Others">
<metadata>
<property name="mimetypes">text/plain</property>
<property name="globs">*.txt;*.tab</property>
</metadata>
<styles>
<style id="chord" _name="Chord" foreground="blue" bold="true"/>
</styles>
<definitions>
<context id="chord" style-ref="chord" class="no-spell-check">
<match>[A-H]</match>
</context>
<context id="tab">
<include>
<context ref="chord"/>
</include>
</context>
</definitions>
</language>
I would expect every capital A to H to be blue and bold in the highlighted text. Is saved the file to /usr/share/gtksourceview-3.0/language-specs and I am able to select it in GEdit. But nothing is highlighted in the text.
Can anyone tell me what I am doing wrong?