Package: pgf
Version: 2.10-1
Severity: normal
Tags: upstream

Hi,

The file
   /usr/share/texmf/tex/generic/pgf/libraries/pgflibraryplotmarks.code.tex
is buggy.  When you use the tex command
   \pgfuseplotmark{triangle*}
the triangle does not appear in the correct position, it is shifted to
the right by a little bit.  You can google this problem and see that
the solution is to append % to the lines in the definition of
\pgfdeclareplotmark{triangle*}.  You know in tex, newlines in
definitions often muck things up, you need to stick the comment on the
end of the line to fix it up.   Actually you probably could patch all
the other definitions in the file, but I only used the triangle* and
triangle so only tested it with those.

Here is a small test case for you:

   \documentclass{article}

   \usepackage{tikz}
   \usetikzlibrary{plotmarks}

   \begin{document}
   \begin{tikzpicture}
   \draw (-1, 0) -- (1, 0);
   \draw (0, -1) -- (0, 1);
   \node at (0,0) {\pgfuseplotmark{triangle*}};
   \end{tikzpicture}

   \end{document}

Just save it in a .tex file, pdflatex it, and view the pdf file.  The
triangle is not at (0, 0).  Then edit 
   /usr/share/texmf/tex/generic/pgf/libraries/pgflibraryplotmarks.code.tex
making sure the triangle* section looks like this

   % A stroke-filled triangle mark

   \pgfdeclareplotmark{triangle*}
   {%
     \pgfpathmoveto{\pgfqpoint{0pt}{\pgfplotmarksize}}%
     \pgfpathlineto{\pgfqpointpolar{-30}{\pgfplotmarksize}}%
     \pgfpathlineto{\pgfqpointpolar{-150}{\pgfplotmarksize}}%
     \pgfpathclose%
     \pgfusepathqfillstroke
   }

and everything will be fine, the triangle will appear exactly at (0, 0).

I did attempt to get this fixed upstream, but never got anywhere with them.
Perhaps we can just have a patch in debian?  Or you could try to push
it upstream and you will have more traction than I?

Thank you!

Matt


-- System Information:
Debian Release: 7.9
  APT prefers oldstable-updates
  APT policy: (500, 'oldstable-updates'), (500, 'oldstable')
Architecture: amd64 (x86_64)

Kernel: Linux 3.2.0-4-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_NZ.UTF-8, LC_CTYPE=en_NZ.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages pgf depends on:
ii  dpkg                       1.16.17
ii  latex-xcolor               2.11-1.1
ii  tex-common                 3.15
ii  texlive-latex-recommended  2012.20120611-5

pgf recommends no packages.

pgf suggests no packages.

-- no debconf information

Reply via email to