diff options
author | Ingo Schwarze <schwarze@cvs.openbsd.org> | 2012-07-16 09:51:04 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@cvs.openbsd.org> | 2012-07-16 09:51:04 +0000 |
commit | ac56567a5861098d3cacce5483e87d459b1f1ecf (patch) | |
tree | fb5e1e9a41915d90c7dc678ffdbaadc6a1423367 /regress | |
parent | 1bffea6b9faacfe39ee86db21ec99b5f4b442d54 (diff) |
Several -mdoc parser improvements related to vertical spacing:
* So far, .Pp and .Lp were removed before paragraph type blocks.
* Now also remove .br before paragraph type blocks.
* Treat .Lp as a paragraph like .Pp, so remove .Pp, .Lp, .br before it.
* Do not treat .sp as a paragraph, don't remove anything before it.
* After .Sh, .Ss, .Pp, and .Lp, remove .Pp, .Lp, .sp, .br, and blank lines.
* After .sp and .br, remove .br.
Diffstat (limited to 'regress')
-rw-r--r-- | regress/usr.bin/mandoc/mdoc/blank/line.in | 18 | ||||
-rw-r--r-- | regress/usr.bin/mandoc/mdoc/blank/line.out_ascii | 18 |
2 files changed, 36 insertions, 0 deletions
diff --git a/regress/usr.bin/mandoc/mdoc/blank/line.in b/regress/usr.bin/mandoc/mdoc/blank/line.in index deef2ee13eb..3a163dfcec9 100644 --- a/regress/usr.bin/mandoc/mdoc/blank/line.in +++ b/regress/usr.bin/mandoc/mdoc/blank/line.in @@ -34,6 +34,9 @@ sp br: Pp sp: .Pp .sp +Pp sp 2v: +.Pp +.sp 2v sp Pp: .sp .Pp @@ -61,4 +64,19 @@ blank sp: Double blank: +Bd ragged sp 2v: +.Bd -ragged -offset 6n +.sp 2v +Ed sp 2v: +.Ed +.sp 2v +Bl tag sp 2v: +.Bl -tag -width 6n +.It tag +.sp 2v +El sp 2v +.El +Sh sp 2v: +.Sh CUSTOM +.sp 2v End. diff --git a/regress/usr.bin/mandoc/mdoc/blank/line.out_ascii b/regress/usr.bin/mandoc/mdoc/blank/line.out_ascii index c0761484e6c..43ca9ab4981 100644 --- a/regress/usr.bin/mandoc/mdoc/blank/line.out_ascii +++ b/regress/usr.bin/mandoc/mdoc/blank/line.out_ascii @@ -24,6 +24,8 @@ DDEESSCCRRIIPPTTIIOONN Pp sp: + Pp sp 2v: + sp Pp: @@ -48,6 +50,22 @@ DDEESSCCRRIIPPTTIIOONN Double blank: + Bd ragged sp 2v: + + + + Ed sp 2v: + + + Bl tag sp 2v: + + tag + + + El sp 2v + Sh sp 2v: + +CCUUSSTTOOMM End. OpenBSD February 17, 2010 OpenBSD |