diff options
author | Ingo Schwarze <schwarze@openbsd.org> | 2013-05-19 21:07:51 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@openbsd.org> | 2013-05-19 21:07:51 +0000 |
commit | 696927db0da847f12657d36e6c8081d708e8c73f (patch) | |
tree | 8e50d2bf72b43943af24cc2a17b7f63833a57e23 /mdoc_man.c | |
parent | ae06230fac2b15973cee3f4eb09a4f68a079d5dd (diff) | |
download | mandoc-696927db0da847f12657d36e6c8081d708e8c73f.tar.gz |
Move printing of the .RS macro into print_offs() such that print_offs()
takes care of printing the whole line. This reduces code duplication -
in particular after the upcoming commit to repair .Bl -offset -
and makes print_offs() more similar to what print_width() does.
No functional change.
Diffstat (limited to 'mdoc_man.c')
-rw-r--r-- | mdoc_man.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -408,6 +408,8 @@ print_offs(const char *v) struct roffsu su; size_t sz; + print_line(".RS", MMAN_Bk_susp); + /* Convert v into a number (of characters). */ if (NULL == v || '\0' == *v || 0 == strcmp(v, "left")) sz = 0; @@ -427,6 +429,7 @@ print_offs(const char *v) * in terms of different units. */ print_word(v); + outflags |= MMAN_nl; return; } } else @@ -441,6 +444,7 @@ print_offs(const char *v) snprintf(buf, sizeof(buf), "%ldn", sz); print_word(buf); + outflags |= MMAN_nl; } /* @@ -825,9 +829,7 @@ pre_bd(DECL_ARGS) print_line(".nf", 0); if (0 == n->norm->Bd.comp && NULL != n->parent->prev) outflags |= MMAN_sp; - print_line(".RS", MMAN_Bk_susp); print_offs(n->norm->Bd.offs); - outflags |= MMAN_nl; return(1); } @@ -981,9 +983,7 @@ static int pre_dl(DECL_ARGS) { - print_line(".RS", MMAN_Bk_susp); print_offs("6n"); - outflags |= MMAN_nl; return(1); } |