From 12886a63affd2596f6df003f827e5ae36b4fc5fd Mon Sep 17 00:00:00 2001 From: Ingo Schwarze Date: Sun, 26 Sep 2010 18:23:55 +0000 Subject: no punctuation after .%* outside .Rs in .Rs, mark full stops after .%* as end of a sentence from kristaps@ --- usr.bin/mandoc/mdoc_term.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'usr.bin/mandoc/mdoc_term.c') diff --git a/usr.bin/mandoc/mdoc_term.c b/usr.bin/mandoc/mdoc_term.c index 04b2e8b0709..ef5c69491db 100644 --- a/usr.bin/mandoc/mdoc_term.c +++ b/usr.bin/mandoc/mdoc_term.c @@ -1,4 +1,4 @@ -/* $Id: mdoc_term.c,v 1.105 2010/09/23 20:39:13 schwarze Exp $ */ +/* $Id: mdoc_term.c,v 1.106 2010/09/26 18:23:54 schwarze Exp $ */ /* * Copyright (c) 2008, 2009, 2010 Kristaps Dzonsons * Copyright (c) 2010 Ingo Schwarze @@ -2126,8 +2126,14 @@ termp____post(DECL_ARGS) /* TODO: %U. */ - p->flags |= TERMP_NOSPACE; - term_word(p, n->next ? "," : "."); + if (NULL == n->parent || MDOC_Rs != n->parent->tok) + return; + + if (NULL == n->next) { + term_word(p, "."); + p->flags |= TERMP_SENTENCE; + } else + term_word(p, ","); } -- cgit v1.2.3