diff options
author | Hans Hagen <pragma@wxs.nl> | 2019-07-16 22:42:53 +0200 |
---|---|---|
committer | Context Git Mirror Bot <phg@phi-gamma.net> | 2019-07-16 22:42:53 +0200 |
commit | a92a8d40ce567ecf5b0baacd9a93a94aac9a4a2d (patch) | |
tree | 17f7038c1c3b353bc2130af87066676d49f87184 /tex/context/base/mkiv/node-ref.lua | |
parent | 4bc28891615011ed3581836e9259434720e25830 (diff) | |
download | context-a92a8d40ce567ecf5b0baacd9a93a94aac9a4a2d.tar.gz |
2019-07-16 18:30:00
Diffstat (limited to 'tex/context/base/mkiv/node-ref.lua')
-rw-r--r-- | tex/context/base/mkiv/node-ref.lua | 59 |
1 files changed, 29 insertions, 30 deletions
diff --git a/tex/context/base/mkiv/node-ref.lua b/tex/context/base/mkiv/node-ref.lua index e12bd95bd..21fc4ce4d 100644 --- a/tex/context/base/mkiv/node-ref.lua +++ b/tex/context/base/mkiv/node-ref.lua @@ -166,33 +166,33 @@ local function dimensions(parent,start,stop) -- in principle we could move some -- todo: if no prev and no next and parent -- todo: we need a a list_dimensions for a vlist if getid(parent) == vlist_code then - if false then - local l = getlist(parent) - local c = l - local ok = false - while c do - if c == start then - ok = true - end - if ok and getid(c) == hlist_code then - break - else - c = getnext(c) - end - end - if ok and c then - if trace_areas then - report_area("dimensions taken of first line in vlist") - end - local w, h, d = getwhd(c) - return w, h, d, c - else - if trace_areas then - report_area("dimensions taken of vlist (probably wrong)") - end - return hlist_dimensions(start,stop,parent) - end - else + -- if false then + -- local l = getlist(parent) + -- local c = l + -- local ok = false + -- while c do + -- if c == start then + -- ok = true + -- end + -- if ok and getid(c) == hlist_code then + -- break + -- else + -- c = getnext(c) + -- end + -- end + -- if ok and c then + -- if trace_areas then + -- report_area("dimensions taken of first line in vlist") + -- end + -- local w, h, d = getwhd(c) + -- return w, h, d, c + -- else + -- if trace_areas then + -- report_area("dimensions taken of vlist (probably wrong)") + -- end + -- return hlist_dimensions(start,stop,parent) + -- end + -- else -- -- we can as well calculate here because we only have kerns and glue -- @@ -200,7 +200,7 @@ local function dimensions(parent,start,stop) -- in principle we could move some local last = nil local current = start local noflines = 0 - while current do + while current do -- can be loop local id = getid(current) if id == hlist_code or id == vlist_code or id == rule_code then if noflines == 0 then @@ -239,7 +239,7 @@ local function dimensions(parent,start,stop) -- in principle we could move some return hlist_dimensions(start,stop,parent) end end - end + -- end else if trace_areas then report_area("dimensions taken of range starting with %a using parent",nodecodes[id]) @@ -929,7 +929,6 @@ local function makedestination(width,height,depth,reference) end end - function nodes.destinations.handler(head) if head and topofstack > 0 then return (inject_areas(head,attribute,makedestination,stack,done)) |