Hotkeyz, AutoHotKey를 이용하여 편하게 프로그램 호출하기

잘 사용하지 않지만 키보드에서 많은 부분을 차지하는 Caps Lock키를 이용하는 자주 사용하는 단축키로 사용할 수 있습니다.

 

A. 작업 순서

1. Autohotkey로 Caps Lock를 CTRL+Shift키로 Mapping

2. (프로그램의 특정 기능을 호출할 때) 프로그램내의 단축키를 CTRL+Shift+xxx 로 설정

3. (프로그램을 실행할 때) Hotkeyz로 단축키 설정

 


B. 설치 프로그램(준비물) : 1~4까지 모두 설치

1. AutoHotKey(이하 AHK) : www.autohotkey.com/

 

AutoHotkey

AutoHotkey provides a simple, flexible syntax allowing you to focus more on the task at hand rather than every single little technicality. It supports not only the popular imperative-procedural paradigm, but also object-oriented and command-based programmi

www.autohotkey.com

2. Hotkeyz : hotkeyz.kr.uptodown.com/windows

 

Hotkeyz (Windows)

Windows을 위한 Hotkeyz 최신 버전을 다운로드하세요.. 한 번의 클릭으로 실행할 프로그램의 단축키를 만드세요. HotKeyz는 키 조합으로, 폴더나 응용 프로그램에 빠르게 접근하여 실행할 수 있도록 도

hotkeyz.kr.uptodown.com

3. 특정기능 구현을 위한 예제 프로그램

ShareX(캡쳐 프로그램) getsharex.com/

 

ShareX - The best free and open source screenshot tool for Windows

ShareX is a free and open source program that lets you capture or record any area of your screen and share it with a single press of a key. It also allows uploading images, text or other types of files to many supported destinations you can choose from.

getsharex.com

2022.08.22 - [업무/Utility] - (추천) 캡쳐 프로그램 - ShareX

 

(추천) 캡쳐 프로그램 - ShareX

저는 업무 상 3D 모델링을 많이 하기 때문에, 관련 자료를 제작할 때 스크린 캡쳐도 많이 하는 편입니다. 예전에는 윈도우10/11에 기본으로 포함된 캡쳐 프로그램을 사용하였지만, 반복 캡쳐, 동영

newace77.tistory.com

4. 프로그램 실행을 위한 예제 프로그램

Everything(파일 검색 프로그램) www.voidtools.com/ko-kr/downloads/

 

다운로드 - voidtools

 

www.voidtools.com


C. Step By Step

1. AHK설정

  • 위에 언급한 바와 같이 Caps Lock키를 CTRL+Shift 키로 Mapping
  • AHK는 Script를 컴파일하여 실행하면 각 Script가 별도의 프로세스로 동작한다.
  • Script 작성하기가 어렵지 않을까 했지만, 많은 사람들이 이미 많이 사용하고 있는터라 인터넷에 조금만 찾아보면 원하는 것을 찾을 수 있다.
  • 나도 Script를 공부할 생각은 없고 구글링으로 원하는 정보를 획득

    국내 커뮤니티 : www.autohotkey.co.kr/

이미지
구글신에게 부탁..

참고로 제가 쓰는 코드는 다음과 같습니다. 

#NoEnv ; recommended for performance and compatibility with future autohotkey releases.
#UseHook
#InstallKeybdHook
#SingleInstance force
SendMode Input
;; deactivate capslock completely
SetCapslockState, AlwaysOff
;; remap capslock to hyper
;; if capslock is toggled, remap it to esc
;; note: must use tidle prefix to fire hotkey once it is pressed
;; not until the hotkey is released
~Capslock::
    ;; must use downtemp to emulate hyper key, you cannot use down in this case 
    ;; according to https://autohotkey.com/docs/commands/Send.htm, downtemp is as same as down except for ctrl/alt/shift/win keys
    ;; in those cases, downtemp tells subsequent sends that the key is not permanently down, and may be 
    ;; released whenever a keystroke calls for it.
    ;; for example, Send {Ctrl Downtemp} followed later by Send {Left} would produce a normal {Left}
    ;; keystroke, not a Ctrl{Left} keystroke
    Send {Ctrl DownTemp}{Shift DownTemp}
    KeyWait, Capslock
    Send {Ctrl Up}{Shift Up}
    if (A_PriorKey = "Capslock") {
        Send {Esc}
    }
return

2. HOTKEYZ 설정

  • Hotkeyz의 모든 설정은 AHK로 대치 가능하다.
  • 하지만, 설정을 변경함에 있어 HOTKEYZ가 비교할 수 없을 정도로 용이하기 때문에, 가능한 HOTKEYZ로 설정
  • (예제) Everything 실행 단축키 설정 (Caps Lock + E)

 

이미지
이미지

3. ShareX설정

  • 제가 주로 많이 사용하고 있는 기능은 "사각형 캡쳐"와 "이전 캡쳐 영역 재캡쳐"입니다.
  • "사각형 캡쳐"Shift+Ctrl+C로 단축기 지정 (실제로는 Caps Lock + C 로 작동)
  • "이전 캡쳐 영역 재캡쳐"Shift+Ctrl+C로 단축기 지정 (실제로는 Caps Lock + D 로 작동)

이미지

 

Hotkeyz나 각 S/W의 단축키들을 활용한다면 PC의 거의 모든 기능을 단축키로 사용할 수 있습니다.