1

How to draw a curly brack around the nodes. Like I have given in the image.

enter image description here

\begin{center}
\begin{tikzpicture}[shorten <=1cm,shorten >=1cm,-latex, align=center, node distance=1cm and 10cm,on grid,auto]

    \node (Owner) {\underline{\textbf{Owner}}};
    \node (Client) [right=of Owner] {\underline{\textbf{User}}};

    \node (Owner1) [below=1.5cm of Owner] {};
    \node (Owner2) [below=of Owner1] {};

   \node (Client1) [below=1.5cm of Client] {};
   \node (Client2) [below=of Client1] {};

   \path[-latex] 
   (Client1)    edge    node [above]{(1) Request Services} (Owner1)
   (Owner2)     edge    node [above]{(2) Sends addr } (Client2);

\end{tikzpicture}
\end{center}
3

You can use the decorations library of tikz:

enter image description here

Code:

\documentclass{standalone}    
\usepackage{tikz}
\usetikzlibrary{positioning, decorations.pathreplacing}    

\begin{document}    
\begin{tikzpicture}

    \begin{scope}[shorten <=1cm,shorten >=1cm,-latex, align=center, node distance=1cm and 10cm,on grid,auto]
    \node (Owner) {\underline{\textbf{Owner}}};
    \node (Client) [right=of Owner] {\underline{\textbf{User}}};

    \node (Owner1) [below=1.5cm of Owner] {};
    \node (Owner2) [below=of Owner1] {};

   \node (Client1) [below=1.5cm of Client] {};
   \node (Client2) [below=of Client1] {};

   \path[-latex] 
   (Client1)    edge    node [above]{(1) Request Services} (Owner1)
   (Owner2)     edge    node [above]{(2) Sends addr } (Client2);
    \end{scope}

    \draw [decorate, decoration={brace}] (Client.east |- Client1.north) -- (Client.east |- Client2.south) node [midway, anchor=west, align=left] {write\\something};

\end{tikzpicture}
\end{document}
| improve this answer | |
1

You can draw a brace using this:

\usetikzlibrary{decorations.pathreplacing}
\begin{tikzpicture}
    \draw [thick, decorate, decoration={brace,amplitude=10pt, mirror}](0,0) -- (0,10) node[midway,right,xshift=7pt] {Some Text};
\end{tikzpicture}

I assume you can fit it for your needs.

| improve this answer | |

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.