aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/term.h
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2017-06-04 18:50:35 +0000
committerIngo Schwarze <schwarze@openbsd.org>2017-06-04 18:50:35 +0000
commitab795e726e781905db61f736dacb3fbb0e35a301 (patch)
tree00d8e7751848ecf740e79624193cbb0809dff465 /term.h
parentd019f1f6d4b986db56f6fa599968bc395d7ce072 (diff)
downloadmandoc-ab795e726e781905db61f736dacb3fbb0e35a301.tar.gz
mandoc-ab795e726e781905db61f736dacb3fbb0e35a301.tar.zst
mandoc-ab795e726e781905db61f736dacb3fbb0e35a301.zip
Make term_flushln() simpler and more robust:
Eliminate the "overstep" state variable. The information is already contained in "viscol". Minus 60 lines of code, no functional change intended.
Diffstat (limited to 'term.h')
-rw-r--r--term.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/term.h b/term.h
index 25600d42..ac5f5858 100644
--- a/term.h
+++ b/term.h
@@ -1,4 +1,4 @@
-/* $Id: term.h,v 1.121 2017/05/08 15:34:54 schwarze Exp $ */
+/* $Id: term.h,v 1.122 2017/06/04 18:50:35 schwarze Exp $ */
/*
* Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
* Copyright (c) 2011-2015, 2017 Ingo Schwarze <schwarze@openbsd.org>
@@ -67,7 +67,7 @@ struct termp {
size_t col; /* Bytes in buf. */
size_t viscol; /* Chars on current line. */
size_t trailspace; /* See termp_flushln(). */
- int overstep; /* See termp_flushln(). */
+ size_t minbl; /* Minimum blanks before next field. */
int ti; /* Temporary indent for one line. */
int skipvsp; /* Vertical space to skip. */
int flags;
@@ -82,8 +82,8 @@ struct termp {
#define TERMP_NOBREAK (1 << 8) /* See term_flushln(). */
#define TERMP_BRTRSP (1 << 9) /* See term_flushln(). */
#define TERMP_BRIND (1 << 10) /* See term_flushln(). */
-#define TERMP_DANGLE (1 << 11) /* See term_flushln(). */
-#define TERMP_HANG (1 << 12) /* See term_flushln(). */
+#define TERMP_HANG (1 << 11) /* See term_flushln(). */
+#define TERMP_NOPAD (1 << 12) /* See term_flushln(). */
#define TERMP_NOSPLIT (1 << 13) /* Do not break line before .An. */
#define TERMP_SPLIT (1 << 14) /* Break line before .An. */
#define TERMP_NONEWLINE (1 << 15) /* No line break in nofill mode. */