Commit Graph

1906 Commits

Author SHA1 Message Date
Benjamin Bäumler 9e5716a9db Add tablet option map-to-focused-output 2026-04-18 12:41:08 +03:00
sodiboo ce9dd33213 protocols: implement ext-foreign-toplevel-list-v1
clean up foreign toplevel destruction: don't `retain` to remove one item

document why we have duplicate destruction logic in foreign toplevel

messy to have two of the same comment but like how else do i make that
information readily available to both

Co-authored-by: HigherOrderLogic <73709188+HigherOrderLogic@users.noreply.github.com>
2026-04-18 09:56:50 +03:00
Ivan Molodetskikh 10995ec62c Fix 1 new Clippy warning
I don't like the other ones
2026-04-18 09:30:28 +03:00
Ivan Molodetskikh c814c656c5 Dlsym set_default_max_buffer_size() to avoid wayland-server 1.23 requirement
Ubuntu 24.04 users rejoice
2026-04-17 16:32:10 +03:00
ArijanJ 82d4c7569e Handle trackball scrolling in overview 2026-04-16 21:17:49 +03:00
Ivan Molodetskikh a1b0bd6d1c Assume square corners for windowed fullscreen windows 2026-04-16 19:47:28 +03:00
Ivan Molodetskikh 892470afd3 Call on_maybe_dnd_ended() in two more places
This is not exhaustive and not a good solution. A proper Smithay
callback is needed: https://github.com/Smithay/smithay/issues/1996
2026-04-16 12:35:35 +03:00
Ivan Molodetskikh 5dc4e83ba7 Upgrade dependencies 2026-04-16 09:54:53 +03:00
Ivan Molodetskikh 2b58e03d30 Upgrade tracing-subscriber and disable ANSI sanitization 2026-04-16 09:54:53 +03:00
Ivan Molodetskikh d4b4407236 Implement cancelling DnD with Escape
The last Smithay upgrade includes a fix that lets us do this.
2026-04-16 09:54:53 +03:00
Ivan Molodetskikh 26ff5f4bf1 Upgrade Smithay (fix disappeared connectors, fix DnD hang in Electron) 2026-04-16 09:54:53 +03:00
Ivan Molodetskikh d7905e6b74 Downgrade accesskit_unix to 0.17.0
Workaround for a 0.18 regression where accessibility doesn't work under
normal conditions.

https://github.com/niri-wm/niri/issues/3594

https://github.com/AccessKit/accesskit-c/issues/76
2026-04-16 09:54:48 +03:00
Ivan Molodetskikh 71d7fa9a61 effect_buffer: Change debug! to trace! 2026-04-15 21:35:28 +03:00
Ivan Molodetskikh 707f08559c postprocess: Replace IGN with more white-noise-like noise
IGN gives visible patterns when zooming in or increasing noise amount.
2026-04-15 21:28:22 +03:00
Ivan Molodetskikh 4d21489101 Add geometry-corner-radius and background-effect popup rules 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 5a24aae560 Add popups { opacity } window and layer rule 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 9170161a0a Implement ext-background-effect for popups 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 66d66d6030 Implement non-xray background effects 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 19866f8b0b Refactor screencopy/screencast to render via the damage tracker, fix cursorless screencopy with damage
The damage tracker stores framebuffer effect cache, so we want anything
that renders repeatedly to render through a reused damage tracker. This
way, the cache persists and is reused across renders.

This will be important for the non-xray background effects.
2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 4bc3ede4b7 blur: Update to use GlesRenderer in a subframe
Will be necessary for non-xray.
2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 250aa1f3cb Upgrade Smithay (framebuffer effect, subframes) 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 931123f38c Implement ext-background-effect protocol 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 73c0ce75d8 Implement blur background effect 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 1b1715fe9b Implement noise and saturation background effects 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh fee8719299 Implement xray background effect 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 7f9c7d1415 Get state in one place instead of three 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh b81cb13c2c Simplify popup position computation 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 45582ad095 render_helpers: Extract common functions 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh b3f5255bb9 layout: Narrow error! condition in update_render_elements()
As far as I can tell, the only place where we can hit this currently is
do-screen-transition when no outputs are connected. A check could be
trivially added there, but I don't think it's worth enforcing it with an
error! -- it's just an optimization (avoiding running unnecessary code)
while being rare and difficult to find if it does get logged.
2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 8c169b1a14 offscreen: Guard against zero size (empty elements) 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 525b33777b offscreen: Add error message 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh dec0e3bf5a layout: Improve view_rect computation for the interactively moved window 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 6bcaaf9d21 Add layer matcher to layer-rule 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh f022b3c504 damage: Remove set_size()
Changes in geometry already cause a repaint.
2026-04-15 14:35:14 +03:00
Ivan Molodetskikh ab10a260fa Rename Niri::render_inner() => render() 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 0eddd16b8a Rename Niri::render() => render_to_vec() 2026-04-15 14:35:14 +03:00
Ivan Molodetskikh d020d986ed shaders: Optimize rounding_alpha() a little
Simplified clamping exploiting half_px + half_px = 1.0 / niri_scale.

