Bug 427668 - If the panel has a shadow, make it not appear over windows, just the desktop
Summary: If the panel has a shadow, make it not appear over windows, just the desktop
Status: RESOLVED INTENTIONAL
Alias: None
Product: plasmashell
Classification: Plasma
Component: Panel (show other bugs)
Version: 5.19.90
Platform: Arch Linux Linux
: NOR wishlist
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords:
: 472887 (view as bug list)
Depends on:
Blocks:
 
Reported: 2020-10-14 01:07 UTC by Adam Fontenot
Modified: 2023-12-21 22:20 UTC (History)
10 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
screenshot of the problem (833.14 KB, image/png)
2020-10-16 23:46 UTC, Adam Fontenot
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Adam Fontenot 2020-10-14 01:07:23 UTC
SUMMARY

This is just generally rather ugly, especially when a window is maximized.

Reproduce:
1. Set all themes to default.
2. Put a panel on the top of the screen.
3. Drag a window up to the top so that it sits adjacent to the panel (or maximize it).

I'd expect the window to appear above the panel shadow (i.e. the shadow should only be drawn over the desktop), but instead the shadow is drawn over the window.

If this is desired behavior, perhaps an option could be added to disable it.

SOFTWARE/OS VERSIONS
Linux: Arch Linux 5.9.0-arch1-1
KDE Plasma Version: 5.20.0 (no option for this in the version box yet)
KDE Frameworks Version: 5.75.0
Qt Version: 5.15.1
Comment 1 Nate Graham 2020-10-16 15:53:44 UTC
This is indeed intended.

You can turn it off by disabling compositing, though that will disable *all* the shadows everywhere, in addition to animations, so that might be too big a stick.

In the end this is why we have Plasma themes: so people can self satisfy if the default aesthetics don't suit their tastes.

I get that this can be frustrating when there's *just one thing* you'd like to change but everything else is fine. However that *just one thing* differs so widely from person to person that we can't really add enough options to satisfy everyone without making the Breeze theme a meta-theme that would horn in on many other 3rd-party themes' reasons for existing.

So I think this has to stay the way it is in the default Breeze theme, sorry. :) Feel free to create a "breeze shadowless panel" theme though!
Comment 2 Adam Fontenot 2020-10-16 23:20:32 UTC
(In reply to Nate Graham from comment #1)
> I get that this can be frustrating when there's *just one thing* you'd like
> to change but everything else is fine. However that *just one thing* differs
> so widely from person to person that we can't really add enough options to
> satisfy everyone without making the Breeze theme a meta-theme that would
> horn in on many other 3rd-party themes' reasons for existing.
> 
> So I think this has to stay the way it is in the default Breeze theme,
> sorry. :) Feel free to create a "breeze shadowless panel" theme though!

I think the big issue here is that I like the panel shadow and I don't want to get rid of it. I just want windows to be drawn on *top* of the shadow, not below it. So the only thing the shadow should appear on top of is the Desktop. This is what macOS appears to do, for example; it makes for a nice clean edge between the panel and a maximized window.

So effectively to solve this I'd need to be able to change whatever the equivalent of z-index is for this platform to fix this, and I would be surprised if this can be done from a theme. If it can be, maybe you can point me in the right direction?
Comment 3 Adam Fontenot 2020-10-16 23:46:57 UTC
Created attachment 132455 [details]
screenshot of the problem

One more thing - I just realized why it might not be obvious that this looks weird. If you're using the default Breeze settings, which has the dark title bar, the shadow is basically invisible when the window is focused. However, if you're using the light title bar, especially with gradients disabled, it ends up looking very strange and bad on the focused window - to the point it's kind of distracting for maximized windows that the user wants to focus on. Screenshot included.

Maybe the panel shadow behavior could automatically change if the user switches to a light title bar?
Comment 4 Nate Graham 2020-10-17 00:50:13 UTC
Ah, you're using a top panel and a light color scheme. Those seem like important pieces of information. I can see your objection now. That does look a little janky.

Sometimes a picture is worth a thousand words. :)
Comment 5 Adam Fontenot 2021-01-22 03:21:00 UTC
Been busy recently, but I just had a minute to look over the press release for the 5.21 beta and noticed that more people are probably going to be encountering this issue because KDE is switching to a light titlebar.

