.claude/skills/verify-miri/features/new-window-width.md
New window width
A window that opens while Miri runs joins the strip on the active display as a new column. It keeps the width it opens with, but never more than that display's tiling area, so focusing it shows the whole window (#410). A window that the user widens past the display afterwards keeps that width and pans.
Sub-features
wider-than-display: a window that opens wider than the tiling area, as an app that remembers its size from a larger display does, gets the tiling area's width.background-open: a window that opens on another display without taking focus, as after an updater relaunch, joins the active display's strip and gets that display's limit.
How to get to it (user POV)
- An app opens a new window, or relaunches and restores its window, while Miri runs.
Driving it with verify-miri
Preconditions:
The baseline from the index.
Two displays, the active one narrower than the width you pass. Read each display's ID and point size with
NSScreen.screens, and the active display withV query active.Focus the narrower display. Press
ctrl+alt+cmd-downarrowor the Focus display chord toward it, and checkV query activeshows itsdisplay_id.Open a wide window in the background. Run
V fixture --width 2560 --display <wider display ID> --background, thenV snapshot after-open. The fixture'sdisplay_idis the active display, and itsframe.widthis at most that display's tiling width: its point width minus the left and right[padding]inconfig.toml.Focus it. Press
ctrl+alt-rightarrowuntilV focused --wait-for fixture-1passes, thenV snapshot focused. The fixture's macOS frame lies inside the display: read it withCGWindowListCopyWindowInfofor the fixture's window ID.Open a wide window with focus. Run
V fixture --width 2560 --display <display ID>. Its column is at most that display's tiling width.
Gotchas
- AppKit limits a window that opens on a display to that display's width, so
--display <narrow display>alone gives a column only the padding too wide. Open on the wider display with--backgroundto get the full overflow from #410. - The engine's frame includes the per-window padding, so it is 8 points wider than the macOS frame with Miri's 4-point padding.