You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When a new window is created that extends past the screens edge, resizing to a rectangle will be truncated. For example, if a window is created and hangs n pixels below the screen, it appears that the resulting window after calling moveToUnit is n pixels shorter than desired.
You can find a minimal example here, in which we subscribe to windowCreated events and resize the window in the callback function.
See the included video demonstrating the behavior:
Screen.Recording.2024-04-06.at.10.45.51.PM.mov
As an aside, I've noticed that I sometimes have to call the move method multiple times before the window is in the location and dimension that I desire. This Reddit user has described similar behavior:
System
Hammerspoon: 0.9.93
macOS Sonoma: 14.3
Problem
When a new window is created that extends past the screens edge, resizing to a rectangle will be truncated. For example, if a window is created and hangs
n
pixels below the screen, it appears that the resulting window after callingmoveToUnit
isn
pixels shorter than desired.You can find a minimal example here, in which we subscribe to
windowCreated
events and resize the window in the callback function.This seems to primarily happen with Firefox.
See the included video demonstrating the behavior:
Screen.Recording.2024-04-06.at.10.45.51.PM.mov
As an aside, I've noticed that I sometimes have to call the
move
method multiple times before the window is in the location and dimension that I desire. This Reddit user has described similar behavior:https://www.reddit.com/r/hammerspoon/comments/xz3xvy/window_manipulation_functions_misbehaving/
The text was updated successfully, but these errors were encountered: