Skip to content

Instantly share code, notes, and snippets.

@eduardomartines
Last active April 11, 2023 00:41
Show Gist options
  • Save eduardomartines/371b790d1c102bccca6db9a25ad2b464 to your computer and use it in GitHub Desktop.
Save eduardomartines/371b790d1c102bccca6db9a25ad2b464 to your computer and use it in GitHub Desktop.
Motospeed CK62 - Autohotkey Script
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
SetCapsLockState, AlwaysOff
CapsLock & ,:: Send {Del}
CapsLock & .:: Send {End}
CapsLock & k:: Send {Ins}
CapsLock & l:: Send {Home}
CapsLock & `;:: Send {PgUp}
CapsLock & ':: Send {PgDn}
CapsLock & [:: Send {PrintScreen}
CapsLock & ]::Send {Pause}
; Functions
CapsLock & 1::Send {F1}
CapsLock & 2::Send {F2}
CapsLock & 3::Send {F3}
CapsLock & 4::Send {F4}
CapsLock & 5::Send {F5}
CapsLock & 6::Send {F6}
CapsLock & 7::Send {F7}
CapsLock & 8::Send {F8}
CapsLock & 9::Send {F9}
CapsLock & 0::Send {F10}
CapsLock & -::Send {F11}
CapsLock & =::Send {F12}
CapsLock & Backspace::Delete
CapsLock & Escape::
If GetKeyState("Shift")
Send {~}
Else
Send {``}
Return
; Arrow Up
Capslock & /::
If GetKeyState("Shift")
Send +{Up}
Else
Send {Up}
Return
; Arrow Left
Capslock & RAlt::
If GetKeyState("Shift") && GetKeyState("LWin")
Send +{Home}
Else
If GetKeyState("Shift") && GetKeyState("Control")
Send +^{Left}
Else
If GetKeyState("Shift")
Send +{Left}
Else
If GetKeyState("LWin")
Send {Home}
Else
If GetKeyState("Control")
Send ^{Left}
Else
Send {Left}
Return
; Arrow Down
Capslock & AppsKey::
If GetKeyState("Shift")
Send +{Down}
Else
Send {Down}
Return
; Arrow Right
Capslock & RControl::
If GetKeyState("Shift") && GetKeyState("LWin")
Send +{End}
Else
If GetKeyState("Shift") && GetKeyState("Control")
Send +^{Right}
Else
If GetKeyState("Shift")
Send +{Right}
Else
If GetKeyState("LWin")
Send {End}
Else
If GetKeyState("Control")
Send ^{Right}
Else
Send {Right}
Return
; Arrows Alternative
CapsLock & w::Send {up}
CapsLock & a::Send {left}
CapsLock & s::Send {down}
CapsLock & d::Send {right}
; Volume
CapsLock & c::Send {Volume_Up}
CapsLock & x::Send {Volume_Down}
CapsLock & z::Send {Volume_Mute}
@omaralwadie
Copy link

i want to add numpad function how ?

@gpapachr
Copy link

gpapachr commented Jun 4, 2021

Any solution for linux based systems?

@Yaroster
Copy link

Yaroster commented Jun 5, 2021 via email

@OMAR-3OOV
Copy link

If you want to lock the CapsLock just press Shift + CapsLock

Shift + Capslock can unlock it but how to lock it again ?

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