Skip to content

Replace the terminal screensaver with the native Wayland one - #16800

Merged
omarchybot merged 9 commits into
quattrofrom
omabot/native-screensaver
Oct 28, 2026
Merged

omarchybot merged 9 commits into
quattrofrom
omabot/native-screensaver

Conversation

@omarchybot

@omarchybot omarchybot commented Oct 27, 2026 •

Copy link
Copy Markdown
Collaborator

The screensaver ran in a terminal, one per monitor, and only a keypress inside it, or losing focus, closed it. Moving the mouse, clicking or scrolling did nothing (#7762), and it carried a stack of terminal workarounds: a focus walk across displays to place each window, window rules to keep it fullscreen, and an idle service tracking its windows so that mouse movement would not cancel the lock while it stayed on screen. Closes #7762.

This replaces it with tobi's native Wayland screensaver, shipped as the omarchy-screensaver package from omacom/omarchy-screensaver. It draws one overlay on every display, renders ttfx in process, and any key, click, scroll or mouse movement dismisses it. omarchy-launch-screensaver hands off to the binary, which already handles the single-instance check, the screensaver-off toggle, the locked-session guard, the branding file and hiding the cursor. The package joins the base list, with a migration to install it.

There is no terminal fallback: the package is in the base set and the migration installs it, so a second implementation would only be kept for machines that never run it. The terminal loop, its per-terminal configs, its Hyprland window rules, its tests and its i18n message go. omarchy-system-lock stops the native screensaver, gives it a second to fade and restore the cursor, kills it only if it is still running, and restores the cursor itself whenever it had to stop one. omarchy-debug-idle reports the screensaver's layer instead of a window.

The idle service no longer tracks screensaver windows; the overlay is a layer surface, not a window, and the input that wakes the idle monitor is the input that dismisses it. Activity after the three-second launch grace ends the cycle as before. The service stops the screensaver itself whenever the user is back, because some input never reaches the overlay: a bound media key, a touchscreen, a second seat. A screensaver that exits while the user is active cancels the cycle as a dismissal, so dismissing it inside the launch grace does not still lock.

On an Omarchy ISO worker with this branch as the running shell and the package's binary installed:

  • Mouse movement, a click, a scroll and a key each dismissed the screensaver launched from the menu, and the cursor came back.
  • An idle-launched screensaver dismissed by the mouse cancelled the pending lock.
  • One left alone locked on time, and the lock stopped it cleanly.
  • A volume key, which the overlay never sees, now closes it and cancels the lock, including inside the launch grace.
  • Dismissing it inside the grace with a lock deadline two seconds after launch did not lock.
  • A volume key inside the grace, with a lock deadline two seconds after launch, did not lock. An untouched cycle with the same deadline still locked on time.

Each of those behaviours was also run with its fix removed and failed. The shell suite's remaining failures (ascii, about-animation, first-run, lock-appear budget, runtime-smoke) fail identically on 84d4435.

Package: omarchy-screensaver is published to edge for x86_64 and aarch64 (omacom/omarchy-pkgs#1710). On a fresh worker on edge, this branch's migration installed it from the repository and was a no-op when run again. omacom/omarchy-pkgs#1715 moves it to 1.2.0, which drops --frame-rate; this branch works with either version. The package publishes on the default ring, so it has to be promoted to rc and stable before an Omarchy release carrying this reaches them.

This revives #7193 by @tobi on today's quattro, and makes #16790, #16549 and the other terminal-dismissal approaches (#16519, #7528, #12975, #11746, #16235) unnecessary.

Reviewed by Claude Opus 5.5, with Codex Medium and muse-spark-1.3-contributor High as second opinions.

omarchybot and others added 6 commits October 27, 2026 14:39
The screensaver ran in a terminal: one per monitor, opened by walking focus across the displays, and closed only by a keypress or by losing focus, so moving the mouse or scrolling over it did nothing. The omarchy-screensaver package now draws it as a native Wayland overlay on every display, rendering ttfx in process, and any key, click, scroll or mouse movement dismisses it.

omarchy-launch-screensaver hands off to that binary, which keeps the single-instance check, the screensaver-off toggle, the locked-session guard and the branding file. OMARCHY_SCREENSAVER_FRAME_RATE passes a lower --frame-rate for virtual GPUs that stall at 120 fps (#8554). The package joins the base list, with a migration to install it.

The terminal implementation goes with it: its loop, its per-terminal configs, its window rules and its launcher test. omarchy-system-lock now stops the native screensaver, gives it a second to fade and restore the cursor, and restores the cursor itself if it had to kill it. omarchy-debug-idle reports the screensaver's layer instead of its window.

Co-Authored-By: Tobi Lutke <tobi@shopify.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The idle service tracked screensaver windows so that activity while one was up would not cancel the pending lock: the terminal screensaver ignored the mouse, so moving it left the screensaver on screen with no lock coming. The native screensaver is a layer surface rather than a window, and the input that wakes the idle monitor is the same input that dismisses it, so activity after the launch grace cancels the cycle and nothing is left to track. This removes the window set, the raw Hyprland event handler and the two model helpers that served it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Activity after the launch grace cancelled the idle cycle on the assumption that the same input had dismissed the screensaver. Input it never sees -- a bound media key, a touchscreen, a second seat -- cancelled the lock and left the overlay up, so the service now stops the screensaver itself when activity ends a cycle that launched one. Activity inside the grace was ignored outright, so dismissing the screensaver just before a lock deadline that fell inside it still locked; a screensaver that exits while the user is active now cancels the cycle as a dismissal.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Codex Medium <noreply@openai.com>
Co-Authored-By: muse-spark-1.3-contributor High <noreply@meta.com>
The cursor was restored only after a SIGKILL, but a screensaver that dies on SIGTERM before its handlers are installed, or whose own restore fails, leaves it hidden too. System lock now restores it whenever it found a screensaver to stop, and kills one only if it is still running after its second.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Codex Medium <noreply@openai.com>
Co-Authored-By: muse-spark-1.3-contributor High <noreply@meta.com>
The terminal-only message lost its last caller with the terminal launcher, and the screensaver command group lost its only command.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Codex Medium <noreply@openai.com>
Co-Authored-By: muse-spark-1.3-contributor High <noreply@meta.com>
Input inside the three-second launch grace is ignored, and when the grace ended with the user active the cycle was cancelled without stopping the screensaver, so a media key pressed just after it appeared left the overlay up. The grace now ends through the same path as any other activity.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Codex Medium <noreply@openai.com>
@greptile-apps

greptile-apps Bot commented Oct 27, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The PR appears safe to merge within this follow-up review’s scope.

Summary

Replaces terminal-based screensavers with the native Wayland omarchy-screensaver package.

  • The screensaver runs as a native overlay across every display.
  • Idle input cancels the pending lock when the screensaver closes.
  • The lock command gives the native screensaver time to exit.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[User becomes idle] --> B[Launch native screensaver]
  B --> C{User returns?}
  C -->|Yes| D[Stop screensaver and cancel pending lock]
  C -->|No| E[Lock deadline]
  E --> F{User returned during launch grace?}
  F -->|Yes| D
  F -->|No| G[Lock session and stop screensaver]
Loading

Reviews (4) · Last reviewed commit: "Restore the bash tag on the toggle examp..." · Reviewed by Greptile

Comment thread shell/plugins/services/idle/Service.qml Resolved
The screensaver now always runs at 120 Hz: it redraws only the cells that change, and the compositor holds redraws to what each display shows, so there is nothing to tune. omarchy-launch-screensaver is a plain hand-off again.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
omarchybot and others added 2 commits October 27, 2026 22:41
Activity in the three-second launch grace is held until the grace ends, but a lock deadline falling inside the grace fired first, so a media key pressed just after the screensaver appeared -- input the overlay never sees -- still locked the session when the lock was set within three seconds of the screensaver. The lock deadline now treats a user already active during the grace the way the end of the grace does.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
An earlier edit stripped it along with a fence that has since been removed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@omarchybot
omarchybot merged commit ce0ef48 into quattro Oct 28, 2026
2 checks passed
ryanrhughes added a commit that referenced this pull request Nov 16, 2026
…#19068)

* Replace the terminal screensaver with the native Wayland one (#16800)

Cherry-pick of #16800 to 4.5.1. The screensaver becomes the omarchy-screensaver package: one overlay per display, closed by any key, click, scroll or mouse movement. The terminal launcher, its configs, window rules and tests go, and a migration installs the package.

Conflicts were the 4.5-only fixes to the terminal screensaver (#17511 and a test fix), resolved by taking quattro's side: bin/omarchy-launch-screensaver is quattro's, and bin/omarchy-screensaver, screensaver-workspace-test.sh and #17511's screensaver-mouse-test.sh are removed.

(cherry picked from commit ce0ef48)

* Carry the screensaver manual's translations from quattro

The English chapter changed with the native screensaver. Each language's paragraph about omarchy toggle screensaver now matches quattro's translation, and the manifest marks those chapters current against the new English.

---------

Co-authored-by: Omarchybot <omabot@omarchy.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Quattro] Screensaver only exits on a keypress inside its own terminal — global mouse/keyboard activity is explicitly ignored while it's up

1 participant