2

I'm trying to achieve equal distances between the blocks in my priority descriptive diagram.

The problem is that not all nodes have the same number of lines, but apparently the centers of the blocks are equally spaced, independently of the block size.

The only relevant option that I found in the documentation is descriptive items y sep, but this is only a scaling factor and no offset.

\documentclass[tikz]{standalone}
\usepackage{tikz}
\usepackage{smartdiagram}
\begin{document}
\smartdiagramset{
    uniform color list=blue!10 for all items,
    % descriptive items y sep=2.5 -> only a factor, no absolute value :(
}
\smartdiagram[priority descriptive diagram]{
    \textbf{Small node},
    \textbf{Small node},
    \textbf{Big node}\\Here\\are\\multiple\\lines,
    \textbf{Small node}
}
\end{document}

enter image description here

1 Answer 1

0

Yes, looks like the y-coordinates of those nodes are simply set to multiples of some given length, so there are no settings to do that automatically. It's not a huge job to create a similar diagram manually though. In the code below I reused some styles from smartdiagram.

output of the code below

\documentclass[tikz,border=5mm]{standalone}
\usepackage{tikz}
\usepackage{smartdiagram}
\usetikzlibrary{chains, backgrounds}
\begin{document}

\begin{tikzpicture}
% \col is used in the description style so needs to be defined
\newcommand{\col}{blue!10}

\begin{scope}[
   % when naming the chain "c", the nodes in the chain are named c-1, c-2 etc.
   start chain=c going above,
   % set distance between nodes
   node distance=2mm,
   local bounding box=a
   ]

\foreach \t in {
    \textbf{Small node},
    \textbf{Small node},
    \textbf{Big node}\\Here\\are\\multiple\\lines,
    \textbf{Small node}}
  \node [description, drop shadow, on chain, align=center] {\t};

\end{scope}

% \distancemodules is used in the priority arrow style, so needs to be defined
% sets length of big arrow
\newcommand{\distancemodules}{7cm}

% draw big arrow on side
\node [priority arrow, left=7mm, anchor=before tail] (f) at (a.south west) {};

% draw ticks on big arrow
\foreach \i in {1,...,4}
   \draw [\col, line width=5pt]  (c-\i -| f.south) -- (c-\i -| f.north);

\end{tikzpicture}
\end{document}
1

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .