diff options
author | James Bursa <james@netsurf-browser.org> | 2005-08-08 19:19:20 +0000 |
---|---|---|
committer | James Bursa <james@netsurf-browser.org> | 2005-08-08 19:19:20 +0000 |
commit | 7a981bb70a1f23fffe51b023add3322e8a59d716 (patch) | |
tree | be20bdf69cea03c3dc1a598190e60482d98c42df | |
parent | 6c597c302dd2a1d42b86fa4406a00fec4b7e6994 (diff) | |
download | netsurf-7a981bb70a1f23fffe51b023add3322e8a59d716.tar.gz netsurf-7a981bb70a1f23fffe51b023add3322e8a59d716.tar.bz2 |
[project @ 2005-08-08 19:19:20 by bursa]
Fix redraw of underlines and other text-decoration.
svn path=/import/netsurf/; revision=1845
-rw-r--r-- | render/layout.c | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/render/layout.c b/render/layout.c index 6e0f68835..6201098b2 100644 --- a/render/layout.c +++ b/render/layout.c @@ -2382,6 +2382,38 @@ void layout_calculate_descendant_bboxes(struct box *box) return; } + if (box->type == BOX_INLINE || box->type == BOX_TEXT) + return; + + if (box->type == BOX_INLINE_END) { + box = box->inline_end; + for (child = box->next; + child && child != box->inline_end; + child = child->next) { + if (child->type == BOX_FLOAT_LEFT || + child->type == BOX_FLOAT_RIGHT) + continue; + + if (child->x + child->descendant_x0 - box->x < + box->descendant_x0) + box->descendant_x0 = child->x + + child->descendant_x0 - box->x; + if (box->descendant_x1 < child->x + + child->descendant_x1 - box->x) + box->descendant_x1 = child->x + + child->descendant_x1 - box->x; + if (child->y + child->descendant_y0 - box->y < + box->descendant_y0) + box->descendant_y0 = child->y + + child->descendant_y0 - box->y; + if (box->descendant_y1 < child->y + + child->descendant_y1 - box->y) + box->descendant_y1 = child->y + + child->descendant_y1 - box->y; + } + return; + } + for (child = box->children; child; child = child->next) { if (child->type == BOX_FLOAT_LEFT || child->type == BOX_FLOAT_RIGHT) |