Page 1 of 1

How do I lock the window size?

Posted: 09 Apr 2022 10:06
by hanshuchen
How do I lock the window size?Disable window resizing。

Re: How do I lock the window size?

Posted: 09 Apr 2022 10:24
by highend
You can't but you are free to use a custom event action (that fires often) to automatically correct it

viewtopic.php?p=120828#p120828

Apart from that: AutoHotkey and script it...

Re: How do I lock the window size?

Posted: 09 Apr 2022 10:30
by hanshuchen
highend wrote: ↑09 Apr 2022 10:24 You can't but you are free to use a custom event action (that fires often) to automatically correct it

viewtopic.php?p=120828#p120828

Apart from that: AutoHotkey and script it...
ok..

Re: How do I lock the window size?

Posted: 09 Apr 2022 10:41
by highend

Code: Select all

#NoTrayIcon

hWnd := A_Args[1]

if (hWnd)
    WinSet, Style, ^0x40000, % "ahk_id" hWnd
Compile that and then you could switch window resizing on / off by calling the .exe (adapt the path^^) with

Code: Select all

run lax("D:\Tools\XYplorer\@Scripts\Toggle window resizing.exe" <hwnd>);

Re: How do I lock the window size?

Posted: 09 Apr 2022 10:48
by hanshuchen
highend wrote: ↑09 Apr 2022 10:41

Code: Select all

#NoTrayIcon

hWnd := A_Args[1]

if (hWnd)
    WinSet, Style, ^0x40000, % "ahk_id" hWnd
Compile that and then you could switch window resizing on / off by calling the .exe (adapt the path^^) with

Code: Select all

run lax("D:\Tools\XYplorer\@Scripts\Toggle window resizing.exe" <hwnd>);
thank you