summaryrefslogtreecommitdiff
path: root/regress
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@cvs.openbsd.org>2015-09-21 13:24:33 +0000
committerIngo Schwarze <schwarze@cvs.openbsd.org>2015-09-21 13:24:33 +0000
commit24e7c4dd68d9ca4296f6378c13a951b1f8d678ad (patch)
tree13251ed089f7f1892faf79464ed9a052b9b8b25c /regress
parent4ce184f4ebd312a3ec83ee56669a42e8ece086c9 (diff)
Trailing whitespace is significant when determining the width of a tag
in mdoc(7) .Bl -tag and man(7) .TP, but not in man(7) .IP. Quirk reported by Jan Stary <hans at stare dot cz> on ports@.
Diffstat (limited to 'regress')
-rw-r--r--regress/usr.bin/mandoc/man/IP/spacing.in14
-rw-r--r--regress/usr.bin/mandoc/man/IP/spacing.out_ascii14
-rw-r--r--regress/usr.bin/mandoc/man/TP/Makefile4
-rw-r--r--regress/usr.bin/mandoc/man/TP/spacing.in42
-rw-r--r--regress/usr.bin/mandoc/man/TP/spacing.out_ascii43
-rw-r--r--regress/usr.bin/mandoc/mdoc/Bl/tag.in18
-rw-r--r--regress/usr.bin/mandoc/mdoc/Bl/tag.out_ascii20
7 files changed, 141 insertions, 14 deletions
diff --git a/regress/usr.bin/mandoc/man/IP/spacing.in b/regress/usr.bin/mandoc/man/IP/spacing.in
index 02a92925f85..e1239b5b0b1 100644
--- a/regress/usr.bin/mandoc/man/IP/spacing.in
+++ b/regress/usr.bin/mandoc/man/IP/spacing.in
@@ -1,4 +1,4 @@
-.TH IP-SPACING 1 "February 5, 2011" OpenBSD
+.TH IP-SPACING 1 "September 21, 2015" OpenBSD
.SH NAME
IP-spacing \- spacing in indentend paragraphs
.SH DESCRIPTION
@@ -16,4 +16,16 @@ Indented text.
.IP "a much longer tag"
Indented text.
.LP
+Tags with trailing space:
+.IP "tag "
+Three plus one makes four.
+.IP "tag "
+Three plus two makes five.
+.IP "tag "
+Three plus three makes six.
+.IP "tag "
+Three plus four makes seven.
+.IP "tag "
+Three plus five makes eight.
+.LP
Normal text.
diff --git a/regress/usr.bin/mandoc/man/IP/spacing.out_ascii b/regress/usr.bin/mandoc/man/IP/spacing.out_ascii
index c9427446ec5..0aeb8291bc7 100644
--- a/regress/usr.bin/mandoc/man/IP/spacing.out_ascii
+++ b/regress/usr.bin/mandoc/man/IP/spacing.out_ascii
@@ -22,8 +22,20 @@ DDEESSCCRRIIPPTTIIOONN
a much longer tag
Indented text.
+ Tags with trailing space:
+
+ tag Three plus one makes four.
+
+ tag Three plus two makes five.
+
+ tag Three plus three makes six.
+
+ tag Three plus four makes seven.
+
+ tag Three plus five makes eight.
+
Normal text.
-OpenBSD February 5, 2011 IP-SPACING(1)
+OpenBSD September 21, 2015 IP-SPACING(1)
diff --git a/regress/usr.bin/mandoc/man/TP/Makefile b/regress/usr.bin/mandoc/man/TP/Makefile
index b6cbebd79ba..b867ba635a5 100644
--- a/regress/usr.bin/mandoc/man/TP/Makefile
+++ b/regress/usr.bin/mandoc/man/TP/Makefile
@@ -1,7 +1,7 @@
-# $OpenBSD: Makefile,v 1.11 2015/09/04 21:24:26 schwarze Exp $
+# $OpenBSD: Makefile,v 1.12 2015/09/21 13:24:32 schwarze Exp $
REGRESS_TARGETS = badarg broken double eof fill literal longhead
-REGRESS_TARGETS += macrotag manyargs sameline width
+REGRESS_TARGETS += macrotag manyargs sameline spacing width
LINT_TARGETS = broken double eof
diff --git a/regress/usr.bin/mandoc/man/TP/spacing.in b/regress/usr.bin/mandoc/man/TP/spacing.in
new file mode 100644
index 00000000000..71c788aa658
--- /dev/null
+++ b/regress/usr.bin/mandoc/man/TP/spacing.in
@@ -0,0 +1,42 @@
+.TH TP-SPACING 1 "September 21, 2015" OpenBSD
+.SH NAME
+TP-spacing \- spacing in tagged paragraphs
+.SH DESCRIPTION
+Normal text.
+.TP
+tag
+Indented text.
+.TP
+four
+Indented text.
+.TP
+ffive
+Indented text.
+.TP
+sixsix
+Indented text.
+.TP
+seseven
+Indented text.
+.TP
+a much longer tag
+Indented text.
+.LP
+Tags with trailing space:
+.TP
+tag\ \&
+Three plus one makes four.
+.TP
+tag\ \ \&
+Three plus two makes five.
+.TP
+tag\ \ \ \&
+Three plus three makes six.
+.TP
+tag\ \ \ \ \ \&
+Three plus four makes seven.
+.TP
+tag\ \ \ \ \ \ \&
+Three plus five makes eight.
+.LP
+Normal text.
diff --git a/regress/usr.bin/mandoc/man/TP/spacing.out_ascii b/regress/usr.bin/mandoc/man/TP/spacing.out_ascii
new file mode 100644
index 00000000000..247b25f903f
--- /dev/null
+++ b/regress/usr.bin/mandoc/man/TP/spacing.out_ascii
@@ -0,0 +1,43 @@
+TP-SPACING(1) General Commands Manual TP-SPACING(1)
+
+
+
+NNAAMMEE
+ TP-spacing - spacing in tagged paragraphs
+
+DDEESSCCRRIIPPTTIIOONN
+ Normal text.
+
+ tag Indented text.
+
+ four Indented text.
+
+ ffive Indented text.
+
+ sixsix Indented text.
+
+ seseven
+ Indented text.
+
+ a much longer tag
+ Indented text.
+
+ Tags with trailing space:
+
+ tag Three plus one makes four.
+
+ tag Three plus two makes five.
+
+ tag Three plus three makes six.
+
+ tag
+ Three plus four makes seven.
+
+ tag
+ Three plus five makes eight.
+
+ Normal text.
+
+
+
+OpenBSD September 21, 2015 TP-SPACING(1)
diff --git a/regress/usr.bin/mandoc/mdoc/Bl/tag.in b/regress/usr.bin/mandoc/mdoc/Bl/tag.in
index ee2d1b46d70..b5bfe8094cd 100644
--- a/regress/usr.bin/mandoc/mdoc/Bl/tag.in
+++ b/regress/usr.bin/mandoc/mdoc/Bl/tag.in
@@ -1,4 +1,4 @@
-.Dd December 25, 2014
+.Dd September 21, 2015
.Dt BL-TAG 1
.Os OpenBSD
.Sh NAME
@@ -86,13 +86,21 @@ text text
Trailing white space in the head:
.Bl -tag -width 5n
.It "a"
-b
+none
.It "a "
-b
+one
+.It "a "
+two
+.It "a "
+three
+.It "a "
+four
+.It "a "
+five
+.It "a "
+six
.It " "
white space only
-.It "a "
-b
.El
.Pp
Non-numeric width specification:
diff --git a/regress/usr.bin/mandoc/mdoc/Bl/tag.out_ascii b/regress/usr.bin/mandoc/mdoc/Bl/tag.out_ascii
index a112c5b8729..4280111e89e 100644
--- a/regress/usr.bin/mandoc/mdoc/Bl/tag.out_ascii
+++ b/regress/usr.bin/mandoc/mdoc/Bl/tag.out_ascii
@@ -76,13 +76,23 @@ DDEESSCCRRIIPPTTIIOONN
Trailing white space in the head:
- a b
+ a none
- a b
+ a one
- white space only
+ a two
+
+ a three
+
+ a four
- a b
+ a
+ five
+
+ a
+ six
+
+ white space only
Non-numeric width specification:
@@ -111,4 +121,4 @@ DDEESSCCRRIIPPTTIIOONN
second paragraph
-OpenBSD December 25, 2014 OpenBSD
+OpenBSD September 21, 2015 OpenBSD