summaryrefslogtreecommitdiff
path: root/tex
diff options
context:
space:
mode:
Diffstat (limited to 'tex')
-rw-r--r--tex/context/base/context-version.pdfbin4256 -> 4259 bytes
-rw-r--r--tex/context/base/mkiv/cldf-bas.lua102
-rw-r--r--tex/context/base/mkiv/cldf-ini.lua38
-rw-r--r--tex/context/base/mkiv/cont-new.mkiv2
-rw-r--r--tex/context/base/mkiv/context.mkiv2
-rw-r--r--tex/context/base/mkiv/status-files.pdfbin9095 -> 9244 bytes
-rw-r--r--tex/context/base/mkiv/status-lua.pdfbin367592 -> 367593 bytes
-rw-r--r--tex/context/base/mkiv/strc-itm.mkvi14
-rw-r--r--tex/context/base/mkiv/supp-box.mkiv11
-rw-r--r--tex/context/interface/mkiv/i-context.pdfbin774441 -> 774585 bytes
-rw-r--r--tex/context/interface/mkiv/i-readme.pdfbin60790 -> 60792 bytes
-rw-r--r--tex/generic/context/luatex/luatex-fonts-merged.lua2
12 files changed, 78 insertions, 93 deletions
diff --git a/tex/context/base/context-version.pdf b/tex/context/base/context-version.pdf
index c828f467a..c696a2842 100644
--- a/tex/context/base/context-version.pdf
+++ b/tex/context/base/context-version.pdf
Binary files differ
diff --git a/tex/context/base/mkiv/cldf-bas.lua b/tex/context/base/mkiv/cldf-bas.lua
index dffeefeb7..311816022 100644
--- a/tex/context/base/mkiv/cldf-bas.lua
+++ b/tex/context/base/mkiv/cldf-bas.lua
@@ -34,6 +34,7 @@ local variables = interfaces.variables
local nodepool = nodes.pool
local new_rule = nodepool.rule
local new_glyph = nodepool.glyph
+local current_attr = nodes.current_attr
local current_font = font.current
local texgetcount = tex.getcount
@@ -68,28 +69,15 @@ function context.utfchar(k)
end
end
-function context.par()
- context([[\par]]) -- no need to add {} there
-end
-
-function context.bgroup()
- context("{")
-end
-
-function context.egroup()
- context("}")
-end
-
-function context.space()
- context("\\space") -- no " " as that gets intercepted
-end
-
function context.rule(w,h,d,dir)
+ local rule
if type(w) == "table" then
- context(new_rule(w.width,w.height,w.depth,w.dir))
+ rule = new_rule(w.width,w.height,w.depth,w.dir)
else
- context(new_rule(w,h,d,dir))
+ rule = new_rule(w,h,d,dir)
end
+ rule.attr = current_attr()
+ context(rule)
end
function context.glyph(id,k)
@@ -97,59 +85,63 @@ function context.glyph(id,k)
if not k then
id, k = current_font(), id
end
- context(new_glyph(id,k))
+ local glyph = new_glyph(id,k)
+ glyph.attr = current_attr()
+ context(glyph)
end
end
--- we also register these in core:
+local function ctx_par () context("\\par") end
+local function ctx_space() context("\\space") end
-ctxcore.par = context.par
-ctxcore.space = context.space
-ctxcore.bgroup = context.bgroup
-ctxcore.egroup = context.egroup
+context.par = ctx_par
+context.space = ctx_space
--- not yet used ... but will get variant at the tex end as well
+ctxcore.par = ctx_par
+ctxcore.space = ctx_space
-function ctxcore.sethboxregister(n) context([[\setbox %s\hbox]],n) end
-function ctxcore.setvboxregister(n) context([[\setbox %s\vbox]],n) end
+local function ctx_bgroup() context("{") end
+local function ctx_egroup() context("}") end
-function ctxcore.starthboxregister(n)
- if type(n) == "number" then
- context([[\setbox%s\hbox{]],n)
- else
- context([[\setbox\%s\hbox{]],n)
- end
-end
+context.bgroup = ctx_bgroup
+context.egroup = ctx_egroup
-function ctxcore.startvboxregister(n)
- if type(n) == "number" then
- context([[\setbox%s\vbox{]],n)
- else
- context([[\setbox\%s\vbox{]],n)
- end
-end
+ctxcore.bgroup = ctx_bgroup
+ctxcore.egroup = ctx_egroup
-ctxcore.stophboxregister = ctxcore.egroup
-ctxcore.stopvboxregister = ctxcore.egroup
+-- not yet used ... but will get variant at the tex end as well
-function ctxcore.flushboxregister(n)
- if type(n) == "number" then
- context([[\box%s ]],n)
- else
- context([[\box\%s]],n)
- end
+local function setboxregister(kind,n)
+ context(type(n) == "number" and [[\setbox%s\%s]] or [[\setbox\%s\%s]],n,kind)
end
-function ctxcore.beginvbox()
- context([[\vbox{]]) -- we can do \bvbox ... \evbox (less tokens)
+function ctxcore.sethboxregister(n) setboxregister("hbox",n) end
+function ctxcore.setvboxregister(n) setboxregister("vbox",n) end
+function ctxcore.setvtopregister(n) setboxregister("vtop",n) end
+
+local function startboxregister(kind,n)
+ context(type(n) == "number" and [[\setbox%s\%s{]] or [[\setbox\%s\%s{]],n,kind)
end
-function ctxcore.beginhbox()
- context([[\hbox{]]) -- todo: use fast one
+function ctxcore.starthboxregister(n) startboxregister("hbox",n) end
+function ctxcore.startvboxregister(n) startboxregister("vbox",n) end
+function ctxcore.startvtopregister(n) startboxregister("vtop",n) end
+
+ctxcore.stophboxregister = ctx_egroup
+ctxcore.stopvboxregister = ctx_egroup
+ctxcore.stopvtopregister = ctx_egroup
+
+function ctxcore.flushboxregister(n)
+ context(type(n) == "number" and [[\box%s ]] or [[\box\%s]],n)
end
-ctxcore.endvbox = ctxcore.egroup
-ctxcore.endhbox = ctxcore.egroup
+function ctxcore.beginhbox() context([[\hbox{]]) end
+function ctxcore.beginvbox() context([[\vbox{]]) end
+function ctxcore.beginvtop() context([[\vtop{]]) end
+
+ctxcore.endhbox = ctx_egroup
+ctxcore.endvbox = ctx_egroup
+ctxcore.endvtop = ctx_egroup
local function allocate(name,what,cmd)
local a = format("c_syst_last_allocated_%s",what)
diff --git a/tex/context/base/mkiv/cldf-ini.lua b/tex/context/base/mkiv/cldf-ini.lua
index a77f25f41..3816e7755 100644
--- a/tex/context/base/mkiv/cldf-ini.lua
+++ b/tex/context/base/mkiv/cldf-ini.lua
@@ -936,27 +936,8 @@ end
-- end
-- end
-local generics = { } context.generics = generics
-
--- local indexer = function(parent,k)
--- if type(k) == "string" then
--- local c = "\\" .. tostring(generics[k] or k)
--- local f = function(first,...)
--- if first == nil then
--- flush(currentcatcodes,c)
--- else
--- return writer(parent,c,first,...)
--- end
--- end
--- parent[k] = f
--- return f
--- else
--- return context -- catch
--- end
--- end
-
local core = table.setmetatableindex(function(parent,k)
- local c = "\\" .. tostring(generics[k] or k)
+ local c = "\\" .. k -- tostring(k)
local f = function(first,...)
if first == nil then
flush(currentcatcodes,c)
@@ -986,12 +967,11 @@ context.core = core
--
-- indexer = function(parent,k)
-- if type(k) == "string" then
--- local s = tostring(generics[k] or k)
--- local t = create(s)
+-- local t = create(k)
-- if t.cmdname == "undefined_cs" then
--- report_cld("macro \\%s is not yet defined",s)
--- token.set_macro(s,"")
--- t = create(s)
+-- report_cld("macro \\%s is not yet defined",k)
+-- token.set_macro(k,"")
+-- t = create(k)
-- end
-- local i = t.id
-- local f = function(first,...)
@@ -1030,7 +1010,7 @@ context.core = core
-- end
--
-- local function indexer(parent,k)
--- local c = "\\" .. tostring(generics[k] or k)
+-- local c = "\\" .. k -- tostring(k)
-- local f = function(...)
-- return constructor(parent,k,c,...)
-- end
@@ -1053,7 +1033,7 @@ do
context.protectedcs = protectedcs
local function fullindexer(t,k)
- local c = "\\" .. tostring(generics[k] or k)
+ local c = "\\" .. k -- tostring(k)
local v = function(first,...)
if first == nil then
flush(prtcatcodes,c)
@@ -1066,7 +1046,7 @@ do
end
local function onlyindexer(t,k)
- local c = "\\" .. tostring(generics[k] or k)
+ local c = "\\" .. k -- tostring(k)
local v = function()
flush(prtcatcodes,c)
end
@@ -1658,7 +1638,7 @@ local formatted = { } context.formatted = formatted
local function indexer(parent,k)
if type(k) == "string" then
- local c = "\\" .. tostring(generics[k] or k)
+ local c = "\\" .. k
local f = function(first,second,...)
if first == nil then
flush(currentcatcodes,c)
diff --git a/tex/context/base/mkiv/cont-new.mkiv b/tex/context/base/mkiv/cont-new.mkiv
index a85a6175d..fb4707e9e 100644
--- a/tex/context/base/mkiv/cont-new.mkiv
+++ b/tex/context/base/mkiv/cont-new.mkiv
@@ -11,7 +11,7 @@
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.
-\newcontextversion{2016.07.22 20:08}
+\newcontextversion{2016.07.23 13:35}
%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/mkiv/context.mkiv b/tex/context/base/mkiv/context.mkiv
index e1007750d..1f773ada8 100644
--- a/tex/context/base/mkiv/context.mkiv
+++ b/tex/context/base/mkiv/context.mkiv
@@ -39,7 +39,7 @@
%D up and the dependencies are more consistent.
\edef\contextformat {\jobname}
-\edef\contextversion{2016.07.22 20:08}
+\edef\contextversion{2016.07.23 13:35}
\edef\contextkind {beta}
%D For those who want to use this:
diff --git a/tex/context/base/mkiv/status-files.pdf b/tex/context/base/mkiv/status-files.pdf
index 2c5d3bad0..d13f9afa1 100644
--- a/tex/context/base/mkiv/status-files.pdf
+++ b/tex/context/base/mkiv/status-files.pdf
Binary files differ
diff --git a/tex/context/base/mkiv/status-lua.pdf b/tex/context/base/mkiv/status-lua.pdf
index 8c4f7a84b..9bcec69dd 100644
--- a/tex/context/base/mkiv/status-lua.pdf
+++ b/tex/context/base/mkiv/status-lua.pdf
Binary files differ
diff --git a/tex/context/base/mkiv/strc-itm.mkvi b/tex/context/base/mkiv/strc-itm.mkvi
index fc05fc669..33b8aee1d 100644
--- a/tex/context/base/mkiv/strc-itm.mkvi
+++ b/tex/context/base/mkiv/strc-itm.mkvi
@@ -121,6 +121,11 @@
% \noitem \startitemize[a] \item Item 2.a. \item Item 2.b. \stopitemize
% \stopitemize
%
+% \startitemize[n,repeat][width=0pt]
+% \noitem \startitemize[a][width=2em] \item Item 1.a. \item Item 1.b. \stopitemize
+% \noitem \startitemize[a][width=2em] \item Item 2.a. \item Item 2.b. \stopitemize
+% \stopitemize
+%
% \startbuffer
% \item
% \startitemize[n]
@@ -1184,8 +1189,13 @@
\unexpanded\def\strc_itemgroups_start_do_item
{\startitemgroupitem}
-\unexpanded\def\strc_itemgroups_start_no_item % ?
- {\startitemgroupitem}
+\unexpanded\def\strc_itemgroups_start_no_item
+ {\let\currentitemreference\empty
+ \strc_itemgroups_increment_item_counter
+ %\advance\c_strc_itemgroups_n_of_items\plusone
+ \setbox\b_strc_itemgroups\emptyhbox
+ \strc_itemgroups_check_for_repeated
+ \ignorespaces}
\unexpanded\def\strc_itemgroups_start_button[#destination]%
{\edef\m_strc_itemgroups_destination{#destination}%
diff --git a/tex/context/base/mkiv/supp-box.mkiv b/tex/context/base/mkiv/supp-box.mkiv
index 745b37f79..ba00a9e1d 100644
--- a/tex/context/base/mkiv/supp-box.mkiv
+++ b/tex/context/base/mkiv/supp-box.mkiv
@@ -2920,21 +2920,24 @@
\definesystemattribute [runningtext] [public]
-\unexpanded\def\runninghbox{\hbox attr \runningtextattribute \plusone} % not yet in i-*
+%unexpanded\def\runninghbox{\hbox attr \runningtextattribute \plusone} % not yet in i-*
\unexpanded\def\runninghbox{\hbox attr \runningtextattribute \fontid\font} % not yet in i-*
%D To complement lua (yet undocumented):
-\unexpanded\def\beginvbox{\vbox\bgroup} \let\endvbox\egroup
\unexpanded\def\beginhbox{\hbox\bgroup} \let\endhbox\egroup
+\unexpanded\def\beginvbox{\vbox\bgroup} \let\endvbox\egroup
+\unexpanded\def\beginvtop{\vtop\bgroup} \let\endvtop\egroup
-\unexpanded\def\setvboxregister#1{\setbox#1\vbox}
\unexpanded\def\sethboxregister#1{\setbox#1\hbox}
+\unexpanded\def\setvboxregister#1{\setbox#1\vbox}
+\unexpanded\def\setvtopregister#1{\setbox#1\vtop}
\unexpanded\def\flushboxregister#1{\box\numexpr#1\relax}
\unexpanded\def\starthboxregister#1{\setbox#1\hbox\bgroup} \let\stophboxregister\egroup
-\unexpanded\def\startvboxregister#1{\setbox#1\hbox\bgroup} \let\stopvboxregister\egroup
+\unexpanded\def\startvboxregister#1{\setbox#1\vbox\bgroup} \let\stopvboxregister\egroup
+\unexpanded\def\startvtopregister#1{\setbox#1\vtop\bgroup} \let\stopvtopregister\egroup
\protect \endinput
diff --git a/tex/context/interface/mkiv/i-context.pdf b/tex/context/interface/mkiv/i-context.pdf
index c8a99637b..d62c1fc3f 100644
--- a/tex/context/interface/mkiv/i-context.pdf
+++ b/tex/context/interface/mkiv/i-context.pdf
Binary files differ
diff --git a/tex/context/interface/mkiv/i-readme.pdf b/tex/context/interface/mkiv/i-readme.pdf
index feabe33b7..8d9ab851e 100644
--- a/tex/context/interface/mkiv/i-readme.pdf
+++ b/tex/context/interface/mkiv/i-readme.pdf
Binary files differ
diff --git a/tex/generic/context/luatex/luatex-fonts-merged.lua b/tex/generic/context/luatex/luatex-fonts-merged.lua
index 13bec6568..b6c46e2db 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 : c:/data/develop/context/sources/luatex-fonts-merged.lua
-- parent file : c:/data/develop/context/sources/luatex-fonts.lua
--- merge date : 07/22/16 20:08:39
+-- merge date : 07/23/16 13:35:55
do -- begin closure to overcome local limits and interference