Commit 73dc5465 authored by Matthias Clasen's avatar Matthias Clasen Committed by Matthias Clasen

Changed size requisition so the viewport does not add the border thickness

2007-07-09  Matthias Clasen  <mclasen@redhat.com>

        * gtk/gtkviewport.c (gtk_viewport_size_request): Changed size
        requisition so the viewport does not add the border thickness
        if it has GTK_SHADOW_NONE selected.  (#361781, Miguel Gomez)



svn path=/trunk/; revision=18421
parent eab944bb
2007-07-09 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkviewport.c (gtk_viewport_size_request): Changed size
requisition so the viewport does not add the border thickness
if it has GTK_SHADOW_NONE selected. (#361781, Miguel Gomez)
2007-07-09 Matthias Clasen <mclasen@redhat.com>
* gtk/gtktooltip.c (gtk_tooltip_trigger_tooltip_query):
......
......@@ -712,11 +712,15 @@ gtk_viewport_size_request (GtkWidget *widget,
bin = GTK_BIN (widget);
requisition->width = (GTK_CONTAINER (widget)->border_width +
GTK_WIDGET (widget)->style->xthickness) * 2;
requisition->width = GTK_CONTAINER (widget)->border_width;
requisition->height = (GTK_CONTAINER (widget)->border_width * 2 +
GTK_WIDGET (widget)->style->ythickness) * 2;
requisition->height = GTK_CONTAINER (widget)->border_width;
if (GTK_VIEWPORT (widget)->shadow_type != GTK_SHADOW_NONE)
{
requisition->width += 2 * widget->style->xthickness;
requisition->height += 2 * widget->style->ythickness;
}
if (bin->child && GTK_WIDGET_VISIBLE (bin->child))
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment