Created
December 11, 2022 15:27
-
-
Save alef/7060b898bce6fb5f2936c7c5e927533e to your computer and use it in GitHub Desktop.
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
#SingleInstance Force | |
Persistent True | |
WindowedFullScreen(Monitor) { | |
; In-game settings: | |
; /Video\ | |
; [ Windowed ] | |
; [ Resolution: Detect ] | |
; [ Window is resizable (takes effect on restart) Yes ] | |
Title := "Dwarf Fortress" | |
StrStyle := "-0xC00000" | |
SetTitleMatchMode 3 | |
if ! WinWait(Title, , 2) | |
return | |
MonitorGetWorkArea(Monitor, &Left, &Top, &Right, &Bottom) | |
Width := Right - Left | |
Height := Bottom - Top | |
WinSetStyle StrStyle | |
WinMove Left, Top, Width, Height | |
} | |
tray := A_TrayMenu | |
tray.Add("") | |
loop MonitorGetCount() { | |
Name := (MonitorGetPrimary() == A_Index ? "P" : Chr(Ord("A") + A_Index - 1)) | |
MonitorGetWorkArea(A_Index, &Left, &Top, &Right, &Bottom) | |
Title := Name " " Format("{1:d}:{2:d}", Left, Top) | |
tray.Add(Title, ((i, *) => WindowedFullScreen(i)).Bind(A_Index)) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment