diff options
author | Kristaps Dzonsons <kristaps@bsd.lv> | 2011-06-29 15:38:09 +0000 |
---|---|---|
committer | Kristaps Dzonsons <kristaps@bsd.lv> | 2011-06-29 15:38:09 +0000 |
commit | 2f53f5a989471121a5bf1f4a5c4d4a335b0f7fdb (patch) | |
tree | 3af6bd3a47d59ceeeec7573b2c6a92212f8db887 /man_term.c | |
parent | 9a1658910c9c2fa6e8b2d75172f98c96f3c99ba2 (diff) | |
download | mandoc-2f53f5a989471121a5bf1f4a5c4d4a335b0f7fdb.tar.gz mandoc-2f53f5a989471121a5bf1f4a5c4d4a335b0f7fdb.tar.zst mandoc-2f53f5a989471121a5bf1f4a5c4d4a335b0f7fdb.zip |
First fix how `sp 1' doesn't imply `1v' (it now does) and that 1
followed by non-digits, e.g. `1g', really means `1'. Next, fix some
spacing issues where `sp' was invoked in -man after sections or
subsections. Make sure this behaviour is mirrored in -Thtml.
Diffstat (limited to 'man_term.c')
-rw-r--r-- | man_term.c | 11 |
1 files changed, 9 insertions, 2 deletions
@@ -1,4 +1,4 @@ -/* $Id: man_term.c,v 1.111 2011/06/18 17:58:48 kristaps Exp $ */ +/* $Id: man_term.c,v 1.112 2011/06/29 15:38:09 kristaps Exp $ */ /* * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv> * Copyright (c) 2010, 2011 Ingo Schwarze <schwarze@openbsd.org> @@ -181,7 +181,7 @@ a2height(const struct termp *p, const char *cp) struct roffsu su; if ( ! a2roffsu(cp, &su, SCALE_VS)) - SCALE_VS_INIT(&su, term_strlen(p, cp)); + SCALE_VS_INIT(&su, atoi(cp)); return(term_vspan(p, &su)); } @@ -411,6 +411,13 @@ pre_sp(DECL_ARGS) { size_t i, len; + if ((NULL == n->prev && n->parent)) { + if (MAN_SS == n->parent->tok) + return(0); + if (MAN_SH == n->parent->tok) + return(0); + } + switch (n->tok) { case (MAN_br): len = 0; |