Skip to content

core/layers: top layers go below fullscreen windows, fix DS solitary - #15937

Open
erstarr wants to merge 20 commits into
hyprwm:mainfrom
erstarr:painAndSuffering
Open

erstarr wants to merge 20 commits into
hyprwm:mainfrom
erstarr:painAndSuffering

Conversation

@erstarr

@erstarr erstarr commented Aug 22, 2026 •

Copy link
Copy Markdown
Contributor

Describe your PR, what does it fix/add?

Title
Fixes #15881

Adds the config opt: misc:allow_new_top_layers_over_existing_fullscreen, which is self descriptive.

Is there anything you want to mention? (unchecked code, possible bugs, found problems, breaking compatibility, etc.)

Default value for the new config opt is true to prevent stuff that relies on the "old" (config value true, not exactly old since there is a config for this but many ppl seem to consider = false to be a net improvement so mayhaps the config value could be removed in the future and = false could become the new standard. Or maybe wayland protocol will become less ambiguous and we'll just follow that) behaviour still works.

Hypractl Layers: Do not show a layer before it's properly mapped. It's a race condition if this is done ontop of making little sense: with hardware rendering the mapping happens fast enough for this to not matter but in github tests CI it incorrectly displays the alpha of the layers.

Is it ready for merging, or does it need work?

WIP

  • Notifications
  • Test

@erstarr
erstarr marked this pull request as ready for review August 22, 2026 22:28
@github-actions
github-actions Bot requested a review from vaxerski August 22, 2026 22:28
@vaxerski

Copy link
Copy Markdown
Member

top layers over fs is expected. New ones should.

@erstarr

erstarr commented Aug 23, 2026

Copy link
Copy Markdown
Contributor Author

top layers over fs is expected. New ones should.

#15881 disagrees with you.

Besides, dark, ritz, etc... also think so. The reason being there isn't a layer that's below fullscreen but above normal windows. bars etc... use top in noctalia wayle etc.. and when you cycle them in fullscreen, they render over fullscreen

@Dregu

Dregu commented Aug 23, 2026

Copy link
Copy Markdown
Contributor

Yeah but nobody likes that. The protocol is stupid and there should be an option to not put any top layers above fullscreen. That's what overlay is for. So make this optional and everyone is happy.

@LRitzdorf

Copy link
Copy Markdown
Contributor

Yeah. Having timing-dependent behavior like we currently do just feels buggy, even if the spec says it's technically okay. Users go "oh not this bug again" and toggle fullscreen, which they really shouldn't have to do

@darkwater

darkwater commented Aug 23, 2026 •

Copy link
Copy Markdown
Contributor

The protocol doesn’t even prescribe that that should happen, it just describes that that’s what tends to happen.

It also means that if you don’t want notifications to pop up over fullscreen windows, there is no layer to place them.

Also when I ran into this I also saw it as a bug and went “welp gotta un-fs and fs my game again, which is annoying because it’s in hdr so it’ll blank out for a while”

e: As it stands now, there is no layer between tiled/floating windows and fullscreen windows.

@erstarr

erstarr commented Aug 23, 2026 •

Copy link
Copy Markdown
Contributor Author

Added a config opt to control this. Defaults to true, which is the old behaviour

misc:allow_new_top_layers_over_existing_fullscreen

@erstarr

erstarr commented Aug 23, 2026 •

Copy link
Copy Markdown
Contributor Author

I have absolutely no idea why the tests are failing in github CI.

Wait until layer spawn, wait until alpha is correctly set - all for naught. Layer tests are just not working on CI. Always passes in local.

@vaxerski

Copy link
Copy Markdown
Member

I don't like it. But, if we're gonna change this, just make all tops below fs. Don't add a knob.

@erstarr
erstarr marked this pull request as draft August 29, 2026 16:16
@Dregu

Dregu commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Bug: Top layers that were never even visible still seem to block DS with "fadeout in progress" when closing under the fullscreen app. e.g. my bar normally shows up only when holding SUPER, this pr prevents that perfectly fine, but game goes out of ds for a fraction of a second when releasing SUPER and the bar closes.

Don't add a knob.

Bit of a conflict here, if "new top layers go above fullscreen" is indeed how the protocol should be interpreted, why should there not even be an option to follow the protocol?

@erstarr

erstarr commented Sep 3, 2026

Copy link
Copy Markdown
Contributor Author

Bug: Top layers that were never even visible still seem to block DS with "fadeout in progress" when closing under the fullscreen app. e.g. my bar normally shows up only when holding SUPER, this pr prevents that perfectly fine, but game goes out of ds for a fraction of a second when releasing SUPER and the bar closes.

From your other comments in other discussions, the regressor is #15991 - this MR or anything it changes have nothing to do with that.

@Dregu

Dregu commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

My other comments elsewhere have nothing to do with layers fading. Without this PR the new top layer would obviously be visible on top of the game already, and the fadeout should block DS. It's definitely something this PR needs to account for when the fading layer isn't even visible.

@LRitzdorf

Copy link
Copy Markdown
Contributor

Don't add a knob.

Bit of a conflict here, if "new top layers go above fullscreen" is indeed how the protocol should be interpreted, why should there not even be an option to follow the protocol?

FWIW, the protocol doesn't actually say which way this should go. All it really does is comment on how some compositors worked at the time of writing. Not to say that what other compositors do is totally irrelevant, but we certainly aren't violating the spec by saying "FS goes above the top layer always"

@LRitzdorf

Copy link
Copy Markdown
Contributor

Bug: Top layers that were never even visible still seem to block DS with "fadeout in progress" when closing under the fullscreen app. e.g. my bar normally shows up only when holding SUPER, this pr prevents that perfectly fine, but game goes out of ds for a fraction of a second when releasing SUPER and the bar closes.

@Dregu Got a fix for this. Beforehand, any fadeouts whatsoever would block solitary (and thus DS), even ones on background or bottom which would never be above the FS window. Have sent patch to erstarr, will probably appear here soonish

@erstarr erstarr changed the title core/layers: Top layers go below fullscreen windows core/layers: Top layers go below fullscreen windows, fix DS solitary Sep 5, 2026
@Dregu

Dregu commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

If you say so, I did specifically only test an invisible (i.e. opened before fullscreen) top layer on main though and its fadeout did not block DS.

And yes the protocol specifically says "order is undefined" so we can do whatever we want with FS, screw all the shells that assume top might go above FS.

@LRitzdorf

Copy link
Copy Markdown
Contributor

an invisible (i.e. opened before fullscreen) top layer on main though and its fadeout did not block DS.

Huh, I just checked that specific case on main, and it did block DS:

image

Well, in any case, it's fixed on this branch now!

@FakeMichau

Copy link
Copy Markdown
Contributor

Can confirm that this PR fixes the issue I was seeing in #15881.
But seems like allow_new_top_layers_over_existing_fullscreen has no effect. The fix seems to be always active regardless of the setting.

@erstarr

erstarr commented Sep 12, 2026

Copy link
Copy Markdown
Contributor Author

Really busy nowadays and don't have the time for this. I'll get to this as soon as I can (prob on the 18th or that weekend)

@erstarr
erstarr force-pushed the painAndSuffering branch 3 times, most recently from 13aba9c to 957bd57 Compare October 10, 2026 16:34
vaxerski pushed a commit that referenced this pull request Oct 13, 2026
…ync upon work area change (#16493)

* change

* test-preliminary

* new helper function -- extracted from #15937

* test - complete
@erstarr

erstarr commented Oct 17, 2026 •

Copy link
Copy Markdown
Contributor Author

@vaxerski poke

@erstarr erstarr changed the title core/layers: Top layers go below fullscreen windows, fix DS solitary core/layers: top layers go below fullscreen windows, fix DS solitary Oct 17, 2026
Comment thread src/output/Monitor.cpp Outdated
hegjon pushed a commit to hegjon/hypoland that referenced this pull request Oct 20, 2026
…ync upon work area change (hyprwm#16493)

* change

* test-preliminary

* new helper function -- extracted from hyprwm#15937

* test - complete

(cherry picked from commit 1bd31aa)
[Hypoland: without the hyprtester and nix parts]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants