Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

If I set \pagecolor{} to any color other than white, I will get a strange result.

rem batch.bat takes a file name without extension.
latex -interaction=nonstopmode %1
dvips -E %1 -o %1-temp.eps
epstool --copy --bbox %1-temp.eps %1.eps
ps2pdf -dEPSCrop %1.eps
\documentclass{minimal}
\usepackage{pstricks}
\pagecolor{red}% please try white or disable it.
\begin{document}
\begin{pspicture}[showgrid=true](2,2)
\psframe(2,2)
\end{pspicture}
\end{document}

Is it a bug?

share|improve this question

1 Answer 1

up vote 2 down vote accepted

No, this is not a bug in ps2pdf.

ps2pdf -dEPSCrop takes the boundingbox from the eps file. Here, epstool has put a very large bounding box in the file. epstool --copy --bbox uses the ghostscript bbox device to calculate the bounding box, and you already know that this has a problem in recent versions of ghostscript when there is a coloured background (whether you want to call this a "bug" in ghostscript is debatable).

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.