diff options
author | Hans Hagen <pragma@wxs.nl> | 2014-06-06 23:52:00 +0200 |
---|---|---|
committer | Hans Hagen <pragma@wxs.nl> | 2014-06-06 23:52:00 +0200 |
commit | b7bf9474dd20221297fb47bf90c1ab6c6a2d9306 (patch) | |
tree | 7f3adafe1d7f02a6697318ef7dff035bd326c354 /tex/context/base/lpdf-mis.lua | |
parent | 1b8d827a6d33b746d004ac5cfab16de8840054e9 (diff) | |
download | context-b7bf9474dd20221297fb47bf90c1ab6c6a2d9306.tar.gz |
beta 2014.06.06 23:52
Diffstat (limited to 'tex/context/base/lpdf-mis.lua')
-rw-r--r-- | tex/context/base/lpdf-mis.lua | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/tex/context/base/lpdf-mis.lua b/tex/context/base/lpdf-mis.lua index 6efbd3882..748567125 100644 --- a/tex/context/base/lpdf-mis.lua +++ b/tex/context/base/lpdf-mis.lua @@ -253,21 +253,26 @@ local pagespecs = { local pagespec, topoffset, leftoffset, height, width, doublesided = "default", 0, 0, 0, 0, false +local pdfpaperheight = tex.pdfpageheight +local pdfpaperwidth = tex.pdfpagewidth + function codeinjections.setupcanvas(specification) local paperheight = specification.paperheight local paperwidth = specification.paperwidth local paperdouble = specification.doublesided if paperheight then texset('global','pdfpageheight',paperheight) + pdfpaperheight = paperheight end if paperwidth then texset('global','pdfpagewidth',paperwidth) + pdfpaperwidth = paperwidth end pagespec = specification.mode or pagespec topoffset = specification.topoffset or 0 leftoffset = specification.leftoffset or 0 - height = specification.height or tex.pdfpageheight - width = specification.width or tex.pdfpagewidth + height = specification.height or pdfpaperheight + width = specification.width or pdfpaperwidth if paperdouble ~= nil then doublesided = paperdouble end @@ -313,7 +318,7 @@ local function boxvalue(n) -- we could share them end local function pagespecification() - local pageheight = tex.pdfpageheight + local pageheight = pdfpaperheight local box = pdfarray { -- can be cached boxvalue(leftoffset), boxvalue(pageheight+topoffset-height), |