summaryrefslogtreecommitdiff
path: root/tex/context/base/mkiv/anch-pos.lua
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2018-11-29 20:53:37 +0100
committerContext Git Mirror Bot <phg@phi-gamma.net>2018-11-29 20:53:37 +0100
commit9bd28a3039a458b054459fe1ef80161b107b798f (patch)
treec15bf6aedc4313de999a97bf92dc63b16ca60794 /tex/context/base/mkiv/anch-pos.lua
parent744095aa4676553437db0d71c281a74557a3222f (diff)
downloadcontext-9bd28a3039a458b054459fe1ef80161b107b798f.tar.gz
2018-11-29 19:54:00
Diffstat (limited to 'tex/context/base/mkiv/anch-pos.lua')
-rw-r--r--tex/context/base/mkiv/anch-pos.lua20
1 files changed, 10 insertions, 10 deletions
diff --git a/tex/context/base/mkiv/anch-pos.lua b/tex/context/base/mkiv/anch-pos.lua
index 4767aa259..b8a5f92c2 100644
--- a/tex/context/base/mkiv/anch-pos.lua
+++ b/tex/context/base/mkiv/anch-pos.lua
@@ -516,19 +516,20 @@ local function b_region(tag)
last.x = x ~= 0 and x or nil
last.y = y ~= 0 and y or nil
last.p = texgetcount("realpageno")
- insert(regions,tag)
+ insert(regions,tag) -- todo: fast stack
region = tag
end
local function e_region(correct)
local last = tobesaved[region]
local y = getvpos()
+ local x, y = getpos()
if correct then
local h = (last.y or 0) - y
last.h = h ~= 0 and h or nil
end
last.y = y ~= 0 and y or nil
- remove(regions)
+ remove(regions) -- todo: fast stack
region = regions[#regions]
end
@@ -544,15 +545,14 @@ local function setregionbox(n,tag,k,lo,ro,to,bo) -- kind
end
local box = getbox(n)
local w, h, d = getwhd(box)
- local x, y = getpos() -- hm, makes no sense here as not in shipout
tobesaved[tag] = {
- -- p = texgetcount("realpageno"), -- we copy them
- x = x ~= 0 and x or nil, -- was true
- y = y ~= 0 and y or nil,
- w = w ~= 0 and w or nil,
- h = h ~= 0 and h or nil,
- d = d ~= 0 and d or nil,
- k = k ~= 0 and k or nil,
+ -- p = texgetcount("realpageno"), -- we copy them
+ x = 0,
+ y = 0,
+ w = w ~= 0 and w or nil,
+ h = h ~= 0 and h or nil,
+ d = d ~= 0 and d or nil,
+ k = k ~= 0 and k or nil,
lo = lo ~= 0 and lo or nil,
ro = ro ~= 0 and ro or nil,
to = to ~= 0 and to or nil,