=================================================================== RCS file: /cvs/mandoc/term.c,v retrieving revision 1.88 retrieving revision 1.90 diff -u -p -r1.88 -r1.90 --- mandoc/term.c 2009/07/16 12:34:06 1.88 +++ mandoc/term.c 2009/07/19 21:26:27 1.90 @@ -1,4 +1,4 @@ -/* $Id: term.c,v 1.88 2009/07/16 12:34:06 kristaps Exp $ */ +/* $Id: term.c,v 1.90 2009/07/19 21:26:27 kristaps Exp $ */ /* * Copyright (c) 2008, 2009 Kristaps Dzonsons * @@ -204,7 +204,10 @@ term_isopendelim(const char *p) * possible). * * FIXME: newline breaks occur (in groff) also occur when a single - * space follows a NOBREAK! + * space follows a NOBREAK (try `Bl -tag') + * + * FIXME: there's a newline error where a `Bl -diag' will have a + * trailing newline if the line is exactly 73 chars long. */ void term_flushln(struct termp *p) @@ -252,10 +255,10 @@ term_flushln(struct termp *p) /* LINTED */ for (j = i, vsz = 0; j < (int)p->col; j++) { - if (' ' == p->buf[j]) + if (' ' == p->buf[j]) break; else if (8 == p->buf[j]) - j += 1; + vsz--; else vsz++; } @@ -549,8 +552,8 @@ term_chara(struct termp *p, char c) static void term_encodea(struct termp *p, char c) { - - if (TERMP_STYLE & p->flags) { + + if (' ' != c && TERMP_STYLE & p->flags) { if (TERMP_BOLD & p->flags) { term_chara(p, c); term_chara(p, 8);