diff options
-rw-r--r-- | scripts/context/lua/mtxrun.lua | 43 | ||||
-rw-r--r-- | scripts/context/stubs/mswin/mtxrun.lua | 43 | ||||
-rwxr-xr-x | scripts/context/stubs/unix/mtxrun | 43 | ||||
-rw-r--r-- | tex/context/base/cont-new.mkii | 2 | ||||
-rw-r--r-- | tex/context/base/cont-new.mkiv | 2 | ||||
-rw-r--r-- | tex/context/base/context.mkii | 2 | ||||
-rw-r--r-- | tex/context/base/context.mkiv | 2 | ||||
-rw-r--r-- | tex/context/base/data-pre.lua | 2 | ||||
-rw-r--r-- | tex/context/base/data-res.lua | 17 | ||||
-rw-r--r-- | tex/context/base/luat-run.lua | 7 | ||||
-rw-r--r-- | tex/context/base/status-files.pdf | bin | 23173 -> 23180 bytes | |||
-rw-r--r-- | tex/context/base/trac-set.lua | 24 | ||||
-rw-r--r-- | tex/generic/context/luatex-fonts-merged.lua | 2 |
13 files changed, 104 insertions, 85 deletions
diff --git a/scripts/context/lua/mtxrun.lua b/scripts/context/lua/mtxrun.lua index 4ada628ea..31d7d9b0f 100644 --- a/scripts/context/lua/mtxrun.lua +++ b/scripts/context/lua/mtxrun.lua @@ -4877,16 +4877,6 @@ local t_enable, t_disable = trackers .enable, trackers .disable local d_enable, d_disable = directives .enable, directives .disable local e_enable, e_disable = experiments.enable, experiments.disable --- experiment - -if trackers and environment and environment.engineflags.trackers then - t_enable(environment.engineflags.trackers) -end - -if directives and environment and environment.engineflags.directives then - d_enable(environment.engineflags.directives) -end - -- nice trick: we overload two of the directives related functions with variants that -- do tracing (itself using a tracker) .. proof of concept @@ -4930,11 +4920,15 @@ end) -- experiment -if trackers and environment and environment.engineflags.trackers then - t_enable(environment.engineflags.trackers) -end -if directives and environment and environment.engineflags.directives then - d_enable(environment.engineflags.directives) +local flags = environment and environment.engineflags + +if flags then + if trackers and flags.trackers then + t_enable(flags.trackers) + end + if directives and flags.directives then + d_enable(flags.directives) + end end -- here @@ -11695,6 +11689,7 @@ end local function findgivenfiles(filename,allresults) local bname, result = filebasename(filename), { } local hashes = instance.hashes + local noffound = 0 for k=1,#hashes do local hash = hashes[k] local files = instance.files[hash.name] or { } @@ -11709,13 +11704,21 @@ local function findgivenfiles(filename,allresults) end if blist then if type(blist) == 'string' then - result[#result+1] = methodhandler('concatinators',hash.type,hash.name,blist,bname) or "" - if not allresults then break end + local found = methodhandler('concatinators',hash.type,hash.name,blist,bname) or "" + if found ~= "" then + noffound = noffound + 1 + result[noffound] = resolvers.resolve(found) + if not allresults then break end + end else for kk=1,#blist do local vv = blist[kk] - result[#result+1] = methodhandler('concatinators',hash.type,hash.name,vv,bname) or "" - if not allresults then break end + local found = methodhandler('concatinators',hash.type,hash.name,vv,bname) or "" + if found ~= "" then + noffound = noffound + 1 + result[noffound] = resolvers.resolve(found) + if not allresults then break end + end end end end @@ -11993,7 +11996,7 @@ prefixes.environment = function(str) return cleanpath(expansion(str)) end -prefixes.relative = function(str,n) +prefixes.relative = function(str,n) -- lfs.isfile if io.exists(str) then -- nothing elseif io.exists("./" .. str) then diff --git a/scripts/context/stubs/mswin/mtxrun.lua b/scripts/context/stubs/mswin/mtxrun.lua index 4ada628ea..31d7d9b0f 100644 --- a/scripts/context/stubs/mswin/mtxrun.lua +++ b/scripts/context/stubs/mswin/mtxrun.lua @@ -4877,16 +4877,6 @@ local t_enable, t_disable = trackers .enable, trackers .disable local d_enable, d_disable = directives .enable, directives .disable local e_enable, e_disable = experiments.enable, experiments.disable --- experiment - -if trackers and environment and environment.engineflags.trackers then - t_enable(environment.engineflags.trackers) -end - -if directives and environment and environment.engineflags.directives then - d_enable(environment.engineflags.directives) -end - -- nice trick: we overload two of the directives related functions with variants that -- do tracing (itself using a tracker) .. proof of concept @@ -4930,11 +4920,15 @@ end) -- experiment -if trackers and environment and environment.engineflags.trackers then - t_enable(environment.engineflags.trackers) -end -if directives and environment and environment.engineflags.directives then - d_enable(environment.engineflags.directives) +local flags = environment and environment.engineflags + +if flags then + if trackers and flags.trackers then + t_enable(flags.trackers) + end + if directives and flags.directives then + d_enable(flags.directives) + end end -- here @@ -11695,6 +11689,7 @@ end local function findgivenfiles(filename,allresults) local bname, result = filebasename(filename), { } local hashes = instance.hashes + local noffound = 0 for k=1,#hashes do local hash = hashes[k] local files = instance.files[hash.name] or { } @@ -11709,13 +11704,21 @@ local function findgivenfiles(filename,allresults) end if blist then if type(blist) == 'string' then - result[#result+1] = methodhandler('concatinators',hash.type,hash.name,blist,bname) or "" - if not allresults then break end + local found = methodhandler('concatinators',hash.type,hash.name,blist,bname) or "" + if found ~= "" then + noffound = noffound + 1 + result[noffound] = resolvers.resolve(found) + if not allresults then break end + end else for kk=1,#blist do local vv = blist[kk] - result[#result+1] = methodhandler('concatinators',hash.type,hash.name,vv,bname) or "" - if not allresults then break end + local found = methodhandler('concatinators',hash.type,hash.name,vv,bname) or "" + if found ~= "" then + noffound = noffound + 1 + result[noffound] = resolvers.resolve(found) + if not allresults then break end + end end end end @@ -11993,7 +11996,7 @@ prefixes.environment = function(str) return cleanpath(expansion(str)) end -prefixes.relative = function(str,n) +prefixes.relative = function(str,n) -- lfs.isfile if io.exists(str) then -- nothing elseif io.exists("./" .. str) then diff --git a/scripts/context/stubs/unix/mtxrun b/scripts/context/stubs/unix/mtxrun index 4ada628ea..31d7d9b0f 100755 --- a/scripts/context/stubs/unix/mtxrun +++ b/scripts/context/stubs/unix/mtxrun @@ -4877,16 +4877,6 @@ local t_enable, t_disable = trackers .enable, trackers .disable local d_enable, d_disable = directives .enable, directives .disable local e_enable, e_disable = experiments.enable, experiments.disable --- experiment - -if trackers and environment and environment.engineflags.trackers then - t_enable(environment.engineflags.trackers) -end - -if directives and environment and environment.engineflags.directives then - d_enable(environment.engineflags.directives) -end - -- nice trick: we overload two of the directives related functions with variants that -- do tracing (itself using a tracker) .. proof of concept @@ -4930,11 +4920,15 @@ end) -- experiment -if trackers and environment and environment.engineflags.trackers then - t_enable(environment.engineflags.trackers) -end -if directives and environment and environment.engineflags.directives then - d_enable(environment.engineflags.directives) +local flags = environment and environment.engineflags + +if flags then + if trackers and flags.trackers then + t_enable(flags.trackers) + end + if directives and flags.directives then + d_enable(flags.directives) + end end -- here @@ -11695,6 +11689,7 @@ end local function findgivenfiles(filename,allresults) local bname, result = filebasename(filename), { } local hashes = instance.hashes + local noffound = 0 for k=1,#hashes do local hash = hashes[k] local files = instance.files[hash.name] or { } @@ -11709,13 +11704,21 @@ local function findgivenfiles(filename,allresults) end if blist then if type(blist) == 'string' then - result[#result+1] = methodhandler('concatinators',hash.type,hash.name,blist,bname) or "" - if not allresults then break end + local found = methodhandler('concatinators',hash.type,hash.name,blist,bname) or "" + if found ~= "" then + noffound = noffound + 1 + result[noffound] = resolvers.resolve(found) + if not allresults then break end + end else for kk=1,#blist do local vv = blist[kk] - result[#result+1] = methodhandler('concatinators',hash.type,hash.name,vv,bname) or "" - if not allresults then break end + local found = methodhandler('concatinators',hash.type,hash.name,vv,bname) or "" + if found ~= "" then + noffound = noffound + 1 + result[noffound] = resolvers.resolve(found) + if not allresults then break end + end end end end @@ -11993,7 +11996,7 @@ prefixes.environment = function(str) return cleanpath(expansion(str)) end -prefixes.relative = function(str,n) +prefixes.relative = function(str,n) -- lfs.isfile if io.exists(str) then -- nothing elseif io.exists("./" .. str) then diff --git a/tex/context/base/cont-new.mkii b/tex/context/base/cont-new.mkii index a171025fa..6b39c2bdf 100644 --- a/tex/context/base/cont-new.mkii +++ b/tex/context/base/cont-new.mkii @@ -11,7 +11,7 @@ %C therefore copyrighted by \PRAGMA. See mreadme.pdf for %C details. -\newcontextversion{2011.02.04 10:01} +\newcontextversion{2011.02.04 19:31} %D This file is loaded at runtime, thereby providing an %D excellent place for hacks, patches, extensions and new diff --git a/tex/context/base/cont-new.mkiv b/tex/context/base/cont-new.mkiv index f077a9bb2..7e0ca5f16 100644 --- a/tex/context/base/cont-new.mkiv +++ b/tex/context/base/cont-new.mkiv @@ -11,7 +11,7 @@ %C therefore copyrighted by \PRAGMA. See mreadme.pdf for %C details. -\newcontextversion{2011.02.04 10:01} +\newcontextversion{2011.02.04 19:31} %D This file is loaded at runtime, thereby providing an %D excellent place for hacks, patches, extensions and new diff --git a/tex/context/base/context.mkii b/tex/context/base/context.mkii index 71000f4ad..5d1f35894 100644 --- a/tex/context/base/context.mkii +++ b/tex/context/base/context.mkii @@ -20,7 +20,7 @@ %D your styles an modules. \edef\contextformat {\jobname} -\edef\contextversion{2011.02.04 10:01} +\edef\contextversion{2011.02.04 19:31} %D For those who want to use this: diff --git a/tex/context/base/context.mkiv b/tex/context/base/context.mkiv index cfe2cedaa..152c50575 100644 --- a/tex/context/base/context.mkiv +++ b/tex/context/base/context.mkiv @@ -20,7 +20,7 @@ %D your styles an modules. \edef\contextformat {\jobname} -\edef\contextversion{2011.02.04 10:01} +\edef\contextversion{2011.02.04 19:31} %D For those who want to use this: diff --git a/tex/context/base/data-pre.lua b/tex/context/base/data-pre.lua index 2e566de87..f774ba6eb 100644 --- a/tex/context/base/data-pre.lua +++ b/tex/context/base/data-pre.lua @@ -28,7 +28,7 @@ prefixes.environment = function(str) return cleanpath(expansion(str)) end -prefixes.relative = function(str,n) +prefixes.relative = function(str,n) -- lfs.isfile if io.exists(str) then -- nothing elseif io.exists("./" .. str) then diff --git a/tex/context/base/data-res.lua b/tex/context/base/data-res.lua index a53816c3f..e9dbc5e67 100644 --- a/tex/context/base/data-res.lua +++ b/tex/context/base/data-res.lua @@ -1408,6 +1408,7 @@ end local function findgivenfiles(filename,allresults) local bname, result = filebasename(filename), { } local hashes = instance.hashes + local noffound = 0 for k=1,#hashes do local hash = hashes[k] local files = instance.files[hash.name] or { } @@ -1422,13 +1423,21 @@ local function findgivenfiles(filename,allresults) end if blist then if type(blist) == 'string' then - result[#result+1] = methodhandler('concatinators',hash.type,hash.name,blist,bname) or "" - if not allresults then break end + local found = methodhandler('concatinators',hash.type,hash.name,blist,bname) or "" + if found ~= "" then + noffound = noffound + 1 + result[noffound] = resolvers.resolve(found) + if not allresults then break end + end else for kk=1,#blist do local vv = blist[kk] - result[#result+1] = methodhandler('concatinators',hash.type,hash.name,vv,bname) or "" - if not allresults then break end + local found = methodhandler('concatinators',hash.type,hash.name,vv,bname) or "" + if found ~= "" then + noffound = noffound + 1 + result[noffound] = resolvers.resolve(found) + if not allresults then break end + end end end end diff --git a/tex/context/base/luat-run.lua b/tex/context/base/luat-run.lua index 77147c862..5bccfee7e 100644 --- a/tex/context/base/luat-run.lua +++ b/tex/context/base/luat-run.lua @@ -127,7 +127,14 @@ directives.register("system.synctex", function(v) else report_system("synctex functionality is disabled!") end + -- current this is bugged: tex.synctex = synctex and 1 or 0 + -- so for the moment we need: + if synctex then + tex.print("\\normalsynctex\\plusone") + else + tex.print("\\normalsynctex\\zerocount") + end end) statistics.register("synctex tracing",function() diff --git a/tex/context/base/status-files.pdf b/tex/context/base/status-files.pdf Binary files differindex c5fbf7ba6..6dc071a3a 100644 --- a/tex/context/base/status-files.pdf +++ b/tex/context/base/status-files.pdf diff --git a/tex/context/base/trac-set.lua b/tex/context/base/trac-set.lua index 49dfcf74d..df0c4fe5c 100644 --- a/tex/context/base/trac-set.lua +++ b/tex/context/base/trac-set.lua @@ -239,16 +239,6 @@ local t_enable, t_disable = trackers .enable, trackers .disable local d_enable, d_disable = directives .enable, directives .disable local e_enable, e_disable = experiments.enable, experiments.disable --- experiment - -if trackers and environment and environment.engineflags.trackers then - t_enable(environment.engineflags.trackers) -end - -if directives and environment and environment.engineflags.directives then - d_enable(environment.engineflags.directives) -end - -- nice trick: we overload two of the directives related functions with variants that -- do tracing (itself using a tracker) .. proof of concept @@ -292,11 +282,15 @@ end) -- experiment -if trackers and environment and environment.engineflags.trackers then - t_enable(environment.engineflags.trackers) -end -if directives and environment and environment.engineflags.directives then - d_enable(environment.engineflags.directives) +local flags = environment and environment.engineflags + +if flags then + if trackers and flags.trackers then + t_enable(flags.trackers) + end + if directives and flags.directives then + d_enable(flags.directives) + end end -- here diff --git a/tex/generic/context/luatex-fonts-merged.lua b/tex/generic/context/luatex-fonts-merged.lua index eb4c35d4a..3310c642c 100644 --- a/tex/generic/context/luatex-fonts-merged.lua +++ b/tex/generic/context/luatex-fonts-merged.lua @@ -1,6 +1,6 @@ -- merged file : luatex-fonts-merged.lua -- parent file : luatex-fonts.lua --- merge date : 02/04/11 10:01:54 +-- merge date : 02/04/11 19:31:45 do -- begin closure to overcome local limits and interference |