From 44e8897a482c71a02e2e37543c253a862d25f0d8 Mon Sep 17 00:00:00 2001 From: Michael Drake Date: Wed, 26 Jan 2011 15:14:38 +0000 Subject: Make layout of block formatting contexts take account of the bottom margin of the last contained block. svn path=/trunk/netsurf/; revision=11498 --- render/layout.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'render/layout.c') diff --git a/render/layout.c b/render/layout.c index 52f5d1ac2..9445b4327 100644 --- a/render/layout.c +++ b/render/layout.c @@ -621,6 +621,9 @@ bool layout_block_context(struct box *block, int viewport_height, margin_box = box; } + /* Account for bottom margin of last contained block */ + cy += max_pos_margin - max_neg_margin; + /* Increase height to contain any floats inside (CSS 2.1 10.6.7). */ for (box = block->float_children; box; box = box->next_float) { y = box->y + box->height + box->padding[BOTTOM] + -- cgit v1.2.3