Pstricks' \psgrid causes ghostscript error

Denis Girou Denis.Girou at idris.fr
Thu Nov 5 12:53:32 CET 1998


-----------------------------------------------------------------------------
This is the PSTricks mailing list, devoted to discussions about computational
graphics in (La)TeX using the PSTricks package from Timothy van Zandt.
For help using this mailing list, see instructions at the end of message.
-----------------------------------------------------------------------------

The following message is a courtesy copy of an article
that has been posted to comp.text.tex as well.

>>>>> "Loris.Bennett" == Loris Bennett <loris at align.physik.tu-berlin.de> writes:

    Loris.Bennett> Hello All,
    Loris.Bennett> Is it a known problem that pstricks' \psgrid command can cause
    Loris.Bennett> a postscript error?

    Loris.Bennett> I'm using Timothy Van Zandt's seminar `seminar' class together 
    Loris.Bennett> with the `pstricks' and `graphicx' packages. No errors occur
    Loris.Bennett> during compilation, but both ghostview (V1.5) and xpsview (V1.0.7)
    Loris.Bennett> are unable to display the postscript produced by dvips.

    Loris.Bennett> I seem to remember having the problem once before and solving it
    Loris.Bennett> by changing the order in which the packages are loaded. However,
    Loris.Bennett> this time it hasn't helped.

  Loris send me today two test cases, where problems have the same origin.

    1/ Without Seminar

\documentclass{article}

\usepackage{pstricks}
\usepackage{graphicx}

\begin{document}
\begin{pspicture}(5,5)
  \psgrid
\end{pspicture}
\end{document}

  This cause a LaTeX \GenericError error. This is rather surprising
and I think that David Carlisle is the only one able to give the "real"
explanation... We just can see that the problem disappear if we inverse the
order of the two packages loading.

  But in any case, the origin is clear (and so the workaround...): there is
an incompatibility between `graphicx' and `pstricks', in rather the same way
than between `color' and `pstricks'. The workaround (in fact what I always
used!) is to not load `pstricks' but `pstcol' (the compatibility interface
between `color' and `pstricks' written by David and available in the same
place than `color' and `graphicx').

  So, you must use (this require a configurated color.cfg file):

\documentclass{article}

\usepackage{pstcol}
\usepackage{graphicx}

  I'll at least add this problem to the list of "Known pitfalls" in the
PSTricks general README.

    2/ With Seminar

\documentclass[semcolor]{seminar}

\usepackage{graphicx}
\usepackage{pstricks}

\begin{document}
\begin{slide}
\begin{pspicture}(5,5)
  \psgrid
\end{pspicture}
\end{slide}
\end{document}

  This generate too a LaTeX \GenericError error for the same reason,
as `semcolor' ... just start by loading `pstricks'.

  In any case, as shown in the Seminar FAQ, I strongly discourage today to
continue to use the color macros of PSTricks (as `semcolor' implicitely do)
but the standard and supported `color' package. So, with Seminar you must use
something like:

\documentclass{seminar}

\usepackage{pstcol}
\usepackage{semcolor}
\usepackage{graphicx}

    Loris.Bennett> For the PSecialists amoungst you, the ghostscript error is

    Loris.Bennett>   Error: /undefined in \dimen@

    Loris.Bennett> folowed by a whole lot of incomprehensible gubbins.

  Loris tell me about a third category error (the one above), this time not at
the LaTeX level but at the PostScript one. The origin can be different.

  So, when you will found some time, try to send me another test case for it.

  Thanks for the report!

Denis Girou
--
---------------------------------------------------------------------------
Institut du De'veloppement et des Ressources en Informatique Scientifique |
Centre National de la Recherche Scientifique                              |
Ba^timent 506 - B.P. 167 - 91403 Orsay Cedex - France                     |
---------------------------------------------------------------------------

-----------------------------------------------------------------------------
The list interface (subscription, information, access to the archives) is on:
http://www.tug.org/cgi-bin/lwgate/pstricks
Otherway to unsubscribe, send mail to pstricks-request at mail.tug.org
with a blank subject and in body the line unsubscribe <email-address>
-----------------------------------------------------------------------------



More information about the PSTricks mailing list