diff options
-rw-r--r-- | doc/context/scripts/mkiv/mtx-bibtex.html | 55 | ||||
-rw-r--r-- | doc/context/scripts/mkiv/mtx-bibtex.man | 33 | ||||
-rw-r--r-- | doc/context/scripts/mkiv/mtx-bibtex.xml | 28 | ||||
-rw-r--r-- | scripts/context/lua/mtxrun.lua | 46 | ||||
-rw-r--r-- | scripts/context/stubs/mswin/mtxrun.lua | 46 | ||||
-rw-r--r-- | scripts/context/stubs/unix/mtxrun | 46 | ||||
-rw-r--r-- | scripts/context/stubs/win64/mtxrun.lua | 46 | ||||
-rw-r--r-- | tex/context/base/cont-log.mkiv | 2 | ||||
-rw-r--r-- | tex/context/base/cont-new.mkiv | 2 | ||||
-rw-r--r-- | tex/context/base/context-version.pdf | bin | 4386 -> 4385 bytes | |||
-rw-r--r-- | tex/context/base/context.mkiv | 2 | ||||
-rw-r--r-- | tex/context/base/data-res.lua | 7 | ||||
-rw-r--r-- | tex/context/base/l-file.lua | 4 | ||||
-rw-r--r-- | tex/context/base/publ-dat.lua | 10 | ||||
-rw-r--r-- | tex/context/base/status-files.pdf | bin | 24874 -> 24873 bytes | |||
-rw-r--r-- | tex/context/base/status-lua.pdf | bin | 345890 -> 345975 bytes | |||
-rw-r--r-- | tex/context/base/trac-lmx.lua | 5 | ||||
-rw-r--r-- | tex/context/base/util-prs.lua | 44 | ||||
-rw-r--r-- | tex/generic/context/luatex/luatex-fonts-merged.lua | 2 |
19 files changed, 187 insertions, 191 deletions
diff --git a/doc/context/scripts/mkiv/mtx-bibtex.html b/doc/context/scripts/mkiv/mtx-bibtex.html deleted file mode 100644 index 61a679716..000000000 --- a/doc/context/scripts/mkiv/mtx-bibtex.html +++ /dev/null @@ -1,55 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> - -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> - -<!-- compare with lmx framework variant --> - -<!-- - filename : context-base.xml - comment : companion to mtx-server-ctx-startup.tex - author : Hans Hagen, PRAGMA-ADE, Hasselt NL - copyright: PRAGMA ADE / ConTeXt Development Team - license : see context related readme files ---> - -<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> - <head> - <title>bibtex helpers</title> - <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> - <style type="text/css"> - body { color: #FFFFFF; background-color: #808080; font-family: optima, verdana, futura, "lucida sans", arial, geneva, helvetica, sans; font-size: 12px; line-height: 18px; } a:link, a:active, a:visited { color: #FFFFFF; } a.dir-view:link, a.dir-view:active, a.dir-view:visited { color: #FFFFFF; text-decoration: underline; } .valid { color: #00FF00; } .invalid { color: #FF0000; } button, .commonlink, .smallbutton { font-weight: bold; font-size: 12px; text-decoration: none; color: #000000; border-color: #7F7F7F; border-style: solid; border-width: .125ex; background-color: #FFFFFF; padding: .5ex; } .smallbutton { width: 1em; } a.commonlink:link, a.commonlink:active, a.commonlink:visited, a.smalllink:link, a.smalllink:active, a.smalllink:visited { font-weight: bold; font-size: 12px; text-decoration: none; color: #000000; } h1, .title { font-style: normal; font-weight: normal; font-size: 18px; line-height: 18px; margin-bottom: 20px; } h2, .subtitle { font-style: normal; font-weight: normal; font-size: 12px; margin-top: 18px; margin-bottom: 18px; } table { line-height: 18px; font-size: 12px; margin: 0; } th { font-weight: bold; text-align: left; padding-bottom: 6px; } .tc { font-weight: bold; text-align: left; } p, li { max-width: 60em; } .empty-line { margin-top: 4px; } .more-room { margin-right: 1.5em; } .much-more-room { margin-right: 3em; } #main { position: absolute; left: 10%; top: 10%; right: 10%; bottom: 10%; z-index: 2; width: 80%; height: 80%; padding: 0%; margin: 0%; overflow: auto; border-style: none; border-width: 0; background-color: #3F3F3F; } #main-settings { margin: 12px; x_max-width: 60em; line-height: 18px; font-size: 12px; } #left { position: absolute; top : 10%; left: 0%; bottom: 0%; right: 90%; z-index: 1; width: 10%; height: 90%; padding: 0%; margin: 0%; font-size: 16px; border-style: none; border-width: 0; background-color: #4F6F6F; } #right { position: absolute; top : 0%; left: 90%; bottom: 10%; right: 0%; z-index: 1; width: 10%; height: 90%; padding: 0%; margin: 0%; font-size: 16px; border-style: none; border-width: 0; background-color: #4F6F6F; _margin-left: -15px; } #bottom { position: absolute; left: 10%; right: 0%; top: 90%; bottom: 0%; z-index: 1; width: 90%; height: 10%; padding: 0%; margin: 0%; font-size: 16px; border-style: none; border-width: 0; background-color: #6F6F8F; } #top { position: absolute; left: 0%; right: 10%; top: 0%; bottom: 90%; z-index: 1; width: 90%; height: 10%; padding: 0%; margin: 0%; font-size: 16px; border-style: none; border-width: 0; background-color: #6F6F8F; } #top-one { position: absolute; bottom: 50%; width: 100%; buggedheight: 100%; } #top-two { position: relative; margin-bottom: -9px; margin-left: 12px; margin-right: 12px; line-height: 18px; text-align: right; vertical-align: middle; } #bottom-one { position: absolute; bottom: 50%; width: 100%; buggedheight: 100%; } #bottom-two { position: relative; margin-bottom: -9px; margin-left: 12px; margin-right: 12px; line-height: 18px; text-align: left; vertical-align: middle; } #left-one { position: absolute; width: 100%; buggedheight: 100%; } #left-two { position: relative; margin-top: 12px; line-height: 18px; text-align: center; vertical-align: top; } #right-one { display: table; height: 100%; width: 100%; } #right-two { display: table-row; height: 100%; width: 100%; } #right-three { display: table-cell; width: 100%; vertical-align: bottom; _position: absolute; _top: 100%; } #right-four { text-align: center; margin-bottom: 2ex; _position: relative; _top: -100%; } #more-top { position: absolute; top: 0%; left: 90%; bottom: 90%; right: 0%; z-index: 3; width: 10%; height: 10%; padding: 0%; margin: 0%; border-style: none; border-width: 0; } #more-top-settings { text-align: center; } #more-right-settings { margin-right: 12px; margin-left: 12px; line-height: 18px; font-size: 10px; text-align: center; } #right-safari { _display: table; width: 100%; height: 100%; } - </style> - <style type="text/css"> - </style> - </head> - <body> - <div id="top"> <div id="top-one"> - <div id="top-two">bibtex helpers </div> - </div> - </div> - <div id="bottom"> <div id="bottom-one"> - <div id="bottom-two">wiki: http://contextgarden.net | mail: ntg-context@ntg.nl | website: http://www.pragma-ade.nl</div> - </div> - </div> - <div id="left"></div> - <div id="right"></div> - <div id="main"> - <div id='main-settings'> - <h1>Command line options</h1> -<table> - <tr><th style="width: 10em">flag</th><th style="width: 8em">value</th><th>description</th></tr> - <tr><th/><td/><td/></tr> - <tr><th>--toxml</th><td></td><td>convert bibtex database(s) to xml</td></tr> - <tr><th>--tolua</th><td></td><td>convert bibtex database(s) to lua</td></tr> - <tr><th>--search</th><td></td><td>seatch bibtex database(s)</td></tr> - </table> -<br/> -<h1>Example</h1> -<tt>mtxrun --script bibtex --tolua bibl-001.bib</tt> -<br/><tt>mtxrun --script bibtex --tolua --simple bibl-001.bib</tt> -<br/><tt>mtxrun --script bibtex --toxml bibl-001.bib bibl-002.bib bibl-003.bib biblio.xml</tt> -<br/><tt>mtxrun --script bibtex --search --list --pattern=match(author:foo) bar.bib</tt> -<br/><br/> </div> - </div> - </body> - </html> diff --git a/doc/context/scripts/mkiv/mtx-bibtex.man b/doc/context/scripts/mkiv/mtx-bibtex.man deleted file mode 100644 index ef44fc87d..000000000 --- a/doc/context/scripts/mkiv/mtx-bibtex.man +++ /dev/null @@ -1,33 +0,0 @@ -.TH "mtx-bibtex" "1" "01-01-2014" "version 1.00" "bibtex helpers" -.SH NAME -.B mtx-bibtex -.SH SYNOPSIS -.B mtxrun --script bibtex [ -.I OPTIONS ... -.B ] [ -.I FILENAMES -.B ] -.SH DESCRIPTION -.B bibtex helpers -.SH OPTIONS -.TP -.B --toxml -convert bibtex database(s) to xml -.TP -.B --tolua -convert bibtex database(s) to lua -.TP -.B --search -seatch bibtex database(s) -.SH AUTHOR -More information about ConTeXt and the tools that come with it can be found at: - - -.B "maillist:" -ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context - -.B "webpage:" -http://www.pragma-ade.nl / http://tex.aanhet.net - -.B "wiki:" -http://contextgarden.net diff --git a/doc/context/scripts/mkiv/mtx-bibtex.xml b/doc/context/scripts/mkiv/mtx-bibtex.xml deleted file mode 100644 index 5c28b946a..000000000 --- a/doc/context/scripts/mkiv/mtx-bibtex.xml +++ /dev/null @@ -1,28 +0,0 @@ -<?xml version="1.0"?> -<application> - <metadata> - <entry name="name">mtx-bibtex</entry> - <entry name="detail">bibtex helpers</entry> - <entry name="version">1.00</entry> - </metadata> - <flags> - <category name="basic"> - <subcategory> - <flag name="toxml"><short>convert bibtex database(s) to xml</short></flag> - <flag name="tolua"><short>convert bibtex database(s) to lua</short></flag> - <flag name="search"><short>seatch bibtex database(s)</short></flag> - </subcategory> - </category> - </flags> - <examples> - <category> - <title>Example</title> - <subcategory> - <example><command>mtxrun --script bibtex --tolua bibl-001.bib</command></example> - <example><command>mtxrun --script bibtex --tolua --simple bibl-001.bib</command></example> - <example><command>mtxrun --script bibtex --toxml bibl-001.bib bibl-002.bib bibl-003.bib biblio.xml</command></example> - <example><command>mtxrun --script bibtex --search --list --pattern=match(author:foo) bar.bib</command></example> - </subcategory> - </category> - </examples> -</application> diff --git a/scripts/context/lua/mtxrun.lua b/scripts/context/lua/mtxrun.lua index 946b18dd4..66a8e0b29 100644 --- a/scripts/context/lua/mtxrun.lua +++ b/scripts/context/lua/mtxrun.lua @@ -3179,7 +3179,7 @@ do -- create closure to overcome 200 locals limit package.loaded["l-file"] = package.loaded["l-file"] or true --- original size: 20945, stripped down to: 9945 +-- original size: 20949, stripped down to: 9945 if not modules then modules={} end modules ['l-file']={ version=1.001, @@ -6558,7 +6558,7 @@ do -- create closure to overcome 200 locals limit package.loaded["util-prs"] = package.loaded["util-prs"] or true --- original size: 20589, stripped down to: 14439 +-- original size: 21550, stripped down to: 14916 if not modules then modules={} end modules ['util-prs']={ version=1.001, @@ -6714,11 +6714,30 @@ function parsers.settings_to_array(str,strict) return { str } end end -local separator=space^0*comma*space^0 -local value=P(lbrace*C((nobrace+nestedbraces)^0)*rbrace)+C((nestedbraces+(1-(space^0*(comma+P(-1)))))^0) -local withvalue=Carg(1)*value/function(f,s) return f(s) end -local pattern_a=spaces*Ct(value*(separator*value)^0) -local pattern_b=spaces*withvalue*(separator*withvalue)^0 +local cache_a={} +local cache_b={} +function parsers.groupedsplitat(symbol,withaction) + if not symbol then + symbol="," + end + local pattern=(withaction and cache_b or cache_a)[symbol] + if not pattern then + local symbols=S(symbol) + local separator=space^0*symbols*space^0 + local value=P(lbrace*C((nobrace+nestedbraces)^0)*rbrace)+C((nestedbraces+(1-(space^0*(symbols+P(-1)))))^0) + if withaction then + local withvalue=Carg(1)*value/function(f,s) return f(s) end + pattern=spaces*withvalue*(separator*withvalue)^0 + cache_b[symbol]=pattern + else + pattern=spaces*Ct(value*(separator*value)^0) + cache_a[symbol]=pattern + end + end + return pattern +end +local pattern_a=parsers.groupedsplitat(",",false) +local pattern_b=parsers.groupedsplitat(",",true) function parsers.stripped_settings_to_array(str) if not str or str=="" then return {} @@ -14389,7 +14408,7 @@ do -- create closure to overcome 200 locals limit package.loaded["data-res"] = package.loaded["data-res"] or true --- original size: 75084, stripped down to: 45905 +-- original size: 75211, stripped down to: 45919 if not modules then modules={} end modules ['data-res']={ version=1.001, @@ -14528,6 +14547,7 @@ function resolvers.newinstance() savelists=true, pattern=nil, force_suffixes=true, + pathstack={}, } setmetatableindex(variables,function(t,k) local v @@ -15348,14 +15368,14 @@ local function makepathlist(list,filetype) if pathlist and #pathlist>0 then for k=1,#pathlist do local path=pathlist[k] + local prescanned=find(path,'^!!') + local resursive=find(path,'//$') local pathname=lpegmatch(inhibitstripper,path) local expression=makepathexpression(pathname) local barename=gsub(pathname,"/+$","") barename=resolveprefix(barename) local scheme=url.hasscheme(barename) - local schemename=gsub(barename,"%.%*$",'') - local prescanned=path~=pathname - local resursive=find(pathname,'//$') + local schemename=gsub(barename,"%.%*$",'') entry[k]={ path=path, pathname=pathname, @@ -17739,8 +17759,8 @@ end -- of closure -- used libraries : l-lua.lua l-package.lua l-lpeg.lua l-function.lua l-string.lua l-table.lua l-io.lua l-number.lua l-set.lua l-os.lua l-file.lua l-gzip.lua l-md5.lua l-url.lua l-dir.lua l-boolean.lua l-unicode.lua l-math.lua util-str.lua util-tab.lua util-sto.lua util-prs.lua util-fmt.lua trac-set.lua trac-log.lua trac-inf.lua trac-pro.lua util-lua.lua util-deb.lua util-mrg.lua util-tpl.lua util-env.lua luat-env.lua lxml-tab.lua lxml-lpt.lua lxml-mis.lua lxml-aux.lua lxml-xml.lua trac-xml.lua data-ini.lua data-exp.lua data-env.lua data-tmp.lua data-met.lua data-res.lua data-pre.lua data-inp.lua data-out.lua data-fil.lua data-con.lua data-use.lua data-zip.lua data-tre.lua data-sch.lua data-lua.lua data-aux.lua data-tmf.lua data-lst.lua util-lib.lua luat-sta.lua luat-fmt.lua -- skipped libraries : - --- original bytes : 743536 --- stripped bytes : 271527 +-- original bytes : 744628 +-- stripped bytes : 272128 -- end library merge diff --git a/scripts/context/stubs/mswin/mtxrun.lua b/scripts/context/stubs/mswin/mtxrun.lua index 946b18dd4..66a8e0b29 100644 --- a/scripts/context/stubs/mswin/mtxrun.lua +++ b/scripts/context/stubs/mswin/mtxrun.lua @@ -3179,7 +3179,7 @@ do -- create closure to overcome 200 locals limit package.loaded["l-file"] = package.loaded["l-file"] or true --- original size: 20945, stripped down to: 9945 +-- original size: 20949, stripped down to: 9945 if not modules then modules={} end modules ['l-file']={ version=1.001, @@ -6558,7 +6558,7 @@ do -- create closure to overcome 200 locals limit package.loaded["util-prs"] = package.loaded["util-prs"] or true --- original size: 20589, stripped down to: 14439 +-- original size: 21550, stripped down to: 14916 if not modules then modules={} end modules ['util-prs']={ version=1.001, @@ -6714,11 +6714,30 @@ function parsers.settings_to_array(str,strict) return { str } end end -local separator=space^0*comma*space^0 -local value=P(lbrace*C((nobrace+nestedbraces)^0)*rbrace)+C((nestedbraces+(1-(space^0*(comma+P(-1)))))^0) -local withvalue=Carg(1)*value/function(f,s) return f(s) end -local pattern_a=spaces*Ct(value*(separator*value)^0) -local pattern_b=spaces*withvalue*(separator*withvalue)^0 +local cache_a={} +local cache_b={} +function parsers.groupedsplitat(symbol,withaction) + if not symbol then + symbol="," + end + local pattern=(withaction and cache_b or cache_a)[symbol] + if not pattern then + local symbols=S(symbol) + local separator=space^0*symbols*space^0 + local value=P(lbrace*C((nobrace+nestedbraces)^0)*rbrace)+C((nestedbraces+(1-(space^0*(symbols+P(-1)))))^0) + if withaction then + local withvalue=Carg(1)*value/function(f,s) return f(s) end + pattern=spaces*withvalue*(separator*withvalue)^0 + cache_b[symbol]=pattern + else + pattern=spaces*Ct(value*(separator*value)^0) + cache_a[symbol]=pattern + end + end + return pattern +end +local pattern_a=parsers.groupedsplitat(",",false) +local pattern_b=parsers.groupedsplitat(",",true) function parsers.stripped_settings_to_array(str) if not str or str=="" then return {} @@ -14389,7 +14408,7 @@ do -- create closure to overcome 200 locals limit package.loaded["data-res"] = package.loaded["data-res"] or true --- original size: 75084, stripped down to: 45905 +-- original size: 75211, stripped down to: 45919 if not modules then modules={} end modules ['data-res']={ version=1.001, @@ -14528,6 +14547,7 @@ function resolvers.newinstance() savelists=true, pattern=nil, force_suffixes=true, + pathstack={}, } setmetatableindex(variables,function(t,k) local v @@ -15348,14 +15368,14 @@ local function makepathlist(list,filetype) if pathlist and #pathlist>0 then for k=1,#pathlist do local path=pathlist[k] + local prescanned=find(path,'^!!') + local resursive=find(path,'//$') local pathname=lpegmatch(inhibitstripper,path) local expression=makepathexpression(pathname) local barename=gsub(pathname,"/+$","") barename=resolveprefix(barename) local scheme=url.hasscheme(barename) - local schemename=gsub(barename,"%.%*$",'') - local prescanned=path~=pathname - local resursive=find(pathname,'//$') + local schemename=gsub(barename,"%.%*$",'') entry[k]={ path=path, pathname=pathname, @@ -17739,8 +17759,8 @@ end -- of closure -- used libraries : l-lua.lua l-package.lua l-lpeg.lua l-function.lua l-string.lua l-table.lua l-io.lua l-number.lua l-set.lua l-os.lua l-file.lua l-gzip.lua l-md5.lua l-url.lua l-dir.lua l-boolean.lua l-unicode.lua l-math.lua util-str.lua util-tab.lua util-sto.lua util-prs.lua util-fmt.lua trac-set.lua trac-log.lua trac-inf.lua trac-pro.lua util-lua.lua util-deb.lua util-mrg.lua util-tpl.lua util-env.lua luat-env.lua lxml-tab.lua lxml-lpt.lua lxml-mis.lua lxml-aux.lua lxml-xml.lua trac-xml.lua data-ini.lua data-exp.lua data-env.lua data-tmp.lua data-met.lua data-res.lua data-pre.lua data-inp.lua data-out.lua data-fil.lua data-con.lua data-use.lua data-zip.lua data-tre.lua data-sch.lua data-lua.lua data-aux.lua data-tmf.lua data-lst.lua util-lib.lua luat-sta.lua luat-fmt.lua -- skipped libraries : - --- original bytes : 743536 --- stripped bytes : 271527 +-- original bytes : 744628 +-- stripped bytes : 272128 -- end library merge diff --git a/scripts/context/stubs/unix/mtxrun b/scripts/context/stubs/unix/mtxrun index 946b18dd4..66a8e0b29 100644 --- a/scripts/context/stubs/unix/mtxrun +++ b/scripts/context/stubs/unix/mtxrun @@ -3179,7 +3179,7 @@ do -- create closure to overcome 200 locals limit package.loaded["l-file"] = package.loaded["l-file"] or true --- original size: 20945, stripped down to: 9945 +-- original size: 20949, stripped down to: 9945 if not modules then modules={} end modules ['l-file']={ version=1.001, @@ -6558,7 +6558,7 @@ do -- create closure to overcome 200 locals limit package.loaded["util-prs"] = package.loaded["util-prs"] or true --- original size: 20589, stripped down to: 14439 +-- original size: 21550, stripped down to: 14916 if not modules then modules={} end modules ['util-prs']={ version=1.001, @@ -6714,11 +6714,30 @@ function parsers.settings_to_array(str,strict) return { str } end end -local separator=space^0*comma*space^0 -local value=P(lbrace*C((nobrace+nestedbraces)^0)*rbrace)+C((nestedbraces+(1-(space^0*(comma+P(-1)))))^0) -local withvalue=Carg(1)*value/function(f,s) return f(s) end -local pattern_a=spaces*Ct(value*(separator*value)^0) -local pattern_b=spaces*withvalue*(separator*withvalue)^0 +local cache_a={} +local cache_b={} +function parsers.groupedsplitat(symbol,withaction) + if not symbol then + symbol="," + end + local pattern=(withaction and cache_b or cache_a)[symbol] + if not pattern then + local symbols=S(symbol) + local separator=space^0*symbols*space^0 + local value=P(lbrace*C((nobrace+nestedbraces)^0)*rbrace)+C((nestedbraces+(1-(space^0*(symbols+P(-1)))))^0) + if withaction then + local withvalue=Carg(1)*value/function(f,s) return f(s) end + pattern=spaces*withvalue*(separator*withvalue)^0 + cache_b[symbol]=pattern + else + pattern=spaces*Ct(value*(separator*value)^0) + cache_a[symbol]=pattern + end + end + return pattern +end +local pattern_a=parsers.groupedsplitat(",",false) +local pattern_b=parsers.groupedsplitat(",",true) function parsers.stripped_settings_to_array(str) if not str or str=="" then return {} @@ -14389,7 +14408,7 @@ do -- create closure to overcome 200 locals limit package.loaded["data-res"] = package.loaded["data-res"] or true --- original size: 75084, stripped down to: 45905 +-- original size: 75211, stripped down to: 45919 if not modules then modules={} end modules ['data-res']={ version=1.001, @@ -14528,6 +14547,7 @@ function resolvers.newinstance() savelists=true, pattern=nil, force_suffixes=true, + pathstack={}, } setmetatableindex(variables,function(t,k) local v @@ -15348,14 +15368,14 @@ local function makepathlist(list,filetype) if pathlist and #pathlist>0 then for k=1,#pathlist do local path=pathlist[k] + local prescanned=find(path,'^!!') + local resursive=find(path,'//$') local pathname=lpegmatch(inhibitstripper,path) local expression=makepathexpression(pathname) local barename=gsub(pathname,"/+$","") barename=resolveprefix(barename) local scheme=url.hasscheme(barename) - local schemename=gsub(barename,"%.%*$",'') - local prescanned=path~=pathname - local resursive=find(pathname,'//$') + local schemename=gsub(barename,"%.%*$",'') entry[k]={ path=path, pathname=pathname, @@ -17739,8 +17759,8 @@ end -- of closure -- used libraries : l-lua.lua l-package.lua l-lpeg.lua l-function.lua l-string.lua l-table.lua l-io.lua l-number.lua l-set.lua l-os.lua l-file.lua l-gzip.lua l-md5.lua l-url.lua l-dir.lua l-boolean.lua l-unicode.lua l-math.lua util-str.lua util-tab.lua util-sto.lua util-prs.lua util-fmt.lua trac-set.lua trac-log.lua trac-inf.lua trac-pro.lua util-lua.lua util-deb.lua util-mrg.lua util-tpl.lua util-env.lua luat-env.lua lxml-tab.lua lxml-lpt.lua lxml-mis.lua lxml-aux.lua lxml-xml.lua trac-xml.lua data-ini.lua data-exp.lua data-env.lua data-tmp.lua data-met.lua data-res.lua data-pre.lua data-inp.lua data-out.lua data-fil.lua data-con.lua data-use.lua data-zip.lua data-tre.lua data-sch.lua data-lua.lua data-aux.lua data-tmf.lua data-lst.lua util-lib.lua luat-sta.lua luat-fmt.lua -- skipped libraries : - --- original bytes : 743536 --- stripped bytes : 271527 +-- original bytes : 744628 +-- stripped bytes : 272128 -- end library merge diff --git a/scripts/context/stubs/win64/mtxrun.lua b/scripts/context/stubs/win64/mtxrun.lua index 946b18dd4..66a8e0b29 100644 --- a/scripts/context/stubs/win64/mtxrun.lua +++ b/scripts/context/stubs/win64/mtxrun.lua @@ -3179,7 +3179,7 @@ do -- create closure to overcome 200 locals limit package.loaded["l-file"] = package.loaded["l-file"] or true --- original size: 20945, stripped down to: 9945 +-- original size: 20949, stripped down to: 9945 if not modules then modules={} end modules ['l-file']={ version=1.001, @@ -6558,7 +6558,7 @@ do -- create closure to overcome 200 locals limit package.loaded["util-prs"] = package.loaded["util-prs"] or true --- original size: 20589, stripped down to: 14439 +-- original size: 21550, stripped down to: 14916 if not modules then modules={} end modules ['util-prs']={ version=1.001, @@ -6714,11 +6714,30 @@ function parsers.settings_to_array(str,strict) return { str } end end -local separator=space^0*comma*space^0 -local value=P(lbrace*C((nobrace+nestedbraces)^0)*rbrace)+C((nestedbraces+(1-(space^0*(comma+P(-1)))))^0) -local withvalue=Carg(1)*value/function(f,s) return f(s) end -local pattern_a=spaces*Ct(value*(separator*value)^0) -local pattern_b=spaces*withvalue*(separator*withvalue)^0 +local cache_a={} +local cache_b={} +function parsers.groupedsplitat(symbol,withaction) + if not symbol then + symbol="," + end + local pattern=(withaction and cache_b or cache_a)[symbol] + if not pattern then + local symbols=S(symbol) + local separator=space^0*symbols*space^0 + local value=P(lbrace*C((nobrace+nestedbraces)^0)*rbrace)+C((nestedbraces+(1-(space^0*(symbols+P(-1)))))^0) + if withaction then + local withvalue=Carg(1)*value/function(f,s) return f(s) end + pattern=spaces*withvalue*(separator*withvalue)^0 + cache_b[symbol]=pattern + else + pattern=spaces*Ct(value*(separator*value)^0) + cache_a[symbol]=pattern + end + end + return pattern +end +local pattern_a=parsers.groupedsplitat(",",false) +local pattern_b=parsers.groupedsplitat(",",true) function parsers.stripped_settings_to_array(str) if not str or str=="" then return {} @@ -14389,7 +14408,7 @@ do -- create closure to overcome 200 locals limit package.loaded["data-res"] = package.loaded["data-res"] or true --- original size: 75084, stripped down to: 45905 +-- original size: 75211, stripped down to: 45919 if not modules then modules={} end modules ['data-res']={ version=1.001, @@ -14528,6 +14547,7 @@ function resolvers.newinstance() savelists=true, pattern=nil, force_suffixes=true, + pathstack={}, } setmetatableindex(variables,function(t,k) local v @@ -15348,14 +15368,14 @@ local function makepathlist(list,filetype) if pathlist and #pathlist>0 then for k=1,#pathlist do local path=pathlist[k] + local prescanned=find(path,'^!!') + local resursive=find(path,'//$') local pathname=lpegmatch(inhibitstripper,path) local expression=makepathexpression(pathname) local barename=gsub(pathname,"/+$","") barename=resolveprefix(barename) local scheme=url.hasscheme(barename) - local schemename=gsub(barename,"%.%*$",'') - local prescanned=path~=pathname - local resursive=find(pathname,'//$') + local schemename=gsub(barename,"%.%*$",'') entry[k]={ path=path, pathname=pathname, @@ -17739,8 +17759,8 @@ end -- of closure -- used libraries : l-lua.lua l-package.lua l-lpeg.lua l-function.lua l-string.lua l-table.lua l-io.lua l-number.lua l-set.lua l-os.lua l-file.lua l-gzip.lua l-md5.lua l-url.lua l-dir.lua l-boolean.lua l-unicode.lua l-math.lua util-str.lua util-tab.lua util-sto.lua util-prs.lua util-fmt.lua trac-set.lua trac-log.lua trac-inf.lua trac-pro.lua util-lua.lua util-deb.lua util-mrg.lua util-tpl.lua util-env.lua luat-env.lua lxml-tab.lua lxml-lpt.lua lxml-mis.lua lxml-aux.lua lxml-xml.lua trac-xml.lua data-ini.lua data-exp.lua data-env.lua data-tmp.lua data-met.lua data-res.lua data-pre.lua data-inp.lua data-out.lua data-fil.lua data-con.lua data-use.lua data-zip.lua data-tre.lua data-sch.lua data-lua.lua data-aux.lua data-tmf.lua data-lst.lua util-lib.lua luat-sta.lua luat-fmt.lua -- skipped libraries : - --- original bytes : 743536 --- stripped bytes : 271527 +-- original bytes : 744628 +-- stripped bytes : 272128 -- end library merge diff --git a/tex/context/base/cont-log.mkiv b/tex/context/base/cont-log.mkiv index ee0dbb09d..cb3b6a58e 100644 --- a/tex/context/base/cont-log.mkiv +++ b/tex/context/base/cont-log.mkiv @@ -93,7 +93,7 @@ \unexpanded\def\Context % wrong usage of \getscaledglyph {\dontleavehmode \begingroup - C\kern -.0667\emwidth{.8}\empty{O\kern -.0667\emwidth N\kern + C\kern -.0667\emwidth\getscaledglyph{.8}\empty{O\kern -.0667\emwidth N\kern -.0549\emwidth T\doifitalicelse{\kern-.1\emwidth}{\kern-.1667\emwidth}\lower.5\exheight\hbox {E}\doifitalicelse\empty{\kern-.11em}X\kern-.055\emwidth T}% \endgroup} diff --git a/tex/context/base/cont-new.mkiv b/tex/context/base/cont-new.mkiv index 7d03cf1a5..ed1b174c8 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{2014.12.30 09:48} +\newcontextversion{2014.12.31 16:52} %D This file is loaded at runtime, thereby providing an excellent place for %D hacks, patches, extensions and new features. diff --git a/tex/context/base/context-version.pdf b/tex/context/base/context-version.pdf Binary files differindex 7b10218d4..c9fef1602 100644 --- a/tex/context/base/context-version.pdf +++ b/tex/context/base/context-version.pdf diff --git a/tex/context/base/context.mkiv b/tex/context/base/context.mkiv index a533be7f9..f8c1bd0be 100644 --- a/tex/context/base/context.mkiv +++ b/tex/context/base/context.mkiv @@ -28,7 +28,7 @@ %D up and the dependencies are more consistent. \edef\contextformat {\jobname} -\edef\contextversion{2014.12.30 09:48} +\edef\contextversion{2014.12.31 16:52} \edef\contextkind {beta} %D For those who want to use this: diff --git a/tex/context/base/data-res.lua b/tex/context/base/data-res.lua index dbd212921..26cfe673a 100644 --- a/tex/context/base/data-res.lua +++ b/tex/context/base/data-res.lua @@ -253,6 +253,7 @@ function resolvers.newinstance() -- todo: all vars will become lowercase and alp savelists = true, pattern = nil, -- lists force_suffixes = true, + pathstack = { }, } setmetatableindex(variables,function(t,k) @@ -1365,14 +1366,16 @@ local function makepathlist(list,filetype) if pathlist and #pathlist > 0 then for k=1,#pathlist do local path = pathlist[k] + local prescanned = find(path,'^!!') + local resursive = find(path,'//$') local pathname = lpegmatch(inhibitstripper,path) local expression = makepathexpression(pathname) local barename = gsub(pathname,"/+$","") barename = resolveprefix(barename) local scheme = url.hasscheme(barename) local schemename = gsub(barename,"%.%*$",'') -- after scheme - local prescanned = path ~= pathname -- ^!! - local resursive = find(pathname,'//$') + -- local prescanned = path ~= pathname -- ^!! + -- local resursive = find(pathname,'//$') entry[k] = { path = path, pathname = pathname, diff --git a/tex/context/base/l-file.lua b/tex/context/base/l-file.lua index 2c471d727..7ed6370f2 100644 --- a/tex/context/base/l-file.lua +++ b/tex/context/base/l-file.lua @@ -157,8 +157,8 @@ file.suffix = suffixonly file.suffixesonly = suffixesonly file.suffixes = suffixesonly -file.dirname = pathpart -- obsolete -file.extname = suffixonly -- obsolete +file.dirname = pathpart -- obsolete +file.extname = suffixonly -- obsolete -- actually these are schemes diff --git a/tex/context/base/publ-dat.lua b/tex/context/base/publ-dat.lua index 88631a0d6..f022f6ade 100644 --- a/tex/context/base/publ-dat.lua +++ b/tex/context/base/publ-dat.lua @@ -1034,11 +1034,15 @@ do return values end) - casters.keyword = utilities.parsers.settings_to_array + local keywordsplitter = utilities.parsers.groupedsplitat(";,") - local pagessplitter = lpeg.splitat(P("-")^1) + casters.keyword = function(str) + return lpegmatch(keywordsplitter,str) + end + + local pagessplitter = lpeg.splitat(P("-")^1) - casters.pagenumber = function(str) + casters.pagenumber = function(str) local first, last = lpegmatch(pagessplitter,str) return first and last and { first, last } or str end diff --git a/tex/context/base/status-files.pdf b/tex/context/base/status-files.pdf Binary files differindex d5af6d8ff..85959a730 100644 --- a/tex/context/base/status-files.pdf +++ b/tex/context/base/status-files.pdf diff --git a/tex/context/base/status-lua.pdf b/tex/context/base/status-lua.pdf Binary files differindex 0b601c9ba..a62ccd5b5 100644 --- a/tex/context/base/status-lua.pdf +++ b/tex/context/base/status-lua.pdf diff --git a/tex/context/base/trac-lmx.lua b/tex/context/base/trac-lmx.lua index d85bd81d5..4f4ea62c4 100644 --- a/tex/context/base/trac-lmx.lua +++ b/tex/context/base/trac-lmx.lua @@ -665,14 +665,13 @@ function lmx.color(r,g,b,a) end end - -- these can be overloaded lmx.lmxfile = string.itself lmx.htmfile = string.itself lmx.popupfile = os.launch -function lmxmake(name,variables) +local function lmxmake(name,variables) local lmxfile = lmx.lmxfile(name) local htmfile = lmx.htmfile(name) if lmxfile == htmfile then @@ -682,7 +681,7 @@ function lmxmake(name,variables) return htmfile end -lmxmake = lmx.make +lmx.make = lmxmake function lmx.show(name,variables) local htmfile = lmxmake(name,variables) diff --git a/tex/context/base/util-prs.lua b/tex/context/base/util-prs.lua index 642968ccb..302b98441 100644 --- a/tex/context/base/util-prs.lua +++ b/tex/context/base/util-prs.lua @@ -167,7 +167,7 @@ local value = P(lbrace * C((nobrace + nestedbraces)^0) * rbrace) + C((nestedbraces + (1-comma))^0) local pattern = spaces * Ct(value*(separator*value)^0) --- "aap, {noot}, mies" : outer {} removes, leading spaces ignored +-- "aap, {noot}, mies" : outer {} removed, leading spaces ignored patterns.settings_to_array = pattern @@ -195,12 +195,40 @@ end -- -- "{123} , 456 " -> "123" "456" -local separator = space^0 * comma * space^0 -local value = P(lbrace * C((nobrace + nestedbraces)^0) * rbrace) - + C((nestedbraces + (1-(space^0*(comma+P(-1)))))^0) -local withvalue = Carg(1) * value / function(f,s) return f(s) end -local pattern_a = spaces * Ct(value*(separator*value)^0) -local pattern_b = spaces * withvalue * (separator*withvalue)^0 +-- local separator = space^0 * comma * space^0 +-- local value = P(lbrace * C((nobrace + nestedbraces)^0) * rbrace) +-- + C((nestedbraces + (1-(space^0*(comma+P(-1)))))^0) +-- local withvalue = Carg(1) * value / function(f,s) return f(s) end +-- local pattern_a = spaces * Ct(value*(separator*value)^0) +-- local pattern_b = spaces * withvalue * (separator*withvalue)^0 + +local cache_a = { } +local cache_b = { } + +function parsers.groupedsplitat(symbol,withaction) + if not symbol then + symbol = "," + end + local pattern = (withaction and cache_b or cache_a)[symbol] + if not pattern then + local symbols = S(symbol) + local separator = space^0 * symbols * space^0 + local value = P(lbrace * C((nobrace + nestedbraces)^0) * rbrace) + + C((nestedbraces + (1-(space^0*(symbols+P(-1)))))^0) + if withaction then + local withvalue = Carg(1) * value / function(f,s) return f(s) end + pattern = spaces * withvalue * (separator*withvalue)^0 + cache_b[symbol] = pattern + else + pattern = spaces * Ct(value*(separator*value)^0) + cache_a[symbol] = pattern + end + end + return pattern +end + +local pattern_a = parsers.groupedsplitat(",",false) +local pattern_b = parsers.groupedsplitat(",",true) function parsers.stripped_settings_to_array(str) if not str or str == "" then @@ -221,8 +249,6 @@ end -- parsers.process_stripped_settings("{123} , 456 ",function(s) print("["..s.."]") end) -- parsers.process_stripped_settings("123 , 456 ",function(s) print("["..s.."]") end) --- - local function set(t,v) t[#t+1] = v end diff --git a/tex/generic/context/luatex/luatex-fonts-merged.lua b/tex/generic/context/luatex/luatex-fonts-merged.lua index 884c5885e..6500989cc 100644 --- a/tex/generic/context/luatex/luatex-fonts-merged.lua +++ b/tex/generic/context/luatex/luatex-fonts-merged.lua @@ -1,6 +1,6 @@ -- merged file : luatex-fonts-merged.lua -- parent file : luatex-fonts.lua --- merge date : 12/30/14 09:48:12 +-- merge date : 12/31/14 16:52:11 do -- begin closure to overcome local limits and interference |