From 6f33395c69550e1fad6aa49d52e1284ca89f88c1 Mon Sep 17 00:00:00 2001 From: Victor Kareh Date: Wed, 22 May 2019 10:56:11 -0400 Subject: Only shadow ARGB windows with a frame outside the frame An ARGB window with a frame is likely something like a transparent terminal. It looks awful (and breaks transparency) to draw a big opaque black shadow under the window, so clip out the region under the terminal from the shadow we draw. Add meta_window_get_frame_bounds() to get a cairo region for the outer bounds of the frame of a window, and modify the frame handling code to notice changes to the frame shape and discard a cached region. meta_frames_apply_shapes() is refactored so we can extract meta_frames_get_frame_bounds() from it. https://bugzilla.gnome.org/show_bug.cgi?id=635268 NOTE: Applied only partially, compositor part is still missing... upstream commit: https://gitlab.gnome.org/GNOME/metacity/commit/0f2e32d1 --- src/include/ui.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/include/ui.h') diff --git a/src/include/ui.h b/src/include/ui.h index 652e8cfc..40ae03cf 100644 --- a/src/include/ui.h +++ b/src/include/ui.h @@ -97,6 +97,11 @@ void meta_ui_apply_frame_shape (MetaUI *ui, int new_window_height, gboolean window_has_shape); +cairo_region_t *meta_ui_get_frame_bounds (MetaUI *ui, + Window xwindow, + int window_width, + int window_height); + void meta_ui_queue_frame_draw (MetaUI *ui, Window xwindow); -- cgit v1.2.1