From 963c3766d55c38c35d322099fe30b674e1d31c69 Mon Sep 17 00:00:00 2001 From: John Mark Bell Date: Wed, 20 Oct 2004 23:31:32 +0000 Subject: [project @ 2004-10-20 23:31:31 by jmb] Reimplement draw groups svn path=/import/netsurf/; revision=1332 --- render/html_redraw.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'render/html_redraw.c') diff --git a/render/html_redraw.c b/render/html_redraw.c index 0b88e06d8..c77cf4f54 100644 --- a/render/html_redraw.c +++ b/render/html_redraw.c @@ -145,14 +145,19 @@ bool html_redraw_box(struct box *box, /* if visibility is hidden render children only */ if (box->style && box->style->visibility == CSS_VISIBILITY_HIDDEN) { + if (!plot.group_start("hidden box")) + return false; for (c = box->children; c; c = c->next) if (!html_redraw_box(c, x_scrolled, y_scrolled, x0, y0, x1, y1, scale, current_background_color)) return false; - return true; + return plot.group_end(); } + if (!plot.group_start("vis box")) + return false; + /* dotted debug outlines */ if (html_redraw_debug) { if (!plot.rectangle(x, y, padding_width, padding_height, @@ -184,7 +189,7 @@ bool html_redraw_box(struct box *box, /* return if the box is completely outside the clip rectangle */ if (clip_y1 < y0 || y1 < clip_y0 || clip_x1 < x0 || x1 < clip_x0) - return true; + return plot.group_end(); if (box->type == BOX_BLOCK || box->type == BOX_INLINE_BLOCK || box->type == BOX_TABLE_CELL || box->object) { @@ -350,7 +355,7 @@ bool html_redraw_box(struct box *box, if (!plot.clip(clip_x0, clip_y0, clip_x1, clip_y1)) return false; - return true; + return plot.group_end(); } -- cgit v1.2.3