Have any VDG members have had the chance to look at this bug report? The status hasn't changed for a few months now.
Comment 6 Nate Graham 2021-01-25 15:43:42 UTC
No, nobody has had a chance to look into this. :)
Comment 7 Janet Blackquill 2021-01-25 15:44:55 UTC
I can take a look into this
Comment 8 Podagric 2021-05-18 13:29:31 UTC
@Jan Blackquill any chance of that getting into plasma 5.22? I am using latte-dock only because of this.
Comment 9 Adam Fontenot 2021-05-21 01:03:44 UTC
(In reply to Podagric from comment #8)
> @Jan Blackquill any chance of that getting into plasma 5.22? I am using
> latte-dock only because of this.

Could you clarify what you mean about using latte-dock? I tried it and it appears to also show a shadow on top of other windows, at least in panel mode. (I also encountered about a dozen other bugs in latte-dock, it's pretty flaky at the moment.)

My eventual workaround for this issue was actually to screenshot my desktop with the panel shadow enabled, then use GIMP to edit the shadow into the wallpaper image itself, making it a permanent part of my wallpaper. Then I just use Plasma themes to disable shadows from desktop widgets. It's a dirty solution, but it's working well enough.
Comment 10 Podagric 2021-05-21 02:28:52 UTC
well, in my use the latte-dock is quite stable. I have no problem with him. But I prefer to keep an experience closer than the plasma developers send.

And as for the shade, there is an option for removes it when a window is maximized. I do not know in what specific version it was introduced.
Comment 11 Adam Fontenot 2021-05-21 02:47:55 UTC
(In reply to Podagric from comment #10)
> well, in my use the latte-dock is quite stable. I have no problem with him.
> But I prefer to keep an experience closer than the plasma developers send.
> 
> And as for the shade, there is an option for removes it when a window is
> maximized. I do not know in what specific version it was introduced.

Thanks, I had another look and did find it. For anyone else looking, it's at the bottom of the appearance settings tab.
Comment 12 Noah Davis 2023-08-02 01:05:09 UTC
*** Bug 472887 has been marked as a duplicate of this bug. ***
Comment 13 Nate Graham 2023-12-08 17:05:29 UTC
From bug 478096, we encountered a case where the lack of a panel shadow caused a real usability issue: the inability to tell where a window ended and the panel began. So I think we have to keep the shadow, sorry.
Comment 14 jakubby 2023-12-09 22:03:48 UTC
(In reply to Nate Graham from comment #13)
> From bug 478096, we encountered a case where the lack of a panel shadow
> caused a real usability issue: the inability to tell where a window ended
> and the panel began. So I think we have to keep the shadow, sorry.

What about configurable shadow strength like is the case with window decorations(it doesn't influence the panel)?
The shadow is much more noticeable(too strong) for use with different panel positions.
Comment 15 Niccolò Venerandi 2023-12-10 13:55:14 UTC
Even just talking about shadow strength for panels, I think Nate words still apply:

> In the end this is why we have Plasma themes: so people can self satisfy if the default aesthetics don't suit their tastes.
> I get that this can be frustrating when there's *just one thing* you'd like to change but everything else is fine. However that *just one thing* differs so widely from person to person that we can't really add enough options to satisfy everyone without making the Breeze theme a meta-theme that would horn in on many other 3rd-party themes' reasons for existing.

It's quite easy to just change the shadow strength in the theme, and you can add a fallback to the Breeze theme so that only one file is changed.
Comment 16 Adam Fontenot 2023-12-20 06:47:42 UTC
> the inability to tell where a window ended and the panel began

This is an extremely limited issue though, it only happens in rare circumstances. In particular it doesn't affect the window decoration itself so long as the colors are set correctly (as I think Breeze does).

If there is an accessibility issue to address, I think it should be addressed with a solution that implements good visual design choices, not relying on the ugly effect of panels casting a shadow on adjacent windows. I can think of a number of (mostly complementary) options:

1. Make panels have a different color than the Breeze theme background color for windows. (This should already be true by default, IIRC?)
2. Give panels a 1 px border on the outside edge. (This exact solution was used to solve the "distinguishing between windows" accessibility problem.)
3. Snap windows the <outline border width> (from the window decorations) away from the panel, instead of directly adjacent to the panel, so the already-existing outline would serve to help distinguish between the window and the panel.
4. Use a slight gradient by default on the panel background.

Or we could go with a workaround like:

5. Make this toggleable, just like the outline strength feature was made toggleable.

Personally I like the idea of (3) because it reuses a window-distinguishing feature we already have. I think it would probably look nice, although I haven't made a mockup.

Can we discuss options that would result in better visual design, rather than closing this because of one relatively rare issue?
Comment 17 Nate Graham 2023-12-20 20:50:03 UTC
At the moment the shadow is part of the intended design of the Breeze theme. As Niccolò mentioned, if you don't like it, you're welcome to use a different theme, or to fork the Breeze theme to remove the shadow.

Of your proposed alternatives, I like the 1px border idea as this could actually increase consistency with other Breeze-window-decoration-themed windows, which also have both a border and a shadow.

If you'd like to pursue that option, I'd recommend submitting a new bug report about it.

I'd also grudgingly accept a new panel-specific option to disable the shadow, seeing as how we already have other purely visual options to toggle  translucency and floatingness. But I'll be a grumpy old man and grouse about it a bit. :)
Comment 18 Niccolò Venerandi 2023-12-21 22:20:11 UTC
I'll definitively _not_ accept a button to disable the panel's shadow, sorry :-)