Advertisement
Javi

AHK

Oct 12th, 2017
184
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.16 KB | None | 0 0
  1. #NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
  2. #Warn ; Enable warnings to assist with detecting common errors.
  3. #InstallKeybdHook
  4. #UseHook On
  5. #SingleInstance force
  6. SetKeyDelay, 10, 10
  7. SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
  8. SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
  9.  
  10. !c::Send,^{Ins}
  11. !v::Send,+{Ins}
  12.  
  13. F1::
  14. run, snippingtool.exe,,, process_id
  15. WinWait, ahk_pid %process_id%
  16. WinActivate, ahk_pid %process_id%
  17.  
  18. º::Send,*
  19. !º::Send,\
  20. !7::Send,\
  21. !u::Send,[
  22. !i::Send,]
  23. !n::Send,{{}
  24. !m::Send,{}}
  25. !1::Send,|
  26. !2::Send,@
  27. !3::Send,{#}
  28.  
  29. +wheelup::send, {LWin Down}{+}{LWin Up}
  30. +wheeldown::send, {LWin Down}{-}{LWin Up}
  31.  
  32. Send !n
  33.  
  34. F24::
  35. FileRead, key, luamacros\keypressed.txt
  36. If (key = 52)
  37. Send,*
  38. else if(key = "p")
  39. return
  40.  
  41.  
  42. +F1::controlSend,,{F13},ahk_class Qt5QWindowIcon
  43. +F2::controlSend,,{F14},ahk_class Qt5QWindowIcon
  44. +F3::controlSend,,{F15},ahk_class Qt5QWindowIcon
  45. +F4::controlSend,,{F16},ahk_class Qt5QWindowIcon
  46. +F5::controlSend,,{F17},ahk_class Qt5QWindowIcon
  47. +F6::controlSend,,{F18},ahk_class Qt5QWindowIcon
  48. +F7::controlSend,,{F19},ahk_class Qt5QWindowIcon
  49. +F8::controlSend,,{F20},ahk_class Qt5QWindowIcon
  50. +F9::controlSend,,{F21},ahk_class Qt5QWindowIcon
  51. +F10::controlSend,,{F22},ahk_class Qt5QWindowIcon
  52.  
  53. ; Center window on 4K monitor
  54. #c::
  55. WinExist("A")
  56. WinGetPos,,, sizeX, sizeY
  57. WinMove,,,(A_ScreenWidth/2)-(sizeX/2), 0, (A_ScreenWidth/2.5), A_ScreenHeight-50
  58. return
  59.  
  60. #If GetKeyState("CapsLock", "T")=1
  61.  
  62. h::Send,{Left}
  63. ^h::Send ^{Left}
  64. +h::Send {Home}
  65. ^+h::Send +{Home}
  66. l::Send,{Right}
  67. ^l::Send ^{Right}
  68. +l::Send {End}
  69. ^+l::Send +{End}
  70. k::Send,{Up}
  71. ^k::Send,{PgUp}
  72. j::Send,{Down}
  73. ^j::Send,{PgDn}
  74. x::Send,{Del}
  75. ^x::Send,^{Del}
  76. +4::Send,{Ctrl}{Home}
  77. 0::Send,{Ctrl}{End}
  78. <::AppsKey
  79. 1::Run, node msi-keyboard-CLI.js -c red -i light, C:\Progra~1\nodejs\node_modules\msi-keyboard-cli, "Hide"
  80. 2::Run, node msi-keyboard-CLI.js -c white -i light, C:\Progra~1\nodejs\node_modules\msi-keyboard-cli, "Hide"
  81. 3::Run, node msi-keyboard-CLI.js -k off, C:\Progra~1\nodejs\node_modules\msi-keyboard-cli, "Hide"
  82. #If
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement