Skip to content

Instantly share code, notes, and snippets.

@ngollan
Last active May 18, 2026 14:23
Show Gist options
  • Select an option

  • Save ngollan/521388fc8ee5f92b917741726a708252 to your computer and use it in GitHub Desktop.

Select an option

Save ngollan/521388fc8ee5f92b917741726a708252 to your computer and use it in GitHub Desktop.
Swapcapses
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:\
00,00,00,00,\
00,00,00,00,\
03,00,00,00,\
3a,00,1d,00,\
1d,00,3a,00,\
00,00,00,00
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:\
00,00,00,00,\
00,00,00,00,\
03,00,00,00,\
1d,e0,1d,00,\
1d,00,3a,00,\
00,00,00,00
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:\
00,00,00,00,\
00,00,00,00,\
02,00,00,00,\
1d,00,3a,00,\
00,00,00,00
@ngollan

ngollan commented May 18, 2026

Copy link
Copy Markdown
Author

Scancodes are taken from really old Windows documentation. The basic idea can be found in many places including (https://github.com/Keith-S-Thompson/no-caps-lock).

swap-caps-control.reg

Swap CAPSLOCK (0x3a) and LEFT CONTROL (0x1d).

swap-caps-only_control.reg

Makes CAPSLOCK a copy of LEFT CONTROL.

swap-caps-control_rcontrol.reg

Makes CAPSLOCK into LEFT CONTROL and LEFT CONTROL becomes a copy of RIGHT CONTROL (0xe01d).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment