I am asking for a style (or something similar), let us call it ERASE
. The imaginary tool works as a convenient inverse clip or eraser within a scope. The specific way is asked within the comment in the following MWE. The MWE is an abstract form of my use cases (if you do not like the background, think of color wheel graphs from complex analysis to smooth your ruffled feathers).
\documentclass{memoir}
\usepackage{tikz}
\usetikzlibrary{shadings,calc}
\tikzset{nodeStyle/.style={draw,rounded corners,thick,font=\bfseries{}}}
\tikzset{ERASE/.style={}}% just a placeholder
\begin{document}
\begin{tikzpicture}
\shade[shading=color wheel white center] (0,0) rectangle (10,10);
\draw[thick] (0,0) -- (10,5);
\node[nodeStyle,fill=white] at (5,2.5) {filled};
%This is readable but removes the background.
\draw[thick] (0,2) -- (10,7);
\node[nodeStyle] at (5,4.5) {not filled};
\begin{scope}
\draw[line width=1.5ex,color=red!50] (0,6.05) -- (10,6.95);%by @marmot
\draw[thick] (0,4) -- (10,9);
\node[nodeStyle,ERASE] at (5,6.5) {ERASE to be implemented};
% erases everything in this scope "behind" this new object
% such that the diagonal line in this node is not visible and
% the text is easy to read and the coding is convenient
\end{scope}
\begin{scope}
% This just illustrates that clip can be used inside a scope
% thus the desired EREASE instruction might be possible.
\clip (1,7) rectangle (8,10);
\draw[thick] (0,6) -- (8,10);
\end{scope}
\end{tikzpicture}
\end{document}
This imaginary tool might be unsuited for more complex use cases within several paths involved. Any suggestions on improving the use case are welcome.