Description
I want to use pstricks
to place some stuff in a large (almost A0) pspicture
. Any stuff I place in the picture with the \rput
command, is not placed precisely. Why? The farther away from the grid origin I place it, the larger offset it gets. Here is a minimal working example.
Minimal working example
\documentclass[pstricks,border=2cm]{standalone}
\begin{document}
% Draw a large picture (81x81 cm)
\begin{pspicture}(81,81)
% This "X" in the grid origin (0,0) is placed precisely (no error here)
\rput{0}(0,0){X}
% An "X" put to (80,80), however, is placed with a significant offset (ERROR)
\rput{0}(80,80){X}
% Drawing a line that far away, on the other hand, works precisely again (no error)
\psline(79,79)(80,80)
% commands which draw the grid and label it on all 4 sides
\psset{origin={0,0}}
\psgrid[gridcolor=red, subgriddiv=1, griddots=10, gridlabels=12pt](81,81)(0,0)
\psgrid[gridcolor=red, subgriddiv=0, griddots=10, gridlabels=12pt]
\end{pspicture}
\end{document}
My configuration
I am using MiKTeX-XeTeX 2.9.4987 (0.9999.3) (MiKTeX 2.9 64-bit), Windows 7. XeTeX is Version 3.1415926-2.5-0.9999.3 (MiKTeX 2.9 64-bit)
In order to typeset a picture this large with xelatex
, I had to use the workaround Heiko Oberdiek suggested as a solution to this problem. It boils down to replacing the parameter -dEPSCrop
with -sPAPERSIZE=a0
in dvipdfmx.cfg
.
Error presentation
- X was specified to be placed by
\rput
at (80,80) but it is placed off grid by approx 3 millimeters. - Error does not happen with
\psline
which is drawn precisely where I specified:
I tried \rput(x,y){stuff}
where I gradually changed x
and y
. The error gets linearly bigger and bigger the farther from the grid's origin X is placed. Enabling the rulers in Acrobat Reader (used to view the resulting PDF) proved that the grid and the line are placed precisely. The X, however, is not.
Expected result
At the grid's origin everything looks fine (X is placed precisely):
I'd expect the X be placed just like this at (80, 80)
latex filename.tex
and thendvips -t unknown filename.dvi
and thengswin64c -dCompatibilityLevel=1.5 -dAutoRotatePages=/None -sDEVICE=pdfwrite -o filename.pdf filename.ps
. – Money Oriented Programmer Dec 4 '17 at 21:49