Skip to content

fix(overview): scale focus ring shaders with window previews - #337

Merged
ItsLemmy merged 3 commits into
noctalia-dev:mainfrom
barrulus:fix/overview-focus-ring-scale
Sep 29, 2026
Merged

ItsLemmy merged 3 commits into
noctalia-dev:mainfrom
barrulus:fix/overview-focus-ring-scale

Conversation

@barrulus

@barrulus barrulus commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Focus ring details and inner overlays now shrink with overview cards. At overview.zoom = 0.1, a 40-pixel overlay becomes 4 pixels wide instead of retaining its desktop width.

Pass the current overview zoom through the existing effect parameters and account for it when binding shader dimensions, radii, and buffer scale. Border light spread scales with the card, and existing snapshot copying retains the effect scale when a card closes.

Motivation

Closes #324. Overview already scaled the card geometry, but procedural shader distances stayed in desktop-sized pixels.

Type of Change

  • Bug fix

Testing

All commands ran in the Nix development shell:

  • meson test -C build-debug -j6 --print-errorlogs: 103 passed.
  • Headless harness: overview/effect_scale, overview/card_lifecycle, effect/border, effect/border_frames, effect/border_transform, effect/window, and effect/window_capture passed.
  • just check-stress overview/effect_scale 8: all 8 concurrent runs passed.
  • just lint src/view/effects.cpp src/view/view.cpp src/overview/overview.cpp: passed.
  • just format, formatter verification, bash -n, and git diff --check: passed.

The new pixel regression fails on unchanged main: at 50% zoom, the overlay measures 80 pixels across instead of 40. With the fix it verifies 50% and 10% zoom, intermediate opening and closing frames, desktop restoration, a rotated output at scale 1.25, and close snapshots.

The reporter manually tested the patched build in a nested Wayland session with their neon-bleed border and inner overlay at overview.zoom = 0.1, and confirmed that it works correctly. Native-session visual review has not been performed.

Documentation and the effects example describe the overview scaling behavior. No configuration keys or defaults changed.

Checklist

  • This PR is ready for review, or it is marked as Draft.
  • This change fits SCOPE.md, or its scope was agreed in an issue or on Discord first.
  • I read and followed the relevant guidance in CONTRIBUTING.md.
  • I ran just format, or this PR has no C++ changes.
  • I ran the relevant build, test, lint, or verification commands, or explained why they were not run.
  • I functionally verified compositor behavior where automated checks are insufficient.
  • I self-reviewed the changes.
  • I checked for new warnings or errors.
  • I updated docs/ and examples/config.toml, or this PR does not change user-facing configuration or behavior.
  • I used canonical names for config keys, IPC actions, paths, and identifiers.

@barrulus
barrulus marked this pull request as ready for review September 28, 2026 19:47
@ItsLemmy
ItsLemmy merged commit 15cd702 into noctalia-dev:main Sep 29, 2026
3 checks passed
@ItsLemmy

Copy link
Copy Markdown
Contributor

Thx

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.

[BUG] Focus ring shaders in Overview are too big

2 participants