summaryrefslogtreecommitdiffstats
path: root/regress/roff/cond/close.in
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2018-11-26 17:44:34 +0000
committerIngo Schwarze <schwarze@openbsd.org>2018-11-26 17:44:34 +0000
commit5179a6f85473d6533f50f28255252719ec60009d (patch)
treec237d1b99e4a76f72e7fb836cda539820bf3c6b9 /regress/roff/cond/close.in
parentb7bfc264a560e768bb85e6c8d26e33d5c6ebe27e (diff)
downloadmandoc-5179a6f85473d6533f50f28255252719ec60009d.tar.gz
When a conditional block is closed by putting "\}" on a text line
by itself (which is somewhat unusual but not invalid; most authors use the empty macro line ".\}" instead), agree more closely with groff and do not produce a double space in the output. Quirk reported by millert@. While here, tweak the rest of the function body of roff_cond_text() to more closely match roff_cond_sub(). The subtly different handling could make people (including myself) wonder whether there is any point in being different. Testing shows there is not.
Diffstat (limited to 'regress/roff/cond/close.in')
-rw-r--r--regress/roff/cond/close.in18
1 files changed, 17 insertions, 1 deletions
diff --git a/regress/roff/cond/close.in b/regress/roff/cond/close.in
index 6bdf3781..74b402c8 100644
--- a/regress/roff/cond/close.in
+++ b/regress/roff/cond/close.in
@@ -1,5 +1,5 @@
.\" $OpenBSD: close.in,v 1.3 2017/07/04 14:53:26 schwarze Exp $
-.TH COND-CLOSE 1 2013-06-27
+.TH COND-CLOSE 1 "November 26, 2018"
.SH NAME
cond-close \- closing conditional macros
.SH DESCRIPTION
@@ -12,5 +12,21 @@ closing after an ignored macro
.if t \{text \}
closing after plain text
.PP
+.if n \{conditional content \} following words with whitespace
+.PP
+.if n \{conditional content\}following words without whitespace
+.PP
+preceding words
+.if n \{\
+standard multi-line style
+.\}
+following words
+.PP
+preceding words
+.if n \{
+non-standard multi-line style
+\}
+following words
+.PP
.if n \{
still open at the end of the file