bool isFrontWidget(double angle) { const degrees90 = pi / 2; const degrees270 = 3 * pi / 2; return angle <= degrees90 || angle >= degrees270; }