- Here's some code. Cheers.
Code: Select all
q::
WS_MINIMIZEBOX := 0x20000
WinGet, hWnd, ID, A
WinSet Style, % -WS_MINIMIZEBOX, % "ahk_id " hWnd
return
w::
WS_MINIMIZEBOX := 0x20000
WinGet, hWnd, ID, A
WinSet Style, % "+" WS_MINIMIZEBOX, % "ahk_id " hWnd
return
;e:: ;not recommended (this removes almost all of the window styles, making the window unusable)
WS_MINIMIZEBOX := 0x20000
WinGet, hWnd, ID, A
WinSet Style, % WS_MINIMIZEBOX, % "ahk_id " hWnd
return
;r:: ;set windows to have the same style as this one
;(i.e. fix windows you messed up above)
WinGet, vWinStyle, Style, A
DetectHiddenWindows, On
WinGet, vWinList, List, ahk_class Notepad
Loop, % vWinList
{
hWnd := vWinList%A_Index%
WinSet, Style, % vWinStyle, % "ahk_id " hWnd
}
MsgBox, % "done"
return
- @swagfag, I would have thought that this wouldn't work: "0x00020000L", because of the 'L'.