summaryrefslogtreecommitdiff
path: root/tex/context/base/mkiv/buff-ver.lua
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2018-03-21 09:47:34 +0100
committerContext Git Mirror Bot <phg42.2a@gmail.com>2018-03-21 09:47:34 +0100
commitf47b4939787074397c9ea37c1d892a1f7ccc7290 (patch)
tree7768be58efe0faab8e2dccb999686c6a674bf0d7 /tex/context/base/mkiv/buff-ver.lua
parentf923c957a3b322ae3ee8e7a0b20df1580869bee7 (diff)
downloadcontext-f47b4939787074397c9ea37c1d892a1f7ccc7290.tar.gz
2018-03-21 09:24:00
Diffstat (limited to 'tex/context/base/mkiv/buff-ver.lua')
-rw-r--r--tex/context/base/mkiv/buff-ver.lua9
1 files changed, 5 insertions, 4 deletions
diff --git a/tex/context/base/mkiv/buff-ver.lua b/tex/context/base/mkiv/buff-ver.lua
index a39e90bda..d9178b1df 100644
--- a/tex/context/base/mkiv/buff-ver.lua
+++ b/tex/context/base/mkiv/buff-ver.lua
@@ -14,7 +14,7 @@ if not modules then modules = { } end modules ['buff-ver'] = {
-- todo: update to match context scite lexing
local type, next, rawset, rawget, setmetatable, getmetatable, tonumber = type, next, rawset, rawget, setmetatable, getmetatable, tonumber
-local format, lower, upper,match, find, sub = string.format, string.lower, string.upper, string.match, string.find, string.sub
+local lower, upper,match, find, sub = string.lower, string.upper, string.match, string.find, string.sub
local splitlines = string.splitlines
local concat = table.concat
local C, P, R, S, V, Carg, Cc, Cs = lpeg.C, lpeg.P, lpeg.R, lpeg.S, lpeg.V, lpeg.Carg, lpeg.Cc, lpeg.Cs
@@ -239,12 +239,13 @@ function visualizers.load(name)
name = lower(name)
if rawget(specifications,name) == nil then
name = lower(name)
- local texname = findfile(format("buff-imp-%s.mkiv",name))
- local luaname = findfile(format("buff-imp-%s.lua" ,name))
+ local impname = "buff-imp-"..name
+ local texname = findfile(addsuffix(impname,"mkiv"))
+ local luaname = findfile(addsuffix(impname,"lua"))
if texname == "" or luaname == "" then
-- assume a user specific file
luaname = findfile(addsuffix(name,"mkiv"))
- texname = findfile(addsuffix(name,"lua" ))
+ texname = findfile(addsuffix(name,"lua"))
end
if texname == "" or luaname == "" then
if trace_visualize then