From bc4417bd36aab0498775b5aef30b09968664d1f0 Mon Sep 17 00:00:00 2001 From: Yudai NAKATA Date: Sat, 16 Jul 2016 19:04:04 +0900 Subject: [PATCH] add prototypical highlight for expl3 syntax fix area/language-latex#48, but still problematic because other highlights such as % sign are overridden and invalid --- grammars/latex.cson | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/grammars/latex.cson b/grammars/latex.cson index 257eb44..0f966b5 100644 --- a/grammars/latex.cson +++ b/grammars/latex.cson @@ -84,6 +84,22 @@ } ] } + { + 'begin': '(\\\\ExplSyntaxOn|\\\\ProvidesExplPackage)' + 'beginCaptures': + '0': + 'name': 'support.function.ExplSyntax.tex' + 'patterns':[ + { + 'match': '(\\\\)[A-Za-z@_]+(:[nNpTFDwcVvxof]+)?' + 'name': 'support.function.expl3.tex' + } + ] + 'end': '\\\\ExplSyntaxOff' + 'endCaptures': + '0': + 'name': 'support.function.ExplSyntax.tex' + } { 'begin': '(((\\\\)begin)(\\{)(minted)(\\})(?:(\\[).*(\\]))?\{.*\}(\\s*%.*\\n?)?)' 'captures':