🐍 Python 3.10+
Disable Sticky Keys Shortcut Prompt (Python)
Stops the Sticky Keys dialog from popping up when Shift is pressed 5 times. Applies the tweak via the stdlib winreg module.
set_disable_sticky_keys_prompt.py
#!/usr/bin/env python3
"""
set_disable_sticky_keys_prompt.py
Disable Sticky Keys Shortcut Prompt.
Stops the Sticky Keys dialog from popping up when Shift is pressed 5 times.
Usage:
python set_disable_sticky_keys_prompt.py
"""
import winreg
def main() -> None:
key = winreg.CreateKeyEx(
winreg.HKEY_CURRENT_USER, r"Control Panel\Accessibility\StickyKeys", 0, winreg.KEY_SET_VALUE
)
winreg.SetValueEx(key, "Flags", 0, winreg.REG_SZ, "506")
winreg.CloseKey(key)
print("Disable Sticky Keys Shortcut Prompt applied.")
if __name__ == "__main__":
main()