-/* $OpenBSD: man_macro.c,v 1.110 2023/10/24 20:30:49 schwarze Exp $ */
+/* $OpenBSD: man_macro.c,v 1.111 2023/11/13 19:13:00 schwarze Exp $ */
/*
* Copyright (c) 2012-2015,2017-2020,2022 Ingo Schwarze <schwarze@openbsd.org>
* Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
if (tok == MAN_RS) {
if (roff_getreg(man->roff, "an-margin") == 0)
roff_setreg(man->roff, "an-margin",
- 7 * 24, '=');
+ 5 * 24, '=');
if ((head->aux = strtod(p, NULL) * 24.0) > 0)
roff_setreg(man->roff, "an-margin",
head->aux, '+');
-/* $OpenBSD: man_term.c,v 1.196 2023/10/24 20:30:49 schwarze Exp $ */
+/* $OpenBSD: man_term.c,v 1.197 2023/11/13 19:13:00 schwarze Exp $ */
/*
* Copyright (c) 2010-15,2017-20,2022-23 Ingo Schwarze <schwarze@openbsd.org>
* Copyright (c) 2008-2012 Kristaps Dzonsons <kristaps@bsd.lv>
struct mtermp mt;
struct termp *p;
struct roff_node *n, *nc, *nn;
- 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");
term_tab_set(p, ".5i");
memset(&mt, 0, sizeof(mt));
- mt.lmargin[mt.lmargincur] = term_len(p, p->defindent);
+ mt.lmargin[mt.lmargincur] = term_len(p, 7);
mt.offset = term_len(p, p->defindent);
mt.pardist = 1;
print_man_nodelist(p, &mt, n, man);
term_end(p);
}
- p->defindent = save_defindent;
}
/*
{
switch (n->type) {
case ROFFT_BLOCK:
- mt->lmargin[mt->lmargincur] = term_len(p, p->defindent);
+ mt->lmargin[mt->lmargincur] = term_len(p, 7);
print_bvspace(p, n, mt->pardist);
break;
case ROFFT_HEAD:
switch (n->type) {
case ROFFT_BLOCK:
- mt->lmargin[mt->lmargincur] = term_len(p, p->defindent);
+ mt->lmargin[mt->lmargincur] = term_len(p, 7);
mt->offset = term_len(p, p->defindent);
/*
switch (n->type) {
case ROFFT_BLOCK:
- mt->lmargin[mt->lmargincur] = term_len(p, p->defindent);
+ mt->lmargin[mt->lmargincur] = term_len(p, 7);
mt->offset = term_len(p, p->defindent);
/*
if (++mt->lmarginsz < MAXMARGINS)
mt->lmargincur = mt->lmarginsz;
- mt->lmargin[mt->lmargincur] = term_len(p, p->defindent);
+ mt->lmargin[mt->lmargincur] = term_len(p, 7);
return 1;
}
-.\" $OpenBSD: mandoc.1,v 1.192 2023/10/24 20:30:49 schwarze Exp $
+.\" $OpenBSD: mandoc.1,v 1.193 2023/11/13 19:13:00 schwarze Exp $
.\"
.\" Copyright (c) 2012, 2014-2023 Ingo Schwarze <schwarze@openbsd.org>
.\" Copyright (c) 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
-.Dd $Mdocdate: October 24 2023 $
+.Dd $Mdocdate: November 13 2023 $
.Dt MANDOC 1
.Os
.Sh NAME
.It Cm indent Ns = Ns Ar indent
The left margin for normal text is set to
.Ar indent
-blank characters instead of the default of five for
-.Xr mdoc 7
-and seven for
-.Xr man 7 .
+blank characters instead of the default of five.
Increasing this is not recommended; it may result in degraded formatting,
for example overfull lines or ugly line breaks.
When output is to a pager on a terminal that is less than 66 columns
.Xr mdoc 7
output style.
This prints the operating system name rather than the page title
-on the right side of the footer line, and it implies
-.Fl O Cm indent Ns =5 .
+on the right side of the footer line.
One useful application is for checking that
.Fl T Cm man
output formats in the same way as the
-/* $OpenBSD: mdoc_term.c,v 1.281 2022/09/11 09:12:47 schwarze Exp $ */
+/* $OpenBSD: mdoc_term.c,v 1.282 2023/11/13 19:13:00 schwarze Exp $ */
/*
* Copyright (c) 2010, 2012-2020, 2022 Ingo Schwarze <schwarze@openbsd.org>
* Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
{
struct roff_node *n, *nn;
struct termp *p;
- size_t save_defindent;
p = (struct termp *)arg;
p->tcol->rmargin = p->maxrmargin = p->defrmargin;
print_mdoc_nodelist(p, NULL, mdoc, n);
term_newln(p);
} else {
- save_defindent = p->defindent;
- if (p->defindent == 0)
- p->defindent = 5;
term_begin(p, print_mdoc_head, print_mdoc_foot, mdoc);
while (n != NULL &&
(n->type == ROFFT_COMMENT ||
print_mdoc_nodelist(p, NULL, mdoc, n);
}
term_end(p);
- p->defindent = save_defindent;
}
}
-/* $OpenBSD: term_ascii.c,v 1.54 2022/08/16 17:44:53 schwarze Exp $ */
+/* $OpenBSD: term_ascii.c,v 1.55 2023/11/13 19:13:00 schwarze Exp $ */
/*
* Copyright (c) 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
* Copyright (c) 2014,2015,2017,2018,2020 Ingo Schwarze <schwarze@openbsd.org>
p->maxtcol = 1;
p->line = 1;
+ p->defindent = 5;
p->defrmargin = p->lastrmargin = 78;
p->fontq = mandoc_reallocarray(NULL,
(p->fontsz = 8), sizeof(*p->fontq));
}
}
- if (outopts->mdoc) {
+ if (outopts->mdoc)
p->mdocstyle = 1;
- p->defindent = 5;
- }
if (outopts->indent)
p->defindent = outopts->indent;
if (outopts->width)