From 409143637f80209f681bc0926f435be29a51de14 Mon Sep 17 00:00:00 2001 From: Benjamin Otte Date: Fri, 29 Apr 2011 09:38:23 +0200 Subject: [PATCH] notebook: Respect padding when computing tabs for left/right This mirrors the top/bottom code --- gtk/gtknotebook.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/gtk/gtknotebook.c b/gtk/gtknotebook.c index 61e30795e1..2d4530c5c2 100644 --- a/gtk/gtknotebook.c +++ b/gtk/gtknotebook.c @@ -6177,11 +6177,16 @@ gtk_notebook_page_allocate (GtkNotebook *notebook, */ if (page != priv->cur_page && tab_overlap > tab_curvature) { - child_allocation.height -= tab_overlap - tab_curvature; - if (gtk_notebook_page_num (notebook, page->child) > gtk_notebook_page_num (notebook, priv->cur_page->child)) - child_allocation.y += tab_overlap - tab_curvature; + { + child_allocation.y += tab_overlap - tab_curvature - tab_padding.top; + child_allocation.height -= tab_overlap - tab_curvature - tab_padding.top; + } + else + { + child_allocation.height -= tab_overlap - tab_curvature - tab_padding.bottom; + } } } else