4

Is it possible to use the boundary of a shape defined as some path as a new path? In the following example

\documentclass{article}
\usepackage{tikz}

\begin{document}

\begin{tikzpicture}[scale=3]
  \draw [color=gray, line width=17pt] (2,0) -- (3,1); 
      \draw [color=gray, line width=7pt] (3,0) -- (2,1);
\end{tikzpicture}

\end{document}

I would like to obtain the boundary of the resulting cross as a new path, which one can draw or fill.

enter image description here

The MWE is in TikZ, but I am interested, if it possible in any tool (TikZ, PostScript, psTricks, MetaPost, etc.). Especially PostScript gives me some hope, because we can use there outline of font characters. However I have no idea, how it may be possible in the case of an ordinary path.

I know that in the above simple example I can simulate a filled region with a boundary by using two copies of a bit different dimensions and filling them, say black and grey. However, as far as I understand, it is possible, because we know the centre of the shape.

0 Answers0