summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--html.c12
-rw-r--r--mdoc_term.c2
2 files changed, 10 insertions, 4 deletions
diff --git a/html.c b/html.c
index f46a714e..8f215d84 100644
--- a/html.c
+++ b/html.c
@@ -2168,13 +2168,19 @@ mdoc_sp_pre(MDOC_ARGS)
int len;
struct htmlpair tag;
- if (MDOC_sp == n->tok)
+ switch (n->tok) {
+ case (MDOC_sp):
len = n->child ? atoi(n->child->string) : 1;
- else
+ break;
+ case (MDOC_br):
+ len = 0;
+ break;
+ default:
len = 1;
+ break;
+ }
buffmt("height: %dem", len);
-
tag.key = ATTR_STYLE;
tag.val = buf;
print_otag(h, TAG_DIV, 1, &tag);
diff --git a/mdoc_term.c b/mdoc_term.c
index 5fc88bde..72ec9ec4 100644
--- a/mdoc_term.c
+++ b/mdoc_term.c
@@ -1866,7 +1866,7 @@ termp_sp_pre(DECL_ARGS)
{
int i, len;
- switch (node->type) {
+ switch (node->tok) {
case (MDOC_sp):
len = node->child ? atoi(node->child->string) : 1;
break;