This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
titleSearch := "My Window" | |
matchCount := WinGetCount titleSearch | |
OutputDebug "Window count: " matchCount "`n" | |
hwnd := WinGetID titleSearch | |
OutputDebug "Window Handle: " hwnd "`n" | |
windowTitle := WinGetTitle hwnd | |
OutputDebug "Window Title: " windowTitle "`n" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Warn All, StdOut | |
#SingleInstance Prompt | |
SetTitleMatchMode "RegEx" | |
ProcessSetPriority "High" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Warn All, StdOut | |
#SingleInstance Prompt | |
ProcessSetPriority "High" | |
; From https://www.maketecheasier.com/turn-off-monitor-automatically-lock-windows/ | |
#l:: { | |
Sleep 200 | |
DllCall "LockWorkStation" | |
Sleep 1000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; From https://gist.github.com/Jaid/407c0f2b01aace1125ea34915ce1f6bb | |
full_command_line := DllCall("GetCommandLine", "str") | |
if not (A_IsAdmin or RegExMatch(full_command_line, " /restart(?!\S)")) { | |
try { | |
if A_IsCompiled { | |
Run '*RunAs "' A_ScriptFullPath '" /restart' | |
} else { | |
Run '*RunAs "' A_AhkPath '" /restart "' A_ScriptFullPath '"' | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# From https://superuser.com/a/758464/1288709 | |
xrandr --newmode "1920x1080" 173.00 1920 2048 2248 2576 1080 1083 1088 1120 -hsync +vsync | |
xrandr --addmode Virtual1 1920x1080 | |
xrandr --output Virtual1 --mode 1920x1080 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Warn All, StdOut | |
#SingleInstance Prompt | |
#Include ../lib/jaid.ahk2 | |
main() { | |
; TODO: Write business logic | |
} | |
; TODO: Change key | |
#e:: { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Stopwatch { | |
time := false | |
__New() { | |
this.start() | |
} | |
start() { | |
this.time := A_TickCount | |
} | |
end() { | |
return A_TickCount - this.time |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* { | |
background: red !important; | |
color: red !important; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Windows Registry Editor Version 5.00 | |
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced] | |
"ShowSecondsInSystemClock"=dword:1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Windows Registry Editor Version 5.00 | |
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced] | |
"DisallowShaking"=dword:1 |