summaryrefslogtreecommitdiff
path: root/riscos/htmlredraw.c
diff options
context:
space:
mode:
authorJohn Mark Bell <jmb@netsurf-browser.org>2003-10-19 17:17:26 +0000
committerJohn Mark Bell <jmb@netsurf-browser.org>2003-10-19 17:17:26 +0000
commit9fd638f098b36399e3ca7c90df3c283ab07ed08e (patch)
tree1fca47335dcec3bb1b4acc4f1ab13b4b22932a4c /riscos/htmlredraw.c
parent6f33e2d42e8cbcc539ac34e5e696ac127f72e4e3 (diff)
downloadnetsurf-9fd638f098b36399e3ca7c90df3c283ab07ed08e.tar.gz
netsurf-9fd638f098b36399e3ca7c90df3c283ab07ed08e.tar.bz2
[project @ 2003-10-19 17:17:26 by jmb]
Make text-decoration span child elements. Add text-decoration to css_dump() svn path=/import/netsurf/; revision=371
Diffstat (limited to 'riscos/htmlredraw.c')
-rw-r--r--riscos/htmlredraw.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/riscos/htmlredraw.c b/riscos/htmlredraw.c
index f9569ea95..83e7b4009 100644
--- a/riscos/htmlredraw.c
+++ b/riscos/htmlredraw.c
@@ -283,14 +283,15 @@ void html_redraw_box(struct content *content, struct box * box,
colourtrans_set_font_colours(box->font->handle, current_background_color << 8,
box->style->color << 8, 14, 0, 0, 0);
+
if (box->style->text_decoration == CSS_TEXT_DECORATION_NONE ||
box->style->text_decoration == CSS_TEXT_DECORATION_BLINK) {
- font_paint(box->font->handle, box->text,
- font_OS_UNITS | font_GIVEN_FONT | font_KERN | font_GIVEN_LENGTH,
- x, y - (int) (box->height * 1.5),
- NULL, NULL, (int) box->length);
+ font_paint(box->font->handle, box->text,
+ font_OS_UNITS | font_GIVEN_FONT | font_KERN | font_GIVEN_LENGTH,
+ x, y - (int) (box->height * 1.5),
+ NULL, NULL, (int) box->length);
}
- if (box->style->text_decoration == CSS_TEXT_DECORATION_UNDERLINE) {
+ if (box->style->text_decoration == CSS_TEXT_DECORATION_UNDERLINE || (box->parent->parent->style->text_decoration == CSS_TEXT_DECORATION_UNDERLINE && box->parent->parent->type == BOX_BLOCK)) {
char ulctrl[3];
char *temp = xcalloc(strlen(box->text)+4,
sizeof(char));
@@ -303,7 +304,7 @@ void html_redraw_box(struct content *content, struct box * box,
NULL, NULL, (int) box->length + 3);
xfree(temp);
}
- if (box->style->text_decoration == CSS_TEXT_DECORATION_LINE_THROUGH){
+ if (box->style->text_decoration == CSS_TEXT_DECORATION_LINE_THROUGH || (box->parent->parent->style->text_decoration == CSS_TEXT_DECORATION_LINE_THROUGH && box->parent->parent->type == BOX_BLOCK)) {
char ulctrl[3];
char *temp = xcalloc(strlen(box->text)+4,
sizeof(char));
@@ -316,7 +317,7 @@ void html_redraw_box(struct content *content, struct box * box,
NULL, NULL, (int) box->length + 3);
xfree(temp);
}
- if (box->style->text_decoration == CSS_TEXT_DECORATION_OVERLINE) {
+ if (box->style->text_decoration == CSS_TEXT_DECORATION_OVERLINE || (box->parent->parent->style->text_decoration == CSS_TEXT_DECORATION_OVERLINE && box->parent->parent->type == BOX_BLOCK)) {
char ulctrl[3];
char *temp = xcalloc(strlen(box->text)+4,
sizeof(char));