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.

Consider the following example. Why does the pattern not rotate correctly both for the tikz rotate and for the rotatebox approach. How can I fix it?

\documentclass{article}

\usepackage{tikz}
\usetikzlibrary{patterns}

\tikzstyle{platform}=[fill,pattern=north east lines,draw=none,minimum
width=3cm,minimum height=0.1cm,inner sep=0pt]

\begin{document}

\begin{tikzpicture}
   \draw[thick] (-1.5,0) -- (1.5,0);
   \node[platform,anchor=north] at (0,0){};
\end{tikzpicture}
\hspace{1cm}
\begin{tikzpicture}[rotate=80,transform shape]
   \draw[thick] (-1.5,0) -- (1.5,0);
   \node[platform,anchor=north] at (0,0){};
\end{tikzpicture}
\hspace{1cm}
\rotatebox{80}{
\begin{tikzpicture}
   \draw[thick] (-1.5,0) -- (1.5,0);
   \node[platform,anchor=north] at (0,0){};
\end{tikzpicture}}

\end{document}

Output:

Output

Edit:

Here is the output of \listfiles:

 *File List*
 article.cls    2007/10/19 v1.4h Standard LaTeX document class
  size10.clo    2007/10/19 v1.4h Standard LaTeX file (size option)
    tikz.sty    2010/10/13 v2.10 (rcs-revision 1.76)
     pgf.sty    2008/01/15 v2.10 (rcs-revision 1.12)
  pgfrcs.sty    2010/10/25 v2.10 (rcs-revision 1.24)
everyshi.sty    2001/05/15 v3.00 EveryShipout Package (MS)
  pgfrcs.code.tex
 pgfcore.sty    2010/04/11 v2.10 (rcs-revision 1.7)
graphicx.sty    1999/02/16 v1.0f Enhanced LaTeX Graphics (DPC,SPQR)
  keyval.sty    1999/03/16 v1.13 key=value parser (DPC)
graphics.sty    2009/02/05 v1.0o Standard LaTeX Graphics (DPC,SPQR)
    trig.sty    1999/03/16 v1.09 sin cos tan (DPC)
graphics.cfg    2009/08/28 v1.8 graphics configuration of TeX Live
  pdftex.def    2010/03/12 v0.04p Graphics/color for pdfTeX
  pgfsys.sty    2010/06/30 v2.10 (rcs-revision 1.37)
  pgfsys.code.tex
pgfsyssoftpath.code.tex    2008/07/18  (rcs-revision 1.7)
pgfsysprotocol.code.tex    2006/10/16  (rcs-revision 1.4)
  xcolor.sty    2007/01/21 v2.11 LaTeX color extensions (UK)
   color.cfg    2007/01/18 v1.5 color configuration of teTeX/TeXLive
 pgfcore.code.tex
pgfcomp-version-0-65.sty    2007/07/03 v2.10 (rcs-revision 1.7)
pgfcomp-version-1-18.sty    2007/07/23 v2.10 (rcs-revision 1.1)
  pgffor.sty    2010/03/23 v2.10 (rcs-revision 1.18)
 pgfkeys.sty    
 pgfkeys.code.tex
  pgffor.code.tex
    tikz.code.tex
supp-pdf.mkii
 ***********

After @cyberSingularity's comment I added the latest stable version of pdftex.def to my local texmf tree, but have the same problem again. Now my \listfiles looks like this:

 *File List*
 article.cls    2007/10/19 v1.4h Standard LaTeX document class
  size10.clo    2007/10/19 v1.4h Standard LaTeX file (size option)
    tikz.sty    2010/10/13 v2.10 (rcs-revision 1.76)
     pgf.sty    2008/01/15 v2.10 (rcs-revision 1.12)
  pgfrcs.sty    2010/10/25 v2.10 (rcs-revision 1.24)
everyshi.sty    2001/05/15 v3.00 EveryShipout Package (MS)
  pgfrcs.code.tex
 pgfcore.sty    2010/04/11 v2.10 (rcs-revision 1.7)
graphicx.sty    1999/02/16 v1.0f Enhanced LaTeX Graphics (DPC,SPQR)
  keyval.sty    1999/03/16 v1.13 key=value parser (DPC)
graphics.sty    2009/02/05 v1.0o Standard LaTeX Graphics (DPC,SPQR)
    trig.sty    1999/03/16 v1.09 sin cos tan (DPC)
graphics.cfg    2009/08/28 v1.8 graphics configuration of TeX Live
  pdftex.def    2011/05/27 v0.06d Graphics/color for pdfTeX
infwarerr.sty    2010/04/08 v1.3 Providing info/warning/error messages (HO)
 ltxcmds.sty    2011/11/09 v1.22 LaTeX kernel commands for general use (HO)
  pgfsys.sty    2010/06/30 v2.10 (rcs-revision 1.37)
  pgfsys.code.tex
pgfsyssoftpath.code.tex    2008/07/18  (rcs-revision 1.7)
pgfsysprotocol.code.tex    2006/10/16  (rcs-revision 1.4)
  xcolor.sty    2007/01/21 v2.11 LaTeX color extensions (UK)
   color.cfg    2007/01/18 v1.5 color configuration of teTeX/TeXLive
 pgfcore.code.tex
pgfcomp-version-0-65.sty    2007/07/03 v2.10 (rcs-revision 1.7)
pgfcomp-version-1-18.sty    2007/07/23 v2.10 (rcs-revision 1.1)
  pgffor.sty    2010/03/23 v2.10 (rcs-revision 1.18)
 pgfkeys.sty    
 pgfkeys.code.tex
  pgffor.code.tex
    tikz.code.tex
supp-pdf.mkii
 ***********

Here is also the output of pdflatex --version

pdfTeX 3.1415926-1.40.10-2.2 (TeX Live 2009/Debian)
kpathsea version 5.0.0
Copyright 2009 Peter Breitenlohner (eTeX)/Han The Thanh (pdfTeX).
There is NO warranty.  Redistribution of this software is
covered by the terms of both the pdfTeX copyright and
the Lesser GNU General Public License.
For more information about these matters, see the file
named COPYING and the pdfTeX source.
Primary author of pdfTeX: Peter Breitenlohner (eTeX)/Han The Thanh (pdfTeX).
Compiled with libpng 1.2.44; using libpng 1.2.44
Compiled with zlib 1.2.3.4; using zlib 1.2.3.4
Compiled with poppler version 0.16.4
share|improve this question
    
Both work as expected for me, with either DVI or PDF output. Perhaps check your packages are up to date? –  cyberSingularity Nov 24 '12 at 14:43
1  
It works on my system. Are you using TikZ v2.10 stable version or CVS? –  percusse Nov 24 '12 at 14:43
    
See my edit. When I setup my box next time I should switch to a manual texlive installation (instead of the ubuntu package) to have always an up to date version... –  student Nov 24 '12 at 14:53
1  
I see. It could be either that the PDF is not standards compliant, or that the viewers are not able to properly handle whichever parts of the standards are used to achieve those effects. I am not sure how you would go about determining which, but only in the first case would it be something to maybe discuss here... –  cyberSingularity Nov 24 '12 at 15:59
1  
Note that both evince and epdfview use the same underlying PDF rendering library poppler and I expect it is a problem there rather than with the latex-generated PDF. I guess you should check out the list of currently open bugs for poppler and close this question for now. –  cyberSingularity Nov 24 '12 at 16:22
show 5 more comments

closed as too localized by Martin Schröder, Kurt, Werner, Alan Munn, Qrrbrbirlbel Feb 2 '13 at 22:53

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

Browse other questions tagged or ask your own question.