diff options
Diffstat (limited to 'kate/data/rest.xml')
-rw-r--r-- | kate/data/rest.xml | 62 |
1 files changed, 62 insertions, 0 deletions
diff --git a/kate/data/rest.xml b/kate/data/rest.xml new file mode 100644 index 000000000..a97524ec7 --- /dev/null +++ b/kate/data/rest.xml @@ -0,0 +1,62 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE language SYSTEM "language.dtd" +[ + <!ENTITY inlinestart "(^|[\s'"\(\[-{</:‘“’«¡¿‐‑‒–— ])"> + <!ENTITY inlineend "([\s’”»‐‑‒–— '"\)\]}>-/:\.,;!\?\\]|$)"> + <!ENTITY SimpleReferenceNameChars "\w-_\.:\+"> +]> +<!-- Copyright Matt Williams <matt@milliams.com> June 2010 --> +<language name="reStructuredText" extensions="*.rst" section="Markup" mimetype="text/x-rst" version="1.01" kateversion="2.4" casesensitive="1"> + + <highlighting> + + <contexts> + <context name="Normal" attribute="Normal" lineEndContext="#stay"> + <RegExpr attribute="Bold" context="#stay" String="&inlinestart;\*\*[^\s].*\*\*&inlineend;" minimal="true"/> + <RegExpr attribute="Italic" context="#stay" String="&inlinestart;\*[^\s].*\*&inlineend;" minimal="true"/> + <RegExpr attribute="InlineLiteral" context="#stay" String="&inlinestart;``[^\s].*``&inlineend;" minimal="true"/> + <RegExpr attribute="SubstitutionReference" context="#stay" String="&inlinestart;\|[^\s].*\|&inlineend;" minimal="true"/> + <RegExpr attribute="InlineInternalTarget" context="#stay" String="&inlinestart;_`[^\s].*`&inlineend;" minimal="true"/> + <RegExpr attribute="Normal" context="#stay" String="&inlinestart;\[[^\s].*\]&inlineend;" minimal="true"/> <!--This is to stop greedy matching of [foo]--> + <RegExpr attribute="FootnoteReference" context="#stay" String="&inlinestart;\[[^\s].*\]_&inlineend;" minimal="true"/> + <RegExpr attribute="HyperlinkRefOrInterpretedText" context="#stay" String="&inlinestart;`[^\s].*(`|`_)&inlineend;" minimal="true"/> + <RegExpr attribute="HyperlinkReference" context="#stay" String="\w+_(\s|$)" minimal="true"/> + <DetectChar attribute="Field" context="Field" firstNonSpace="true" char=":"/> + <RegExpr attribute="Footnote" context="#stay" String="^\s*\.\. \[(\d+|#|\*|#[&SimpleReferenceNameChars;]+)\]\s" minimal="true" firstNonSpace="true"/> + <RegExpr attribute="Citation" context="#stay" String="^\s*\.\. \[[&SimpleReferenceNameChars;]+\]\s" minimal="true" firstNonSpace="true"/> + <RegExpr attribute="HyperlinkTarget" context="#stay" String="^\s*(\.\. (__:|_[&SimpleReferenceNameChars; ]+:(\s|$))|__ )" minimal="true" firstNonSpace="true"/> + <RegExpr attribute="Directive" context="#stay" String="^\s*\.\. [\w-_\.]+::(\s|$)" minimal="true" firstNonSpace="true"/> + <RegExpr attribute="SubstitutionDefinition" context="#stay" String="^\s*\.\. \|[&SimpleReferenceNameChars; ]+\|\s+[&SimpleReferenceNameChars;]+::\s" minimal="true" firstNonSpace="true"/> + </context> + <context name="Field" attribute="Field" lineEndContext="#stay"> + <DetectChar attribute="Field" context="#pop" char=":"/> + <Detect2Chars attribute="Field" context="#stay" char="\" char1=":"/> + </context> + </contexts> + + <itemDatas> + <itemData name="Normal" defStyleNum="dsNormal" /> + <itemData name="Bold" defStyleNum="dsNormal" bold="1" /> + <itemData name="Italic" defStyleNum="dsNormal" italic="1" /> + <itemData name="InlineLiteral" defStyleNum="dsString" /> + <itemData name="SubstitutionReference" defStyleNum="dsFunction" /> + <itemData name="InlineInternalTarget" defStyleNum="dsFunction" /> + <itemData name="FootnoteReference" defStyleNum="dsOthers" /> + <itemData name="HyperlinkRefOrInterpretedText" defStyleNum="dsOthers" /> + <itemData name="HyperlinkReference" defStyleNum="dsOthers" /> + <itemData name="Monospaced" defStyleNum="dsNormal" color="#006600" /> + <itemData name="Field" defStyleNum="dsFunction" /> + <itemData name="Footnote" defStyleNum="dsDataType" /> + <itemData name="Citation" defStyleNum="dsDataType" /> + <itemData name="HyperlinkTarget" defStyleNum="dsDataType" /> + <itemData name="Directive" defStyleNum="dsDataType" /> + <itemData name="SubstitutionDefinition" defStyleNum="dsDataType" /> + </itemDatas> + + </highlighting> + + <general> + <folding indentationsensitive="true" /> + </general> + +</language> |