[Tex/LaTex] Add gaps to lines with TikZ

pathstikz-pgf

I am drawing some block diagrams with TikZ. Sometimes, I need to combine several blocks together to form one large group by adding a border around the corresponding blocks. However, there are some arrows which cross the border, as shown in this picture.

Block diagram without gaps

The arrow "to ALC loop" and the arrow just below it looks ugly. What I would like to do is the following (note the small gaps around the arrows where they cross the thick border):

enter image description here

How is that possible with TikZ? The arrows are just ordinary arrows drawn with the \draw[->] (from) -- (to); macro, and the thick border is also just an ordinary line.

Best Answer

Using @AboAmmar MWE, preaction can be used in the simple case:

\documentclass[border=2pt]{standalone}
\usepackage{tikz}
\begin{document}

\begin{tikzpicture}[> = latex]
\node [draw, thick, minimum size=5em] (rec) {};
\node [draw] (div) {$\div$};

\draw [preaction={draw, line width=3pt, white}][<->] (div) -- ++(5em,0);

\end{tikzpicture}

\end{document}

EDIT: there is some problem nevertheless - arrow tip changes path bending dependently on the size of this arrow tip. So the idea is not good solution. enter image description here

\documentclass[border=2pt]{standalone}
\usepackage{tikz}

\tikzset{
    outlined arrow/.style={
        preaction={{}-{},draw,line width=3pt,yellow}
    }
}

\begin{document}    
\begin{tikzpicture}[> = latex]
\node [draw,thick,minimum size=5em] (rec) {};
\node [draw] (div) {$\div$};

\draw [outlined arrow][<->] (div) -- ++(5em,0);
\draw [outlined arrow][<->,shorten <=2pt] (div) .. controls +(-90:15mm) and +(180:15mm) .. ++(5em,-5em);

\end{tikzpicture}
\end{document}

EDIT 2: In the above case black arrow bent line goes not in the middle of yellow line - dependently on the arrow size. I found that @cfr response (arrow tip size independent on the line width) can be useful a bit here. The code below works only when the arrow tip setup my arrow is passed through optional argument.

enter image description here

\documentclass[border=2pt]{standalone}
\usepackage{tikz}
\usetikzlibrary{arrows.meta}

\begin{document}
\begin{tikzpicture}[
    outlined arrow/.style={preaction={double=yellow,double distance=2pt,draw=red}},
    my arrow/.style={>={LaTeX[length=2mm]}},
    yscale=0.6
]
\node [draw,thick,minimum size=5em] (rec) {};
\node [draw] (div) {$\div$};

\draw [outlined arrow][<->,my arrow] (div) -- ++(5em,0);
\draw [outlined arrow][<->,shorten <=2pt,my arrow]
      (div) .. controls +(-90:15mm) and +(180:15mm) .. ++(5em,-5em);

\end{tikzpicture}
\end{document}

I considered also the use of @Qrrbrbirlbel solution (save a path and call it for stroking), but shorten option didn't work. Also @Paul Gaborit solution (surrounded arrow) excludes shorten option (?).