Page 1 of 1

InstallEventHandler(SizeWindow={}) action to include X and Y

Posted: Fri Feb 21, 2025 11:20 am
by Bugala
When using:

Code: Select all

Local ID = CreateDisplay(Nil, {X=100, Y=100, Width=500, Height=300, Sizeable=True, Mode="windowed"})
OpenDisplay(ID)

InstallEventHandler({SizeWindow = Function(Action)
							ForEach(Action, DebugPrint)
									EndFunction})
Repeat
	WaitEvent()
Forever
You can see there is Width and Height, but there is no X and Y.

This isn't a big problem, since I can use GetAttribute() command to get the X and Y position, but main point here is consistency.

Thing is, at least in Windows you can also resize Hollywood windows by either choosing the left side of the window, or top side of the window, to be the dragging point, which means that not only will the Width and Height change, but also X and Y position. Currently "Action" doesn't recognise this possibility, but I need to make a separate GetAttribute() inquiry to get the new X and Y positions.

Re: InstallEventHandler(SizeWindow={}) action to include X and Y

Posted: Tue Feb 25, 2025 10:37 pm
by airsoftsoftwair
Yes, might make sense to add this. I'll check.

Re: InstallEventHandler(SizeWindow={}) action to include X and Y

Posted: Sun May 11, 2025 7:22 pm
by airsoftsoftwair

Code: Select all

- New: The SizeWindow event message now contains additional X/Y fields that contain the window's position
  because that could also have changed in the course of window resizing