In my figure, I have a thick line that connects with the side of a box. However, the line does not connect completely with the box. Also, the line covers part of the box (which I don't want).
So, I want the lower edge of the line to connect completely with the box, and prevent the upper edge of the line to cover part of the box. It probably says how to deal with this in the PGF manual but I can't find it (and since I don't know the terminology for this, I can't search for it either).
Here is minimal example for the figure above.
\documentclass{standalone}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\node [draw, minimum size = 1cm] (box) {};
\draw [line width = 5pt] (2cm, 2cm) -- (box.east);
\end{tikzpicture}
\end{document}
Best Answer
second solution
Third solution
Fourth version With
reverseclip