diff options
author | 2011-02-06 22:56:45 +0000 | |
---|---|---|
committer | 2011-02-06 22:56:45 +0000 | |
commit | cdf75aa10c19e757c8c8baa57ddea0bf29a8d5bf (patch) | |
tree | 6b128295f7004b13f1acf855d88a286d031e0dc0 /usr.bin/mandoc/mdoc_html.c | |
parent | Some pre-handlers produce output, so reorder the code to set up (diff) | |
download | wireguard-openbsd-cdf75aa10c19e757c8c8baa57ddea0bf29a8d5bf.tar.xz wireguard-openbsd-cdf75aa10c19e757c8c8baa57ddea0bf29a8d5bf.zip |
Do not break the line between the arguments of .Bsx .Dx .Fx .Nx .Ox .Ux.
Original patch from kristaps@, but i fixed a regression regarding .Bk.
Diffstat (limited to 'usr.bin/mandoc/mdoc_html.c')
-rw-r--r-- | usr.bin/mandoc/mdoc_html.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/usr.bin/mandoc/mdoc_html.c b/usr.bin/mandoc/mdoc_html.c index d57108e71a2..05f636d3008 100644 --- a/usr.bin/mandoc/mdoc_html.c +++ b/usr.bin/mandoc/mdoc_html.c @@ -1,4 +1,4 @@ -/* $Id: mdoc_html.c,v 1.51 2011/02/06 17:33:20 schwarze Exp $ */ +/* $Id: mdoc_html.c,v 1.52 2011/02/06 22:56:45 schwarze Exp $ */ /* * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv> * @@ -800,6 +800,7 @@ mdoc_xx_pre(MDOC_ARGS) { const char *pp; struct htmlpair tag; + int flags; switch (n->tok) { case (MDOC_Bsx): @@ -826,8 +827,15 @@ mdoc_xx_pre(MDOC_ARGS) PAIR_CLASS_INIT(&tag, "unix"); print_otag(h, TAG_SPAN, 1, &tag); + print_text(h, pp); - return(1); + if (n->child) { + flags = h->flags; + h->flags |= HTML_KEEP; + print_text(h, n->child->string); + h->flags = flags; + } + return(0); } |