Wayland opacity regions are incorrect when window is maximized
Categories
(Core :: Widget: Gtk, defect)
Tracking
()
People
(Reporter: 0456523, Unassigned)
References
(Blocks 1 open bug)
Details
Attachments
(3 files, 1 obsolete file)
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:159.0) Gecko/20100101 Firefox/159.0
Steps to reproduce
- Make a
userChrome.css(included in the attached zip) that makes the background and titlebar transparent but uses a:beforeto make the background gradient translucent without making the entire window translucent - Start Firefox
- Maximize the window
Actual results
- When the window is not maximized, the blur regions are correct (see
1A.pngand1B.pngin the zip). - When the window is maximized, the blur regions are incorrect (see
2A.pngand2B.png;2A_edited.pngand2B_edited.pngpoint out the issues using red boxes). - I have a glass effect plugin installed in KDE. When I tell the glass effect to ignore opacity regions by enabling the "ignore blur regions" option, it appears correctly (
3A.pngand3B.png), but this comes with a massive GPU and battery usage tax that I cannot afford, as it will shade the entire window area with the effect before pasting over the effect with the window contents, which is expensive and wasteful.
Expected results
The opacity regions should be set correctly when maximized, so that Firefox looks like 3A.png and 3B.png without having to enable the glass effect's "ignore blur regions" option.
Comment 1•15 days ago
|
||
The Bugbug bot thinks this bug should belong to the 'Core::Widget: Gtk' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.
Updated•14 days ago
|
I will say, I'm not using fractional scaling (my scale is set to 100%), but I'll wait and see if the fix for that fixes this issue for me too.
Comment 4•10 days ago
|
||
I wonder how is that possible. If you use 100% scale, please run on terminal with MOZ_LOG="Widget:5" env variable, reproduce the issue and attach the log here.
Thanks
Updated•10 days ago
|
I can easily reproduce the issue by hitting alt to show the menubar. I can see in the log that when I open the menubar, it sets the opaque region like so:
[Parent 1492324: Main Thread]: D/Widget [7f00630fb800]: nsWindow::UpdateOpaqueRegionInternal() set opaque region [281,93] -> [1354 x 30]
[Parent 1492324: Main Thread]: D/Widget [7f00630fb800]: nsWindow::UpdateOpaqueRegionInternal() set opaque region [0,130] -> [1920 x 950]
I drew out that region in GIMP with opaque as red and transparent as green, and put it over a screenshot.
So I can see that firefox is at least claiming to set the correct region, but it seems that kwin might not be getting the memo? idrk
Here's the screenshot with the claimed region drawn on top.
The claimed region is correct and lines up, but the actual region being used by kwin does not line up, and the background bleeds through a part that kwin still thinks is opaque.
Comment 7•10 days ago
|
||
Please run with WAYLAND_DEBUG=1 - does the nsWindow::UpdateOpaqueRegionInternal() matches region passed to Wayland compositor?
From what I can see in the log, it seems to only do set_opaque_region 2 times out of the 8 times the opaque region is updated
Updated•9 days ago
|
Description
•