i have the following mwe
\documentclass[tikz,border=4pt]{standalone}
\usetikzlibrary{arrows}
\begin{document}
\begin{tikzpicture}[->,>=angle 45,scale=3,ultra thick]
\draw[help lines] (-.1,-.9) grid (1.1,.1);
\draw[>=triangle 60,fill=red,draw=teal](0,-0.1)--++(1,0);
\draw[>=latex,fill=blue,draw=violet](0,-0.2)--++(1,0);
\draw[>=stealth,fill=blue,draw=violet](0,-0.3)--++(1,0);
\draw[](0,-0.4)--++(1,0);
\draw[draw=cyan](0,-.5)--++(1,0);
\draw[draw=orange](0,-.6)--++(1,0);
\end{tikzpicture}
\end{document}
the compiled pdf file is expected as follows,
but the compiled dvi file have different arrow tip color,
after commenting one line
\documentclass[tikz,border=4pt]{standalone}
\usetikzlibrary{arrows}
\begin{document}
\begin{tikzpicture}[->,>=angle 45,scale=3,ultra thick]
\draw[help lines] (-.1,-.9) grid (1.1,.1);
\draw[>=triangle 60,fill=red,draw=teal](0,-0.1)--++(1,0);
\draw[>=latex,fill=blue,draw=violet](0,-0.2)--++(1,0);
\draw[>=stealth,fill=blue,draw=violet](0,-0.3)--++(1,0);
% \draw[](0,-0.4)--++(1,0);
\draw[draw=cyan](0,-.5)--++(1,0);
\draw[draw=orange](0,-.6)--++(1,0);
\end{tikzpicture}
\end{document}
the output pictures are normal and consistant again,
is there anything special about the commented line, or that is just a bug somehow? i was think of exploiting that to change the arrow tip color only without resorting to the advanced decoration
option. now it seems that changing color of angle 45
type arrow tip is indeed trickier than latex
/stealth
type.
Best Answer
CW from the comments:
.dvi
files do not contain any color or graphics per se; what they can contain arespecial
s. Thesespecial
s are there for the benefit of post-processing backend software; likedvips
,dvipdfm
or the integratedpdf
backend ofpdflatex
.However, many
dvi
viewers will give it a shot to interpret somespecial
s. Color changes are hard to implement, you need a whole color stack to pop and push colors at the appropriate moments (consider a color change inside floating material). Hence, manydvi
viewers fail some of the time. Finally, Tikz is really meant only forpdf
/ps
, notdvi
.