[pstricks] Accessing psfontdots

Herbert Voss Herbert.Voss at alumni.TU-Berlin.DE
Thu Jul 8 07:54:40 CEST 2004


Alan Ristow wrote:

> I'm trying to access the dot symbols used for plotting so I can create a
> legend. After trying to dissect the relevant parts of pstricks.tex, this
> is the best I can come up with:
> 
>   \makeatletter%
>     \newcommand*{\mychartdot}{%
>       \addto at pscode{\psds at o}%
>     }%
>   \makeatother%
> 
> The idea is that I can use the command \mychartdot to create a circle
> for my legend. The problem is, no dot shows up when I say \mychartdot
> and I can't figure out why. I suspect I need something to follow \psds at o
> in my definition -- perhaps say Dot, then issue a command to display Dot
> -- but I haven't found the right combination yet.
> 
> I figure if I can get this part right I might try to package a set of
> commands for making generic legends incorporating the pstricks dots --
> that is, if Herbert doesn't rattle it off in his sleep as he usually
> does. :-)

no need for writing PostScript code

Herbert


\documentclass[12pt]{article}
\usepackage{pstricks}

\begin{document}

\begin{figure}
\centering
\begin{pspicture}(3,3)
   \psdot[dotscale=4,dotstyle=pentagon](1.5,1.5)
\end{pspicture}
\caption{~\protect\raisebox{0.6ex}{\protect\psdot[dotscale=2,dotstyle=pentagon](0,0)} 
A pentagon}
\end{figure}

\newsavebox\Legend
\savebox\Legend{
\begin{tabular}[t]{ll}
\raisebox{0.6ex}{\psdot[dotscale=2,dotstyle=pentagon](0,0)} & A pentagon\\
\raisebox{0.6ex}{\psdot[dotscale=2,dotstyle=pentagon*](0,0)} & Another 
pentagon
\end{tabular}
}

\begin{figure}
\centering
\begin{pspicture}(3,3)
   \psdot[dotscale=4,dotstyle=pentagon](1,1)
   \psdot[dotscale=4,dotstyle=pentagon*](2,2)
\end{pspicture}
\caption{\usebox\Legend}
\end{figure}

\end{document}




-- 
http://TeXnik.de/
http://PSTricks.de/
ftp://ftp.dante.de/tex-archive/info/math/voss/Voss-Mathmode.pdf
http://www.dante.de/faq/de-tex-faq/
http://www.tex.ac.uk/cgi-bin/texfaq2html?introduction=yes




More information about the PSTricks mailing list