AHKCommandPicker icon indicating copy to clipboard operation
AHKCommandPicker copied to clipboard

How to modify the trigger shortcut key

Open PiscesDreamer opened this issue 2 years ago • 1 comments

Hello author! I am learning ahk, so I am not very familiar with ahk code. I want to modify the trigger shortcut keys. How should I modify the source code?

PiscesDreamer avatar Jan 11 '24 02:01 PiscesDreamer

Hey @PiscesDreamer , if you want to use a key other than CapsLock to trigger the UI, you'll want to change this line in the AHKCommandPicker.ahk file. Rather than specifying CapsLock, specify the key or key combination you want to have launch the picker. You can also remove the line to set CapsLock to off as well.

For example, to have Windows+Z launch the picker instead of CapsLock, change:

CapsLock::
	SetCapslockState, Off				; Turn CapsLock off after it was pressed
	CPLaunchCommandPicker()
return

to

#z::
	CPLaunchCommandPicker()
return

Let me know if that does the trick for you. I hope that helps, and that you enjoy the tool 😄

deadlydog avatar Jan 11 '24 05:01 deadlydog