Fix full-screen logo hiding on notched displays (detect via Spaces API) - #31
Open
jeffscottmtl wants to merge 1 commit into
Open
Fix full-screen logo hiding on notched displays (detect via Spaces API)#31jeffscottmtl wants to merge 1 commit into
jeffscottmtl wants to merge 1 commit into
Conversation
This was referenced May 23, 2026
On notched MacBooks (Sequoia/Tahoe) the logo did not hide when an app entered native full screen, and once hidden could stay stuck until the app was relaunched. The root cause is that the old getFullScreens() tried to recognise full screen by matching window bounds against the screen frame (windowRect.equalTo(screen.frame)), which fails on these machines. Window-bounds matching fundamentally cannot work here. Verified live on macOS 26 with a built-in notched display, a native full-screen window and a merely maximized (green-zoom) window report identical bounds, both rendering below the notch: - maximized Chrome main window: (0, 34, 1710, 1073) - full-screen Chrome main window: (0, 34, 1710, 1073) <- identical and there is no persistent full-screen-sized window to key off. So any geometric rule either misses full screen (logo never hides) or fires on maximized windows (logo hides when it should not). Detect full screen by asking the window server directly instead. The CoreGraphics Spaces API (CGSCopyManagedDisplaySpaces) reports each display's current Space type; a native full-screen Space is type 4. We collect the displays currently in a full-screen Space and map them back to NSScreen frames by display UUID. This is app-agnostic and per-display, and it flips back to normal the instant full screen is exited, so the logo reappears immediately with no stuck state. Verified across repeated enter/exit cycles on the built-in display. This is a private API, consistent with the existing use of the private CGWindowList API; Logoer ships outside the App Store. Apps using *non-native* full screen (e.g. iTerm2's option) do not create a full-screen Space and are intentionally not matched, since they are geometrically indistinguishable from a maximized window. Closes lihaoyun6#29 Closes lihaoyun6#30 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
jeffscottmtl
force-pushed
the
fix/fullscreen-detection
branch
from
June 18, 2026 00:08
347120c to
536378c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
On notched MacBooks (Sequoia/Tahoe) the logo did not hide when an app entered native full screen, and once hidden it could stay stuck until the app was relaunched. This fixes both, for any app, on any display.
Root cause
The old
getFullScreens()recognised full screen by matching window bounds against the screen frame (windowRect.equalTo(screen.frame)). On notched displays that can never be made to work, because a native full-screen window and a merely maximized (green-zoom) window report identical bounds, both rendering below the notch.Verified live on macOS 26 with a built-in notched display:
(0, 34, 1710, 1073)(0, 34, 1710, 1073)There is also no persistent full-screen-sized window to key off (only a 1-frame flicker during the transition). So any geometry-based rule must pick one horn of a dilemma: either miss full screen (logo never hides) or fire on maximized windows (logo hides when it shouldn't, and gets "stuck" because a maximized window is usually present after exiting).
Fix
Ask the window server directly instead of guessing from rectangles. The CoreGraphics Spaces API (
CGSCopyManagedDisplaySpaces) reports each display's current Space type; a native full-screen Space istype == 4. We collect the displays currently in a full-screen Space and map them back toNSScreenframes by display UUID.This is:
Verified across repeated enter/exit cycles on the built-in notched display:
FULLSCREEN -> normal -> FULLSCREEN -> normal, logo hides/reappears correctly each time, and stays visible for maximized windows.Also removes the now-dead
isFullScreenWindow()andgetOwner()helpers.Notes
CGWindowListAPI in this file, and Logoer ships outside the App Store. IfCGSCopyManagedDisplaySpacesever returns nothing on a future OS, the code degrades gracefully (logo simply stays visible).Closes #29
Closes #30