summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2017-06-17 01:27:05 +0000
committerIngo Schwarze <schwarze@openbsd.org>2017-06-17 01:27:05 +0000
commit559c18edcfbf60d30aedce9d3c81d132f3e77621 (patch)
tree9cad8c50ad5c8542e2c347d2afa821fe6289e6c8
parent867c61d7b14fadc354e0eb3ab21b8df4fc0fac56 (diff)
downloadmandoc-559c18edcfbf60d30aedce9d3c81d132f3e77621.tar.gz
properly set the default indentation
such that even pages without any .SH macros get it
-rw-r--r--man_term.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/man_term.c b/man_term.c
index 11431079..5f527721 100644
--- a/man_term.c
+++ b/man_term.c
@@ -141,6 +141,9 @@ terminal_man(void *arg, const struct roff_man *man)
size_t save_defindent;
p = (struct termp *)arg;
+ save_defindent = p->defindent;
+ if (p->synopsisonly == 0 && p->defindent == 0)
+ p->defindent = 7;
p->tcol->rmargin = p->maxrmargin = p->defrmargin;
term_tab_set(p, NULL);
term_tab_set(p, "T");
@@ -167,16 +170,13 @@ terminal_man(void *arg, const struct roff_man *man)
n = n->next;
}
} else {
- save_defindent = p->defindent;
- if (p->defindent == 0)
- p->defindent = 7;
term_begin(p, print_man_head, print_man_foot, &man->meta);
p->flags |= TERMP_NOSPACE;
if (n != NULL)
print_man_nodelist(p, &mt, n, &man->meta);
term_end(p);
- p->defindent = save_defindent;
}
+ p->defindent = save_defindent;
}
/*