From f4f17f905b1f7d1c12baebca6f4c18362d71d80c Mon Sep 17 00:00:00 2001 From: James Bursa Date: Sun, 5 Nov 2006 12:58:24 +0000 Subject: More work on lists. Simplify the implementation to a BLOCK for display: list-item, with a marker box on box->list_marker. svn path=/trunk/netsurf/; revision=3031 --- render/box.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'render/box.c') diff --git a/render/box.c b/render/box.c index 4113120de..590b673a8 100644 --- a/render/box.c +++ b/render/box.c @@ -84,6 +84,7 @@ struct box * box_create(struct css_style *style, box->inline_end = NULL; box->float_children = NULL; box->next_float = NULL; + box->list_marker = NULL; box->col = NULL; box->gadget = NULL; box->usemap = NULL; @@ -495,10 +496,6 @@ void box_dump(struct box *box, unsigned int depth) case BOX_FLOAT_RIGHT: fprintf(stderr, "FLOAT_RIGHT "); break; case BOX_BR: fprintf(stderr, "BR "); break; case BOX_TEXT: fprintf(stderr, "TEXT "); break; - case BOX_LIST: fprintf(stderr, "LIST "); break; - case BOX_LIST_ITEM: fprintf(stderr, "LIST_ITEM "); break; - case BOX_LIST_MARKER: fprintf(stderr, "LIST_MARKER "); break; - case BOX_LIST_PRINCIPAL: fprintf(stderr, "LIST_PRINCIPAL "); break; default: fprintf(stderr, "Unknown box type "); } @@ -538,6 +535,13 @@ void box_dump(struct box *box, unsigned int depth) } fprintf(stderr, "\n"); + if (box->list_marker) { + for (i = 0; i != depth; i++) + fprintf(stderr, " "); + fprintf(stderr, "list_marker:\n"); + box_dump(box->list_marker, depth + 1); + } + for (c = box->children; c && c->next; c = c->next) ; if (box->last != c) -- cgit v1.2.3