Makes the resize shader fit on a Eee PC ALU.
2026-04-15 14:35:14 +03:00
Ivan Molodetskikh 5abeb923de shaders: Extract niri_rounding_alpha() into a file
To have it in one place.
2026-04-15 14:35:14 +03:00
Ivan Molodetskikh dd1f28998f Bundle renderer and target into a RenderCtx 2026-04-15 14:35:14 +03:00
Jakob Hellermann 8f48f56fe1 ui/hotkey_overlay: prettify diaeresis keysyms 2026-03-27 16:00:18 +03:00
Ivan Molodetskikh a217ad6424 tty: Log on DrmScanEvent::Changed 2026-03-07 08:54:39 +03:00
Ivan Molodetskikh f4dc10e0b4 Upgrade Smithay (virtual_keyboard revert, clipboard destroy cleanup, xdg-shell v7)
The virtual keyboard is reverted to the same state as it was in v25.08, i.e.
cannot trigger compositor binds. A bigger Smithay refactor is necessary to
properly support them without breaking other things.

Fixes wtype being completely broken.
2026-03-07 08:17:52 +03:00
Ivan Molodetskikh b82d52705e Increase default Wayland buffer size
The buffer size matches the one used in other compositors, e.g.:

- https://gitlab.gnome.org/GNOME/mutter/-/blob/49.4/src/wayland/meta-wayland.c?ref_type=tags#L970-971
2026-03-07 08:03:28 +03:00
Ivan Molodetskikh c7fa5f29d6 Upgrade dependencies 2026-03-07 08:03:24 +03:00
Jon Heinritz e708f54615 winit: add an app-id when running niri in nested mode in nested mode 2026-02-27 23:53:51 +08:00
Tobias Heider 1fa0338a17 openbsd: implement close_range workaround
Since OpenBSD doesn't have close_range we have
to use close from and close the remaining
descriptors manually.
2026-02-16 03:00:17 +08:00
Ivan Molodetskikh 41b5de8769 Change all links from YaLTeR/niri to niri-wm/niri 2026-02-10 17:59:14 +03:00
Christian Meissl 6d5c5f12b2 Fix dead surface hook VRAM leak (#3404)
* remove pre-commit hook when surface is destroyed

this re-uses the already existing remove_default_dmabuf_pre_commit_hook
during surface destruction instead of just removing the hook from the
stored list of hooks.

* do not add dmabuf pre-commit hook for destroyed surfaces

this prevents surfaces getting stored indefinitely in case
some logic tries to add the hook for an already
destroyed surface.

* align surface/toplevel destruction order for client destruction

resource destruction has undefined order in case
the client does not explicitly destroy the resourced
and wait for destruction to complete.
the same applies for clients exiting unexpectedly.

* rearrange some things

---------

Co-authored-by: Ivan Molodetskikh <yalterz@gmail.com>
2026-02-10 05:55:49 +00:00
Ivan Molodetskikh ab47f5cec4 Remove obsolete FIXME 2026-02-06 19:22:39 +03:00
ジムワルド 549148d277 Add load-config-file --path to load a different config (#3395)
* ipc: allow load-config to relocate the path of the config

* doc: add info about alternative configuration paths and relocating

Co-authored-by: Ivan Molodetskikh <yalterz@gmail.com>

* Update docs/wiki/Integrating-niri.md

* Update niri-ipc/src/lib.rs

* Update src/ipc/server.rs

---------

Co-authored-by: Ivan Molodetskikh <yalterz@gmail.com>
2026-02-06 19:22:16 +03:00