summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIain Holmes <iain@src.gnome.org>2007-11-14 00:23:40 +0000
committerIain Holmes <iain@src.gnome.org>2007-11-14 00:23:40 +0000
commit99e5be1e7e019df3b14d4d6e5c71324a8f5c73b3 (patch)
tree6e8e3819050ef4581f195ff553ad92006da0b5d2
parent4ae3e2fb224faad2d20adbe0efb5a4b52bc3bbf4 (diff)
downloadmetacity-99e5be1e7e019df3b14d4d6e5c71324a8f5c73b3.tar.gz
Make nicer shadows and put a shadow around ARGB managed windows
svn path=/branches/iains-blingtastic-bucket-o-bling/; revision=3395
-rw-r--r--src/compositor.c16
1 files changed, 6 insertions, 10 deletions
diff --git a/src/compositor.c b/src/compositor.c
index ccbb54c5..7a5764af 100644
--- a/src/compositor.c
+++ b/src/compositor.c
@@ -93,10 +93,10 @@ typedef struct _MetaCompWindow {
#define WINDOW_TRANS 1
#define WINDOW_ARGB 2
-#define SHADOW_RADIUS 12.0
-#define SHADOW_OFFSET_X -15
-#define SHADOW_OFFSET_Y -15
-#define SHADOW_OPACITY 0.75
+#define SHADOW_RADIUS 6.0
+#define SHADOW_OFFSET_X (SHADOW_RADIUS * -3 / 2)
+#define SHADOW_OFFSET_Y (SHADOW_RADIUS * -5 / 4)
+#define SHADOW_OPACITY 0.66
#define TRANS_OPACITY 0.75
@@ -651,14 +651,10 @@ win_extents (MetaCompWindow *cw)
/*
We apply a shadow to the window if:
- - There is no overlay (ie unredirected windows)
- - It's a window with a frame and the user asked for shadows under regular
- windows,
- - it's an override redirect window that is not shaped, not an argb and
- the user asked for shadows on so called "popup" windows.
+ * the window is ARGB and override redirected.
*/
- if (cw->mode != WINDOW_ARGB) {
+ if (! (cw->mode == WINDOW_ARGB && cw->attrs.override_redirect)) {
XRectangle sr;
cw->shadow_dx = SHADOW_OFFSET_X;