Skip to content

Instantly share code, notes, and snippets.

@isti115
Created September 5, 2018 20:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save isti115/6fa863f732cfef4bd57c986c85305eaf to your computer and use it in GitHub Desktop.
Save isti115/6fa863f732cfef4bd57c986c85305eaf to your computer and use it in GitHub Desktop.
AutoHotKey script mainly for cursor navigation without leaving the area around the home row. It uses the extra key next to "z" on a 102 key keyboard.
#SingleInstance force
;#NoTrayIcon
Menu, Tray, Icon, C:\Users\isti\programming\AutoHotKey\icons\cursor.ico
;#If GetKeyState("CapsLock", "P")
; --- Space
#If GetKeyState("vkE2", "P") && GetKeyState("Space", "P")
; --- Disabling Space
*Space:: return
; --- Standard navigation
i:: Send, {Up 10}
j:: Send, {Left 10}
k:: Send, {Down 10}
l:: Send, {Right 10}
; --- Shift
+i:: Send, +{Up 10}
+j:: Send, +{Left 10}
+k:: Send, +{Down 10}
+l:: Send, +{Right 10}
; --- Alt
!i:: Send, !{Up 10}
!j:: Send, !{Left 10}
!k:: Send, !{Down 10}
!l:: Send, !{Right 10}
; --- vkE2
#If GetKeyState("vkE2", "P") && !GetKeyState("Space", "P")
; --- Disabling vkE2
vkE2:: return
; --- Temp
\:: Send, \[]{Left}
-:: Send, {Right}{}}{Left 2}\_{{}
; --- Extras
q:: Volume_Up
a:: Volume_Down
z:: Volume_Mute
p:: Backspace
s:: ^s
e:: Escape
x:: ^x
c:: ^c
v:: ^v
;e:: Send, {Alt Down}e{Alt Up}la{Alt}
;e:: Send, ^i^i
,:: Send, ^#{Left}
WheelUp:: Send, ^#{Left}
.:: Send, ^#{Right}
WheelDown:: Send, ^#{Right}
vkBF:: Send {LCtrl Down}{LShift}{LCtrl Up}
F3:: Run, nircmdc setdefaultsounddevice "Speakers", , Hide
F4:: Run, nircmdc setdefaultsounddevice "DELL U2515H", , Hide
; --- YouTube speed
`:: Send, <<<<<<
1:: Send, <<<<<<>
2:: Send, <<<<<<>>
3:: Send, <<<<<<>>>
4:: Send, <<<<<<>>>>
5:: Send, <<<<<<>>>>>
6:: Send, <<<<<<>>>>>>
7:: return
; --- Standard navigation
i:: Send, {Up}
j:: Send, {Left}
k:: Send, {Down}
l:: Send, {Right}
h:: Send, ^{Left}
`;:: Send, ^{Right}
;SC027:: Send, ^{Right}
u:: Send, {Home}
o:: Send, {End}
n:: Send, {PgUp}
m:: Send, {PgDn}
; --- Ctrl
^i:: Send, ^{Up}
^j:: Send, ^{Left}
^k:: Send, ^{Down}
^l:: Send, ^{Right}
; --- Shift
+i:: Send, +{Up}
+j:: Send, +{Left}
+k:: Send, +{Down}
+l:: Send, +{Right}
+u:: Send, +{Home}
+o:: Send, +{End}
+h:: Send, ^+{Left}
+`;:: Send, ^+{Right}
; --- Ctrl + Shift
^+i:: Send, ^+{Up}
^+j:: Send, ^+{Left}
^+k:: Send, ^+{Down}
^+l:: Send, ^+{Right}
; --- Alt
!i:: Send, !{Up}
!j:: Send, !{Left}
!k:: Send, !{Down}
!l:: Send, !{Right}
; --- Maintance
^e::
Run, notepad %A_ScriptFullPath%
return
^r::
Reload
return
^x::
ExitApp
return
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment