Describe the bug
The QToggleSwitch class won't update the GUI if used under a QSignalBlocker.
This is happening because the animation is handled as an event connection in:
class QToggleSwitch(QtW.QAbstractButton):
....
def __init__( # type: ignore [misc] # overload
self, text: str | None = None, parent: QtW.QWidget | None = None
) -> None:
....
self.toggled.connect(self._animate_handle)
To Reproduce
Steps to reproduce the behavior:
- Create a QToggleSwitch.
- Update the state inside a QSignalBlocker.
- The button will glitch, properly changing the color but not the GUI handle.
Expected behavior
If the button state is updated inside a QSignalBlocker, the GUI should be updated alongside the state.
Screenshots
Button state Checked = True but GUI handle OFF (WRONG state)

Button state Checked = False but GUI handle ON (WRONG state)

Button state Checked = False GUI handle OFF (This is CORRECT)

Desktop:
- Windows 11 (26200.8328)
- PyQt6 (6.10.2)
- Python 3.13
Describe the bug
The QToggleSwitch class won't update the GUI if used under a QSignalBlocker.
This is happening because the animation is handled as an event connection in:
To Reproduce
Steps to reproduce the behavior:
Expected behavior
If the button state is updated inside a QSignalBlocker, the GUI should be updated alongside the state.
Screenshots

Button state
Checked = Truebut GUI handleOFF(WRONG state)Button state

Checked = Falsebut GUI handleON(WRONG state)Button state

Checked = FalseGUI handleOFF(This is CORRECT)Desktop: