summaryrefslogtreecommitdiff
path: root/context/data/scite/lexers/scite-context-lexer-tex.lua
diff options
context:
space:
mode:
authorMarius <mariausol@gmail.com>2011-12-31 17:00:24 +0200
committerMarius <mariausol@gmail.com>2011-12-31 17:00:24 +0200
commit8e9d274c8a72b93fb1ab1a98d404b396ec8eae22 (patch)
tree5087a4b95a3688dcf2c11d06e5f94f1379158a24 /context/data/scite/lexers/scite-context-lexer-tex.lua
parent11dde3f4c6c0584ff20070edc1b1aad0b9013d30 (diff)
downloadcontext-8e9d274c8a72b93fb1ab1a98d404b396ec8eae22.tar.gz
beta 2011.12.31 15:44
Diffstat (limited to 'context/data/scite/lexers/scite-context-lexer-tex.lua')
-rw-r--r--context/data/scite/lexers/scite-context-lexer-tex.lua7
1 files changed, 6 insertions, 1 deletions
diff --git a/context/data/scite/lexers/scite-context-lexer-tex.lua b/context/data/scite/lexers/scite-context-lexer-tex.lua
index f7ba0a8e6..a7c044f6d 100644
--- a/context/data/scite/lexers/scite-context-lexer-tex.lua
+++ b/context/data/scite/lexers/scite-context-lexer-tex.lua
@@ -394,7 +394,9 @@ local stoplua = P("\\stop") * Cmt(luaenvironment,stopdisplaylua)
local startluacode = token("embedded", startlua)
local stopluacode = token("embedded", stoplua)
-local metafunenvironment = ( P("use") + P("reusable") + P("unique") ) * ("MPgraphic")
+local metafuncall = ( P("use") + P("reusable") + P("unique") ) * ("MPgraphic")
+
+local metafunenvironment = metafuncall -- ( P("use") + P("reusable") + P("unique") ) * ("MPgraphic")
+ P("MP") * ( P("code")+ P("page") + P("inclusions") + P("initializations") + P("definitions") + P("extensions") + P("graphic") )
local startmetafun = P("\\start") * metafunenvironment
@@ -409,6 +411,8 @@ local metafunarguments = (spacing^0 * openargument * argumentcontent * clo
local startmetafuncode = token("embedded", startmetafun) * metafunarguments
local stopmetafuncode = token("embedded", stopmetafun)
+local callers = token("embedded", P("\\") * metafuncall) * metafunarguments
+
lexer.embed_lexer(contextlexer, cldlexer, startluacode, stopluacode)
lexer.embed_lexer(contextlexer, mpslexer, startmetafuncode, stopmetafuncode)
@@ -422,6 +426,7 @@ _rules = {
{ "text", text }, -- non words
{ "comment", comment },
{ "constant", constant },
+ { "callers", callers },
{ "helper", helper },
{ "command", command },
{ "primitive", primitive },