Window Activation
Focus Stealing: User Experiences and Pain Points
- Many describe accidentally typing into pop‑ups that grabbed focus mid‑sentence, including passwords ending up in dialogs.
- This happens across systems: on X11/i3, Windows (auto‑updaters; games minimized), and macOS (system or app dialogs appearing while typing).
- Some consider it rare and acceptable; others say it happens daily and is “infuriating,” especially during games or work.
- Several note they’ve written workarounds (window manager patches, extensions, global hotkeys) just to avoid or compensate for focus theft.
Wayland’s Window Activation / Focus Model
- Wayland’s model: apps cannot unilaterally take focus; they can only receive focus via tokens issued by the compositor when triggered by explicit user action (click, shortcut, etc.).
- Example: clicking a link in a chat app → chat app requests a token → passes it with the “open URL” request → browser uses it to gain focus.
- Commenters see this as a principled fix for keystroke‑stealing popups; others find it cumbersome and note incomplete adoption (e.g., password prompts “pop under”).
Comparisons with X11, KDE, GNOME, Windows, macOS
- On X11, whether focus can be stolen is largely up to the window manager; some setups never refocus except on explicit user input, others are vulnerable.
- KDE has configurable “focus stealing prevention” levels; some report no issues there, suggesting the problem is environment‑specific.
- Windows historically added APIs to limit focus stealing, but people disagree on how effective they are today.
- macOS is widely criticized in the thread for dialogs that take focus while typing; Apple’s newer “cooperative app activation” is mentioned but not widely validated.
App Capabilities vs. Restrictions (KiCAD Case Study)
- A large subthread debates apps like KiCAD that want to warp the cursor, control window placement, and manage focus for complex UIs.
- Critics say such apps don’t need OS‑wide control; they should use higher‑level, constrained protocols (pointer constraints, relative placement, modals, throttling controls).
- Others argue removing widely available primitives (e.g., absolute cursor positioning, exact window placement) breaks existing UX and shifts the burden onto app developers.
Philosophy and Trade‑offs
- One side favors “powerful, low‑level APIs” and user choice (copy what Windows does; let market punish abusers).
- The other side prioritizes safety, privacy, and user control via capabilities and permissions, even at the cost of porting pain and lost flexibility.