I am trying to draw some pictures using TikZ within LaTeX. I have started by using simple examples, but I am having trouble getting colors to show. For example, I use the following commands, but only get black and white output for the items created with TikZ. As suggested, I am supplying a full, compilable document that generates the behavior:





\draw [gray] (0,1) -- (2,1);
\draw [red] (0, 0.5) -- (2,0.5);
\draw [blue] (0,0) -- (2,0);

\textcolor{red}{this shows in red correctly}


I am using scientific workplace to create my document. I have used the tikz package, as well as the color and xcolor packages. Any thoughts as to why there is no color. I know the system is generally capable of creating color, as the second \textcolor statement comes out in red.

  • 3
    It would be great if you could turn your code into a full, compilable, minimal document that reproduces the described behaviour. You might be loading some packages that interfere with the colour. – Jake Sep 25 '11 at 3:34
  • 1
    This compiles fine (with color) for me. What compiler do you use (pdflatex?), and what viewer (Acrobat)? – Jake Sep 25 '11 at 4:55
  • 1
    By the way, tikz loads xcolor, so you don't need to load this explicitly yourself. – Jake Sep 25 '11 at 4:56
  • 3
    @stanford202: Interesting! You should post that as an answer and mark it as accepted, so other people stumbling across the same problem can find the answer more easily. It's also worth pointing out that this reliance on old TikZ/PGF versions is quite a serious drawback: The new version (2.1) includes many quite important features (such as left or right aligning text in nodes), and the recommendation to update to a current version is a very frequent one on this site. – Jake Sep 26 '11 at 23:30
  • 3
    I presume that you mean (in the update) "Scientific Workplace does not work with newer versions of pgf". As Jake said, it would be good to post that as an answer rather than an update to the question. – Andrew Stacey Sep 27 '11 at 6:50

In case anyone else has this problem, Scientific Workplace does not work with newer versions of pgf. So, you need to have an older version of pgf installed, e.g. v1.18, in order to use tikz.

See more here: http://forum.mackichan.com/node/565#comment-1200

(The above was added to the original answer by the original questioner. I've taken the liberty of posting this as an answer (CW) as part of "house keeping".)

| improve this answer | |
  • Just wanted to also mention that Scientific Workplace can be made to work with newer versions of pgf, but you must change the latex formatter from True Tex to something like MikTex. – profj Jul 9 '12 at 18:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.