aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2010-06-06 22:08:15 +0000
committerIngo Schwarze <schwarze@openbsd.org>2010-06-06 22:08:15 +0000
commit10d8ff93badeca4aa0cdd78f26832996d7b3536c (patch)
tree95dbfe9248295d9a1901619e07d75e767c7feb26
parentdcd638814564be0dd5e62edd3f5b23a74cc9f7db (diff)
downloadmandoc-10d8ff93badeca4aa0cdd78f26832996d7b3536c.tar.gz
mandoc-10d8ff93badeca4aa0cdd78f26832996d7b3536c.tar.zst
mandoc-10d8ff93badeca4aa0cdd78f26832996d7b3536c.zip
Merge a fix to avoid a regression in OpenBSD:
Restore the blank line before .In in SYNOPSIS except right after .Sh or right after another .In. Even though Kristaps says SYNOPSIS blank-line handling is still very much work in progress and more is probably needed, this one is useful to keep in sync with OpenBSD. "fine" kristaps@
-rw-r--r--mdoc_term.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/mdoc_term.c b/mdoc_term.c
index a3226b83..e6be6214 100644
--- a/mdoc_term.c
+++ b/mdoc_term.c
@@ -1,4 +1,4 @@
-/* $Id: mdoc_term.c,v 1.141 2010/06/06 10:50:56 kristaps Exp $ */
+/* $Id: mdoc_term.c,v 1.142 2010/06/06 22:08:15 schwarze Exp $ */
/*
* Copyright (c) 2008, 2009 Kristaps Dzonsons <kristaps@kth.se>
*
@@ -1845,6 +1845,9 @@ static int
termp_in_pre(DECL_ARGS)
{
+ if (SEC_SYNOPSIS == n->sec && n->prev && MDOC_In != n->prev->tok)
+ term_vspace(p);
+
if (SEC_SYNOPSIS == n->sec && MDOC_LINE & n->flags) {
term_fontpush(p, TERMFONT_BOLD);
term_word(p, "#include");