aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/term.c
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2012-07-10 15:35:41 +0000
committerIngo Schwarze <schwarze@openbsd.org>2012-07-10 15:35:41 +0000
commitd37d4166a2cbe775074aef6e163c5d73be7ad9e8 (patch)
treedb420dcd06b2458b871c1af39f032d348164203c /term.c
parent93d3ffc3d342e3e9214ceb0ba55d157aa51d70b7 (diff)
downloadmandoc-d37d4166a2cbe775074aef6e163c5d73be7ad9e8.tar.gz
mandoc-d37d4166a2cbe775074aef6e163c5d73be7ad9e8.tar.zst
mandoc-d37d4166a2cbe775074aef6e163c5d73be7ad9e8.zip
Remove a hack that was intended for groff-1.15 bug compatibility:
When the width of a tag in .Bl -hang was exactly one character shorter than the maximum length that would fit, the following text would have a negative hang of one character (i.e., hang to the left). That bug is no longer present in groff-1.21, so relax mandoc, too. OpenBSD rev. 1.65
Diffstat (limited to 'term.c')
-rw-r--r--term.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/term.c b/term.c
index a10fce7a..26292b98 100644
--- a/term.c
+++ b/term.c
@@ -1,4 +1,4 @@
-/* $Id: term.c,v 1.203 2012/05/31 22:29:13 schwarze Exp $ */
+/* $Id: term.c,v 1.204 2012/07/10 15:35:41 schwarze Exp $ */
/*
* Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
* Copyright (c) 2010, 2011, 2012 Ingo Schwarze <schwarze@openbsd.org>
@@ -265,16 +265,11 @@ term_flushln(struct termp *p)
p->overstep = (int)(vis - maxvis + (*p->width)(p, ' '));
/*
- * Behave exactly the same way as groff:
* If we have overstepped the margin, temporarily move
* it to the right and flag the rest of the line to be
* shorter.
- * If we landed right at the margin, be happy.
- * If we are one step before the margin, temporarily
- * move it one step LEFT and flag the rest of the line
- * to be longer.
*/
- if (p->overstep < -1)
+ if (p->overstep < 0)
p->overstep = 0;
return;