summaryrefslogtreecommitdiff
path: root/tex/context/base/mkiv/grph-img.lua
diff options
context:
space:
mode:
Diffstat (limited to 'tex/context/base/mkiv/grph-img.lua')
-rw-r--r--tex/context/base/mkiv/grph-img.lua7
1 files changed, 5 insertions, 2 deletions
diff --git a/tex/context/base/mkiv/grph-img.lua b/tex/context/base/mkiv/grph-img.lua
index 4b4bee1fc..49b082c58 100644
--- a/tex/context/base/mkiv/grph-img.lua
+++ b/tex/context/base/mkiv/grph-img.lua
@@ -602,8 +602,11 @@ do
local y = f:readcardinal4()
local u = f:readcardinal()
if u == 1 then -- meters
- -- x = round(0.0254 * x)
- -- y = round(0.0254 * y)
+ -- there was a reason why this was commented
+ x = round(0.0254 * x)
+ y = round(0.0254 * y)
+ if x == 0 then x = 1 end
+ if y == 0 then y = 1 end
end
specification.xres = x
specification.yres = y