No worry. It is a different expression for the same final result.
I have programmed your "weird function" defined by :
$$W(t)=\underbrace{(2H(t)-1)}_{sign(t)}.H(-a-t.H(-t))H(a+\underbrace{t.H(t)}_{ramp}) \tag{1}$$
(Matlab code below)
It gives the same result as $H(t+a)-H(a)$ in the two different cases $a>0$ and $a \le 0$.
It is not the first time that I see equivalent expressions written very differently using Heaviside function.
A known example is the "characteristic function" of interval $[a,b]$ (value $1$ for $a<t<b$, $0$ elsewhere) which can be written using $H$ function in (at least) two ways :
$$\underbrace{H(t-a)-H(t-b)}_{additive \ way}=\underbrace{H(t-a)H(b-t)}_{multiplicative \ way}$$
Please note that the first factor in (1) is the sign function and that $t*H(t)$ defines the "ramp function" which is a primitive function of $H$.
t=-5:0.01:5;
H=@(x)((sign(x)+1)/2); % Heaviside
a=-2; %
W=(2*H(t)-1).*H(-a-t.*H(-t)).*H(a+t.*H(t));
plot(t,W)