Shadows are cropped on non-CSD windows under mutter [$50]

Bug #1437173 reported by brncsk
130
This bug affects 28 people
Affects Status Importance Assigned to Milestone
Gala
Invalid
High
Unassigned
elementary Stylesheet
Fix Released
Medium
Unassigned

Bug Description

This started happening under gnome-shell/mutter 3.16, possibly due to mutter now rendering all window decorations with GTK+ (see [1]).

[1] https://bugzilla.gnome.org/show_bug.cgi?id=741917

Tags: bounty
Revision history for this message
brncsk (adam-barancsuk) wrote :
Changed in egtk:
milestone: none → loki-beta1
Cody Garver (codygarver)
Changed in egtk:
importance: Undecided → Medium
Revision history for this message
Danielle Foré (danrabbit) wrote :

As far as I can tell, this only affects non-gtk3 apps. So I'm wondering if it's actually an issue in Gala. There's another problem here in that the decoration buttons don't work.

Revision history for this message
Danielle Foré (danrabbit) wrote :

This seems to also be a problem with mutter (tested with mutter --replace) but at least the decoration buttons work in Mutter.

Revision history for this message
Danielle Foré (danrabbit) wrote :

So for some reason this seems to happen only occasionally. For that reason, I'm going to assume this is a Gala/Mutter issue. I don't think I have any control over this in the stylesheet

Changed in egtk:
status: New → Invalid
milestone: loki-beta1 → none
Changed in gala:
milestone: none → loki-beta1
Cody Garver (codygarver)
Changed in gala:
importance: Undecided → Medium
Changed in gala:
status: New → Confirmed
Cody Garver (codygarver)
Changed in gala:
importance: Medium → High
Changed in gala:
milestone: loki-beta1 → loki-beta2
Revision history for this message
Danielle Foré (danrabbit) wrote :
summary: - Shadows are cropped on non-CSD windows under mutter
+ Shadows are cropped on non-CSD windows under mutter [$50]
tags: added: bounty
Changed in gala:
assignee: nobody → Adam Bieńkowski (donadigo)
status: Confirmed → In Progress
Changed in gala:
assignee: Adam Bieńkowski (donadigo) → nobody
status: In Progress → Confirmed
Revision history for this message
Adam Bieńkowski (donadigo) wrote :

After restarting gala the issue is gone, but is easily reproducible by snapping the window to one of the screen edges and unsnapping it. Hope that this helps someone.

Revision history for this message
Vishal Rao (vishalrao) wrote :

Is everyone who is able to repro this issue running on Intel graphics?
I was trying to search for the xserver-xorg-video-intel package patch code location but could only find Trusty version which has a shadows-related patch in it. Wondering if this current Loki issue is stemming from that area.

Revision history for this message
shantanu saha (shantanucse18-gmail) wrote :

I have install MacBuntu-OS theme and I found the shadow issue is gone(restart application). So it should be a elementary-theme issue not Gala. I have attached two image, one with elementary theme and other with MacBuntu-OS theme.

MacBuntu-OS theme:
https://s6.postimg.org/xrnj9h21t/Screenshot_from_2016_08_10_13_22_17.png

Elementary theme:
https://s6.postimg.org/5q9hvrwrl/Screenshot_from_2016_08_11_00_15_41.png

Revision history for this message
Maxim Taranov (png2378) wrote :

shantanu saha: This solution breaks shadows on CSD-windows.

Revision history for this message
shantanu saha (shantanucse18-gmail) wrote :

Maybe I have solved this problem. Make some changes and let's see what happened.

File: /usr/share/themes/elementary/gtk-3.0/gtk.css

/* Add this line to end of the file */
@define-color backdrop_bg_color @theme_bg_color;

File: /usr/share/themes/elementary/gtk-3.0/gtk-widgets.css
search for '.window-frame { .... }' replace the whole block by following code

.window-frame {
  border-radius: 5px 5px 0 0;
  border-width: 0;
  box-shadow: 0 3px 9px 1px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(0, 0, 0, 0.23);
  margin: 10px; }
  .window-frame:backdrop {
    box-shadow: 0 1px 6px 2px rgba(0, 0, 0, 0.2), 0 0 0 1px rgba(0, 0, 0, 0.18); }
  .window-frame.tiled {
    border-radius: 0; }
  .window-frame.csd.popup {
    border-radius: 0;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2), 0 0 0 1px rgba(0, 0, 0, 0.13); }

/* classic decoration */
  .window-frame.ssd {
    border-radius: 5px 5px 0 0;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.18); }
  .window-frame.ssd,
  .window-frame.ssd:backdrop {
    background-color: @backdrop_bg_color}

  .window-frame.csd.tooltip {
    border-radius: 0;
    box-shadow: none; }
  .window-frame.csd.message-dialog {
    border-radius: 3px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2), 0 0 0 1px rgba(0, 0, 0, 0.13); }
 .window-frame.solid-csd {
     border: solid 1px shade(@bg_color, 0.8);
     border-radius: 0;
     margin: 2px;
     background-color: @bg_color;
     box-shadow: none;
}

Save and logout. In my case it solved shadow issue. I installed elementary-desktop over Ubuntu. Can anybody please check it for fresh installed elementary Loki?

I found the hints in MacBuntu-OS theme.

-Thanks

Changed in egtk:
status: Invalid → Confirmed
Changed in gala:
status: Confirmed → Invalid
Revision history for this message
Danielle Foré (danrabbit) wrote :

Alright so it doesn't address the actual cropping issue, but I can workaround it by making the shadow smaller just for .ssd class. Thanks for the hint. Marking as fixed :)

Changed in egtk:
status: Confirmed → Fix Committed
milestone: none → loki-rc1
Changed in gala:
milestone: loki-rc1 → none
Cody Garver (codygarver)
Changed in egtk:
milestone: loki-rc1 → 5.0
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.