[Problem] pstricks.pro for dvipsone driver

Denis Girou Denis.Girou at idris.fr
Fri Oct 17 23:34:40 CEST 1997


-----------------------------------------------------------------------------
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.
-----------------------------------------------------------------------------

  D. P. Story <D.P.Story at uakron.edu> report in September that the macros
using triangles (\pstriangle, \trinode, \pstribox) doesn't work with his
installation, which use the dvipsone driver from Y&Y.

  After looking at it, I see that the problem come from the definition
of the /Triangle macro in pstricks.pro that cause problem with the dvipsone
driver. I already change the code is January 1997, to correct a bug reported,
that exist also for dvipsone.

  I don't succeed to understand why the current code doesn't work for
dvipsone (and more it seems really non logical that the changed code give
other thing than previous one!) Nevertheless, with the following modification,
D. P. Story says that this work well for him. I verify that it work too for
dvips driver (the only one I use myself).

  So, we can think to introduce this modification in the distribution,
even if I'm not happy to introduce a modification when I don't understand
clearly the reason.

  But before, we must check in any case that it work too for other drivers!
So, I would like to ask to people that use other ones that dvips and dvipsone
to confirm to me that it work too (personaly, as there is no reason to bother
the list with that).

  Thanks.

  Change in pstricks.pro:

% /Triangle { /mtrx CM def translate rotate /h ED 2 div /w ED dup 0 eq {
% pop } { CLW mul /d ED /h h d w h Atan sin Div sub def /w w d h w Atan 2
% div dup cos exch sin Div mul sub def } ifelse mark 0 d w neg d 0 h w d 0
% d /ArrowA { moveto } def /ArrowB { } def false Line closepath mtrx
% setmatrix } def
% /Triangle { /mtrx CM def translate rotate /h ED 2 div /w ED dup
% CLW mul /d ED /h h d w h Atan sin Div sub def /w w d h w Atan 2
% div dup cos exch sin Div mul sub def mark 0 d w neg d 0 h w d 0
% d /ArrowA { moveto } def /ArrowB { } def false Line closepath mtrx
% setmatrix } def
/Triangle { /mtrx CM def translate rotate /h ED 2 div /w ED dup 2 eq {
pop } { CLW mul /d ED /h h d w h Atan sin Div sub def /w w d h w Atan 2
div dup cos exch sin Div mul sub def } ifelse mark 0 d w neg d 0 h w d 0
d /ArrowA { moveto } def /ArrowB { } def false Line closepath mtrx
setmatrix } def

  You can test it on the test file adapted from the one he send me:

\documentclass{article}

\usepackage{pst-node}

\newpsobject{showgrid}{psgrid}{subgriddiv=1,griddots=10,gridlabels=6pt}

\begin{document}

\begin{pspicture}(5,5)
  \showgrid
  \pstriangle(2,2)(2,1)
\end{pspicture}
\hspace{1cm}
\begin{pspicture}(5,5)
  \showgrid
  \pstriangle*[dimen=middle,linecolor=blue,gangle=45](2,2)(2,1)
\end{pspicture}

\vspace{2cm}

\begin{pspicture}(5,5)
  \showgrid
  \rput(2,2){\pstribox*[trimode=U,fillcolor=yellow]{\red Hi World!}}
\end{pspicture}
\hspace{1cm}
\begin{pspicture}(5,5)
  \showgrid
  \rput[tl](0,3){\dianode{A}{Diamond}}
  \rput[br](4,0){\trinode[trimode=L]{B}{Triangle}}
  \nccurve[angleA=-135,angleB=90]{A}{B}
\end{pspicture}

\end{document}

D.G.

-----------------------------------------------------------------------------
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