Description: Fix shadows
Origin: upstream, https://bugs.freedesktop.org/show_bug.cgi?id=46285
Author: 3 Brandon Gooch
Reviewed-by: Alessandro Ghedini <ghedo@debian.org>
Last-Update: 2013-11-15

--- a/xcompmgr.c
+++ b/xcompmgr.c
@@ -1028,7 +1028,6 @@
 	{
 	    w->borderClip = XFixesCreateRegion (dpy, NULL, 0);
 	    XFixesCopyRegion (dpy, w->borderClip, region);
-	    XFixesIntersectRegion(dpy, w->borderClip, w->borderClip, w->borderSize);
 	}
 	w->prev_trans = t;
 	t = w;
@@ -1080,6 +1079,8 @@
 	if (w->mode == WINDOW_TRANS)
 	{
 	    int	x, y, wid, hei;
+	    XFixesIntersectRegion(dpy, w->borderClip, w->borderClip, w->borderSize);
+	    XFixesSetPictureClipRegion(dpy, rootBuffer, 0, 0, w->borderClip);
 #if HAS_NAME_WINDOW_PIXMAP
 	    x = w->a.x;
 	    y = w->a.y;
@@ -1099,6 +1100,8 @@
 	else if (w->mode == WINDOW_ARGB)
 	{
 	    int	x, y, wid, hei;
+	    XFixesIntersectRegion(dpy, w->borderClip, w->borderClip, w->borderSize);
+	    XFixesSetPictureClipRegion(dpy, rootBuffer, 0, 0, w->borderClip);
 #if HAS_NAME_WINDOW_PIXMAP
 	    x = w->a.x;
 	    y = w->a.y;
