The following code works but it looks wrong at the ends.
Code: Select all
[
interface/.style={
postaction={
draw,
decorate,
decoration={
border,
angle=45,
amplitude=0.3cm,
segment length=3mm
}
}
},
]
Code: Select all
\tikzset{mystripes dist/.initial=0.2}
\pgfdeclarepatternformonly[/tikz/mystripes dist]{mystripes}
{\pgfpointorigin}{\pgfpoint{1cm}{1cm}}
{\pgfpoint{1cm}{1cm}}
{
\foreach \x in {0,\pgfkeysvalueof{/tikz/mystripes dist},...,1}{
\pgfmathsetmacro{\nx}{1-\x}
\tikz[overlay]\draw[decoration = {random steps, segment length = 0.2mm, amplitude = 0.15pt}, decorate] (\x, 0) -- ++(\nx,\nx);
\tikz[overlay]\draw[decoration = {random steps, segment length = 0.2mm, amplitude = 0.15pt}, decorate] (0, \x) -- ++(\nx,\nx);
}
}