diff options
-rw-r--r-- | src/ui/theme.c | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/ui/theme.c b/src/ui/theme.c index 1bbb9932..fc16f9fa 100644 --- a/src/ui/theme.c +++ b/src/ui/theme.c @@ -625,6 +625,17 @@ strip_button (MetaButtonSpace *func_rects[MAX_BUTTONS_PER_CORNER], } static void +get_margin (GtkStyleContext *style, + GtkBorder *border) +{ + GtkStateFlags state; + + state = gtk_style_context_get_state (style); + + gtk_style_context_get_margin (style, state, border); +} + +static void get_padding_and_border (GtkStyleContext *style, GtkBorder *border) { @@ -678,6 +689,17 @@ meta_frame_layout_sync_with_style (MetaFrameLayout *layout, layout->right_width = border.right; layout->bottom_height = border.bottom; + if (compositing_manager) + get_margin (style, &layout->invisible_border); + else + { + get_margin (style, &border); + + layout->left_width += border.left; + layout->right_width += border.right; + layout->bottom_height += border.bottom; + } + if (layout->hide_buttons) layout->icon_size = 0; |