6

The following document renders a nice sequence diagram for me:

\documentclass[12pt,english]{scrartcl}

\usepackage{babel} %\usepackage{pgfplots}

% Sequence diagrams: \usepackage{tikz} \usetikzlibrary{arrows,shadows} % for pgf-umlsd \usepackage[underline=true,rounded corners=false]{pgf-umlsd}

\begin{document}

\begin{sequencediagram} \newthread{a}{Client} \newthread{b}{Server} \mess{a}{X}{b} \mess{a}{Y}{b} \begin{call}{a}{$Z_a$}{b}{$Z_b$}\end{call} \end{sequencediagram}

\end{document}

Good sequence diagram

But when I uncomment the line \usepackage{pgfplots}, the vertical lines and bars vanish:

Bad sequence diagram

In my real document I need the pgfplots package. So how can I make the two compatible?


I'm using MiKTeX 2.9 and TeXworks 0.4.4 r1003 on Windows XP SP2; pgf-umlsd 0.5 and pgfplots 1.6.1. I will also need it to work on an FC11 Linux system that's stuck at TeXLive 2007.


Update

Although I can't find an exact match in the pgf-umlsd issues list, issue 15 seems to describe the same conflict between pgf-umlsd and pgf-umlcd, and this was fixed in pgf-umlsd 0.7.

I locally updated the package to 0.7 in my Windows environment, but the problem persisted.

1 Answers1

5

Although I can't find an exact match in the pgf-umlsd issues list, issue 15 seems to describe the same conflict between pgf-umlsd and pgf-umlcd, and this was fixed in pgf-umlsd 0.7. However, updating pgf-umlsd to 0.7 did not solve the problem. I reverted it back to 0.5.

Updating pgfplots to 1.7 did solve the problem (due to a bug in 1.6.1 that the package author points out in the comments below).

Having done this, a cursory check shows that my usage of pgfplots doesn't appear to be broken anywhere in my real .tex files.

I had to perform this package update manually, but it works in both the Windows and FC11 Linux environments.

  • The reason is: pgfplots 1.6.1 introduced a bug which lead to broken layers (i.e. your question is a duplicate of http://tex.stackexchange.com/questions/77594/why-does-pgfplots-package-cause-tikz-layer-to-disappear ). pgfplots 1.7 repairs this. Sorry. – Christian Feuersänger Oct 29 '12 at 20:50
  • @ChristianFeuersänger: Aha! Then, thanks not only for fixing it but also for allowing me to stop researching the reason this failed. :) – Lightness Races in Orbit Oct 29 '12 at 20:52