Skip to content

Instantly share code, notes, and snippets.

@gMagicScott
Created April 24, 2020 20:31
Show Gist options
  • Save gMagicScott/bec87003143bf8553999f531f479706f to your computer and use it in GitHub Desktop.
Save gMagicScott/bec87003143bf8553999f531f479706f to your computer and use it in GitHub Desktop.
Using AutoHotKey, remap Caps Lock to be <Esc> when tapped (under 400ms), acts as <Ctrl> when used in combo shortcuts
*CapsLock::
Send {Blind}{Ctrl Down}
cDown := A_TickCount
Return
*CapsLock up::
If ((A_TickCount-cDown)<400) ; Modify press time as needed (milliseconds)
Send {Blind}{Ctrl Up}{Esc}
Else
Send {Blind}{Ctrl Up}
Return
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment