11

I'm new to Tikz and am working on converting SmartArt from MS PowerPoint to LaTeX. One of my diagrams looks like this:

Descriptive Diagram

I'm aware of the package smartdiagram, and I found the "descriptive diagram", which seems somewhat close to the above. But I am trying to show the steps of a process AND describe each of those steps (hence the directed hexagons down the left). Is there a way to do this that already exists in smartdiagram? Or do I need to draw my own tikzpicture?

18

Or, without the smartdiagram package:

\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{shapes.symbols,positioning}

\definecolor{myblue}{RGB}{79,129,189}

\tikzset{
myshape/.style={
  shape=signal,
  fill=myblue,
  minimum height=1.5cm,
  minimum width=1.5cm,
  text=white,
  signal pointer angle=130,
  signal to=east,
  signal from=west,
  rotate=-90,
  transform shape
  },
mytext/.style={
  draw=myblue,
  text width=7cm,
  minimum height=1.15cm,
  thick,
  outer sep=0pt
  }  
}
\newcounter{tmp}
\newcommand\MyDesc[3][]{
\stepcounter{tmp}%
\node[myshape,#1] (desc\thetmp) {};
\node[font=\color{white}] at (desc\thetmp) {#2};
\node[mytext,anchor=north west] at (desc\thetmp.north west) 
  {%
    \parbox[t]{2em}{\hfill$\bullet$\hfill\null}%
    \parbox[t]{\dimexpr\linewidth-2em\relax}{#3}%
  };
}

\begin{document}

\begin{tikzpicture}[]
\MyDesc{Foo 1}{Description 1}
\MyDesc[below = 1.5cm of desc1.north]{Foo 2}{Description 2}
\MyDesc[below = 1.5cm of desc2.north]{Foo 3}{Description 3}
\end{tikzpicture}

\end{document}

enter image description here

3
  • Great. Suppose I want to get rid of the bullet. Do I just delete \parbox[t]{2em}{\hfill$\bullet$\hfill\null}%? Mar 15 '14 at 18:34
  • 1
    @user1577636 Yes. Additionally, you change \parbox[t]{\dimexpr\linewidth-2em\relax}{#3} to \parbox[t]{\linewidth}{#3}. Mar 15 '14 at 18:36
  • @user1577636 I simplified the code in my updated answer. Mar 15 '14 at 23:33
19

With a small patch, it is possible to achieve:

enter image description here

which is far from being perfect, but looks like the reference picture.

The code:

\documentclass[12pt]{article} 
\usepackage{smartdiagram}
\usetikzlibrary{shapes.symbols}

\tikzset{description title/.append style={
    signal, 
    signal to=south, 
    signal from=north,
    yshift=-0.65cm,
  }
}
\begin{document} 
\begin{center}
\smartdiagramset{description title width=2cm, 
description title text width=1.75cm,
descriptive items y sep=2,
description text width=5.75cm,
module minimum height=1.25cm}
\smartdiagram[descriptive diagram]{%
{Set up,The set up operation consist of..},
{Run, {After having set up the program, you must run..}},
{Analyse, You must check what did with analytical tools like..},}
\end{center}
\end{document}
3
  • 3
    I'm planning to add this feature in the new release, thanks for the suggestion. Mar 15 '14 at 18:10
  • Yep. In the temporary workaround above, is there a way to scale down the whole thing (i.e. an equivalent to scale = 0.5 in tikz)? Mar 15 '14 at 20:55
  • @user1577636: sure, you can exploit \scale from graphicx package; then \scale{0.5}{\smartdiagram[..]{..}}. Mar 16 '14 at 8:35

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.