summaryrefslogtreecommitdiffstats
path: root/kate/data/restructuredtext.xml
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2014-01-09 00:24:34 +0100
committerSlávek Banko <slavek.banko@axis.cz>2014-01-09 00:24:34 +0100
commitbf4e405e03859bf383f55715944f4f71bd338c34 (patch)
tree293783d05c079b477b9ef396bbd851ca01714e2d /kate/data/restructuredtext.xml
parentc5189a79b8621b38b53e3cec952d49630e16dd3a (diff)
downloadtdelibs-bf4e405e03859bf383f55715944f4f71bd338c34.tar.gz
tdelibs-bf4e405e03859bf383f55715944f4f71bd338c34.zip
Update kate syntax highlight files
Diffstat (limited to 'kate/data/restructuredtext.xml')
-rw-r--r--kate/data/restructuredtext.xml59
1 files changed, 59 insertions, 0 deletions
diff --git a/kate/data/restructuredtext.xml b/kate/data/restructuredtext.xml
new file mode 100644
index 000000000..c798e8f43
--- /dev/null
+++ b/kate/data/restructuredtext.xml
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE language SYSTEM "language.dtd">
+<language name="Restructured Text" version="1.01" kateversion="2.5" section="Markup" extensions="*.rst" author="Massimiliano Torromeo (massimiliano.torromeo@gmail.com)" license="LGPL">
+
+ <highlighting>
+ <contexts>
+ <context name="Normal" attribute="Normal Text" lineEndContext="#stay">
+ <RegExpr attribute="Emphasys" String="\*[^* ].*\S\*" context="#stay" />
+ <RegExpr attribute="Strong" String="\*\*\S.*\S\*\*" context="#stay" />
+ <RegExpr attribute="Literal" String="``\S.*\S``" context="#stay" />
+ <RegExpr attribute="Directive" String="^\.\. " context="Directive" />
+ <RegExpr attribute="Title" String="^(#{3,}|\*{3,}|={3,}|-{3,}|\^{3,}|&quot;{3,}|&apos;{3,}|~{3,}|`{3,}|\+{3,})$" context="#stay" />
+ <RegExpr attribute="OrderedList" String="[#0-9]\.\s" firstNonSpace="1" context="#stay" />
+ <AnyChar attribute="UnorderedList" String="*+-" firstNonSpace="1" context="#stay" />
+ <DetectChar attribute="Link" char="`" context="Link" />
+ <RegExpr attribute="Code" String="::$" context="CodeBlock" />
+ </context>
+
+ <context name="CodeBlock" attribute="Code" lineEndContext="#stay">
+ <RegExpr attribute="Code" String="^\s" context="Code" />
+ </context>
+
+ <context name="Code" attribute="Code" lineEndContext="#stay">
+ <RegExpr attribute="Normal" String="^\S" lookAhead="true" context="#pop#pop" />
+ </context>
+
+ <context name="Directive" attribute="Directive" lineEndContext="#pop">
+ <RegExpr attribute="Keyword" String="\w+" context="#stay" />
+ </context>
+
+ <context name="Link" attribute="Link" lineEndContext="#pop">
+ <DetectChar attribute="Link" char="&lt;" context="URL" />
+ <Detect2Chars attribute="Link" char="`" char1="_" context="#pop" />
+ </context>
+
+ <context name="URL" attribute="LinkUrl" lineEndContext="#stay">
+ <RegExpr attribute="LinkUrl" String="[^&gt;]+" context="#stay" />
+ <DetectChar attribute="Link" char="&gt;" context="#pop" />
+ </context>
+ </contexts>
+
+ <itemDatas>
+ <itemData name="Normal Text" defStyleNum="dsNormal" />
+ <itemData name="Directive" defStyleNum="dsDecVal" />
+ <itemData name="Emphasys" defStyleNum="dsNormal" italic="1" />
+ <itemData name="Strong" defStyleNum="dsNormal" bold="1" />
+ <itemData name="Literal" defStyleNum="dsDataType" />
+ <itemData name="Keyword" defStyleNum="dsKeyword" />
+ <itemData name="OrderedList" defStyleNum="dsDecVal" />
+ <itemData name="UnorderedList" defStyleNum="dsFloat" />
+ <itemData name="Link" defStyleNum="dsString" />
+ <itemData name="LinkUrl" defStyleNum="dsString" bold="1" />
+ <itemData name="Title" defStyleNum="dsKeyword" bold="1" />
+ <itemData name="Code" defStyleNum="dsDataType" />
+ <itemData name="Error" defStyleNum="dsError" />
+ </itemDatas>
+
+ </highlighting>
+</language>