Hide off-screen scrolling columns and stop boundary focus jumps#320
Open
corpooo wants to merge 2 commits intoacsandmann:mainfrom
Open
Hide off-screen scrolling columns and stop boundary focus jumps#320corpooo wants to merge 2 commits intoacsandmann:mainfrom
corpooo wants to merge 2 commits intoacsandmann:mainfrom
Conversation
macOS does not allow non-privileged apps to reorder other apps' windows (SLSOrderWindow returns CGError 1000 on Tahoe). Instead of fighting macOS Z-order, hide off-screen columns by clamping them just past the screen edge. This eliminates cross-app overlap entirely. Removes the broken SLSOrderWindow-based Z-order enforcement since it cannot work without SIP-disabled Dock injection (like yabai). Inspired by OmniWM's approach of moving non-visible columns off-screen. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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
Why
The scrolling layout can produce windows that are logically part of the strip but fully outside the visible area. When those windows belong to other apps, macOS window ordering becomes unreliable during focus changes and can cause overlap/flicker problems.
This takes the simpler route: if a scrolling column is fully off-screen, place it just beyond the visible edge so it stays hidden without requiring cross-app window reordering.
The follow-up boundary guard keeps
focus-left/focus-rightfrom jumping to an adjacent display when scrolling layout is already at the first or last visible column. With off-screen columns hidden, that jump can otherwise select a hidden window and desynchronize focus.Verification
cargo build --profile release-fast --bin riftcargo test scrolling -- --nocapture