aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/mdoc_html.c
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2010-10-10 09:59:48 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2010-10-10 09:59:48 +0000
commit9c1eaf47face65f05d12c1991f19a92789b433fc (patch)
tree5e6662f4f2d676183f8cab8033bc73492a798ec7 /mdoc_html.c
parent385a2d9a12f28a334c3d74170511b5200d6166f7 (diff)
downloadmandoc-9c1eaf47face65f05d12c1991f19a92789b433fc.tar.gz
mandoc-9c1eaf47face65f05d12c1991f19a92789b433fc.tar.zst
mandoc-9c1eaf47face65f05d12c1991f19a92789b433fc.zip
`Sm' no longer produces a linebreak when used in `Bd'.
Diffstat (limited to 'mdoc_html.c')
-rw-r--r--mdoc_html.c15
1 files changed, 13 insertions, 2 deletions
diff --git a/mdoc_html.c b/mdoc_html.c
index ef37781b..d16bd07a 100644
--- a/mdoc_html.c
+++ b/mdoc_html.c
@@ -1,4 +1,4 @@
-/* $Id: mdoc_html.c,v 1.110 2010/10/01 21:51:13 schwarze Exp $ */
+/* $Id: mdoc_html.c,v 1.111 2010/10/10 09:59:48 kristaps Exp $ */
/*
* Copyright (c) 2008, 2009, 2010 Kristaps Dzonsons <kristaps@bsd.lv>
*
@@ -1323,6 +1323,8 @@ mdoc_bd_pre(MDOC_ARGS)
* anyway, so don't sweat it.
*/
switch (nn->tok) {
+ case (MDOC_Sm):
+ /* FALLTHROUGH */
case (MDOC_br):
/* FALLTHROUGH */
case (MDOC_sp):
@@ -1603,7 +1605,16 @@ mdoc_sm_pre(MDOC_ARGS)
assert(n->child && MDOC_TEXT == n->child->type);
if (0 == strcmp("on", n->child->string)) {
- /* FIXME: no p->col to check... */
+ /*
+ * FIXME: no p->col to check. Thus, if we have
+ * .Bd -literal
+ * .Sm off
+ * 1 2
+ * .Sm on
+ * 3
+ * .Ed
+ * the "3" is preceded by a space.
+ */
h->flags &= ~HTML_NOSPACE;
h->flags &= ~HTML_NONOSPACE;
} else