=================================================================== RCS file: /cvs/mandoc/man_html.c,v retrieving revision 1.14 retrieving revision 1.18 diff -u -p -r1.14 -r1.18 --- mandoc/man_html.c 2009/10/26 08:18:16 1.14 +++ mandoc/man_html.c 2009/11/10 12:03:30 1.18 @@ -1,4 +1,4 @@ -/* $Id: man_html.c,v 1.14 2009/10/26 08:18:16 kristaps Exp $ */ +/* $Id: man_html.c,v 1.18 2009/11/10 12:03:30 kristaps Exp $ */ /* * Copyright (c) 2008, 2009 Kristaps Dzonsons * @@ -18,7 +18,6 @@ #include #include -#include #include #include #include @@ -212,6 +211,9 @@ print_man_node(MAN_ARGS) default: if (mans[n->tok].post) (*mans[n->tok].post)(m, n, h); + + /* Reset metafont upon exit from macro. */ + h->metafont = 0; break; } } @@ -234,7 +236,7 @@ a2width(const struct man_node *n, struct roffsu *su) static int man_root_pre(MAN_ARGS) { - struct htmlpair tag[2]; + struct htmlpair tag[3]; struct tag *t, *tt; char b[BUFSIZ], title[BUFSIZ]; @@ -248,7 +250,9 @@ man_root_pre(MAN_ARGS) PAIR_CLASS_INIT(&tag[0], "header"); bufcat_style(h, "width", "100%"); PAIR_STYLE_INIT(&tag[1], h); - t = print_otag(h, TAG_TABLE, 2, tag); + PAIR_SUMMARY_INIT(&tag[2], "header"); + + t = print_otag(h, TAG_TABLE, 3, tag); tt = print_otag(h, TAG_TR, 0, NULL); bufinit(h); @@ -282,7 +286,7 @@ man_root_pre(MAN_ARGS) static void man_root_post(MAN_ARGS) { - struct htmlpair tag[2]; + struct htmlpair tag[3]; struct tag *t, *tt; char b[DATESIZ]; @@ -291,7 +295,9 @@ man_root_post(MAN_ARGS) PAIR_CLASS_INIT(&tag[0], "footer"); bufcat_style(h, "width", "100%"); PAIR_STYLE_INIT(&tag[1], h); - t = print_otag(h, TAG_TABLE, 2, tag); + PAIR_SUMMARY_INIT(&tag[2], "footer"); + + t = print_otag(h, TAG_TABLE, 3, tag); tt = print_otag(h, TAG_TR, 0, NULL); bufinit(h); @@ -330,6 +336,9 @@ man_br_pre(MAN_ARGS) bufcat_su(h, "height", &su); PAIR_STYLE_INIT(&tag, h); print_otag(h, TAG_DIV, 1, &tag); + /* So the div isn't empty: */ + print_text(h, "\\~"); + return(0); }