0

I would like to have a bulleted list with vertical lines as in this thread:

Bulleted list with vertical lines

...but with an additional connection between the first and the last element, as in the following image:

enter image description here

Any ideas?

  • Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. – Community Jun 22 '22 at 11:30

2 Answers2

2

Not exactly what you want, but close, obtained with pstricks:

    \documentclass[svgnames]{article}
    \usepackage{enumitem}
    \usepackage{pst-node, pst-arrow}
\begin{document}

\psset{linecolor=DarkGray, ArrowInside=->, ArrowInsidePos=0.60} %\noindent
\dotnode(0,0.4ex){A}\qquad Step1\bigskip

\dotnode(0,0.4ex){B}\qquad Step2.\bigskip

\dotnode(0,0.4ex){C}\qquad Step3. Return to step 1.
\ncline{A}{B}\ncline{B}{C}
\ncbar[angle=180]{->}{C}{A}

\end{document} 

enter image description here

Bernard
  • 271,350
0

Here is a solution based on the accepted solution in the question you linked.

Important:

  • Only lists that are completely on one page work.
  • The arrow position must currently still be specified manually.
\documentclass{article}
\usepackage{tikz,tikzpagenodes}
\usetikzlibrary{arrows.meta}
\usetikzlibrary{calc}
\usetikzlibrary{decorations.markings}% ADDED
\usepackage{refcount}

\newcounter{mylist} % new counter for amount of lists \newcounter{mycnt}[mylist] % create new item counter \newcounter{mytmp}[mylist] % tmp counter needed for checking before/after current item

% ADDED postaction and decoration \newcommand{\drawoptionsconn}{ gray, shorten <= .5mm, shorten >= .5mm, thick, postaction={decorate}, decoration={markings,mark=at position 0.7 with {\arrow{Stealth}}}} \newcommand{\drawoptionsshort}{gray, shorten <= .5mm, shorten >= -1mm, thick, postaction={decorate}, decoration={markings,mark=at position 0.7 with {\arrow{Stealth}}}}

\newcommand{\myitem}{% Modified \item to update counter and save nodes \stepcounter{mycnt}% \item[\linkedlist{% i\alph{mylist}\arabic{mycnt}}]% \label{item-\alph{mylist}\arabic{mycnt}}% \ifnum\value{mycnt}>1% \ifnum\getpagerefnumber{item-\alph{mylist}\arabic{mytmp}}<\getpagerefnumber{item-\alph{mylist}\arabic{mycnt}}% \begin{tikzpicture}[remember picture,overlay]% \expandafter\draw\expandafter[\drawoptionsshort] (i\alph{mylist}\arabic{mycnt}) -- ++(0,3mm) -- (i\alph{mylist}\arabic{mycnt} |- current page text area.north);% draw short line \end{tikzpicture}% \else% \begin{tikzpicture}[remember picture,overlay]% \expandafter\draw\expandafter[\drawoptionsconn] (i\alph{mylist}\arabic{mytmp}) -- (i\alph{mylist}\arabic{mycnt});% draw the connecting lines \end{tikzpicture}% \fi% \fi% \addtocounter{mytmp}{2}% \IfRefUndefinedExpandable{item-\alph{mylist}\arabic{mytmp}}{}{% defined \ifnum\getpagerefnumber{item-\alph{mylist}\arabic{mytmp}}>\getpagerefnumber{item-\alph{mylist}\arabic{mycnt}}% \begin{tikzpicture}[remember picture,overlay]% \expandafter\draw\expandafter[\drawoptionsshort] (i\alph{mylist}\arabic{mycnt}) -- ++(0,-3mm) -- (i\alph{mylist}\arabic{mycnt} |- current page text area.south);% draw short line \end{tikzpicture}% \fi% }% \addtocounter{mytmp}{-1}% }

\newcommand{\linkedlist}[1]{ \raisebox{0pt}[0pt][0pt]{\begin{tikzpicture}[remember picture]% \node (#1) [gray,circle,fill,inner sep=1.5pt]{}; \end{tikzpicture}}% }

\newenvironment{myitemize}{% % Create new myitemize environment to keep track of the counters \stepcounter{mylist}% increment list counter \begin{itemize} }{\end{itemize}% }

% ADDED \newcommand\additionalConnection[1]{ \begin{tikzpicture}[remember picture,overlay]% \draw[gray, shorten <= .5mm, shorten >= .5mm, thick, postaction={decorate}, decoration={markings,mark=at position #1 with {\arrow{Stealth}}}] (i\alph{mylist}\arabic{mycnt}.west) -- ++(-.25,0) |- (i\alph{mylist}1.west); \end{tikzpicture}

}

\begin{document} \noindent First bullet list: \begin{myitemize} \myitem Step 1. \myitem Step 2. Return to step 1. \end{myitemize} \additionalConnection{.6}% with mark/arrow position

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\noindent Second bullet list: \begin{myitemize} \myitem Step 1. \myitem Step 2. \myitem Step 3. Return to step 1. \end{myitemize} \additionalConnection{.57}% with mark/arrow position

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\noindent Third bullet list: \begin{myitemize} \myitem Step 1. \myitem Step 2. \myitem Step 3. \myitem Step 4. Return to step 1. \end{myitemize} \additionalConnection{.55}% with mark/arrow position \end{document}

Bullet list with connected bullets. Closed loop.

Unknown
  • 822