From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from localhost (fantadrom.bsd.lv [local]) by fantadrom.bsd.lv (OpenSMTPD) with ESMTPA id 144bbd95 for ; Wed, 23 Aug 2017 15:30:16 -0500 (EST) Date: Wed, 23 Aug 2017 15:30:15 -0500 (EST) Message-Id: <7509035958700419884.enqueue@fantadrom.bsd.lv> X-Mailinglist: mandoc-source Reply-To: source@mandoc.bsd.lv MIME-Version: 1.0 From: schwarze@mandoc.bsd.lv To: source@mandoc.bsd.lv Subject: mandoc: eliminate white space after opening and before closing X-Mailer: activitymail 1.26, http://search.cpan.org/dist/activitymail/ Content-Type: text/plain; charset=utf-8 Log Message: ----------- eliminate white space after opening and before closing punctuation Modified Files: -------------- mandoc: eqn_term.c mandoc/regress/eqn/fromto: precedence.out_ascii mandoc/regress/eqn/over: precedence.out_ascii mandoc/regress/eqn/subsup: precedence.out_ascii Revision Data ------------- Index: precedence.out_ascii =================================================================== RCS file: /home/cvs/mandoc/mandoc/regress/eqn/fromto/precedence.out_ascii,v retrieving revision 1.2 retrieving revision 1.3 diff -Lregress/eqn/fromto/precedence.out_ascii -Lregress/eqn/fromto/precedence.out_ascii -u -p -r1.2 -r1.3 --- regress/eqn/fromto/precedence.out_ascii +++ regress/eqn/fromto/precedence.out_ascii @@ -4,6 +4,6 @@ NNAAMMEE ssuubbssuupp--pprreecceeddeennccee - precedence of subscripts and superscripts DDEESSCCRRIIPPTTIIOONN - initial text _X_(_a_)^_c^ ; X_aa^_c ; (_X_1^2)_(_a__c^_e)^(_o__r^_s) final text + initial text _X_(_a_)^_c^; X_aa^_c; (_X_1^2)_(_a__c^_e)^(_o__r^_s) final text OpenBSD July 6, 2017 OpenBSD Index: eqn_term.c =================================================================== RCS file: /home/cvs/mandoc/mandoc/eqn_term.c,v retrieving revision 1.14 retrieving revision 1.15 diff -Leqn_term.c -Leqn_term.c -u -p -r1.14 -r1.15 --- eqn_term.c +++ eqn_term.c @@ -90,8 +90,14 @@ eqn_box(struct termp *p, const struct eq if (bp->font != EQNFONT_NONE) term_fontpush(p, fontmap[(int)bp->font]); - if (bp->text != NULL) + if (bp->text != NULL) { + if (strchr("!\"'),.:;?]}", *bp->text) != NULL) + p->flags |= TERMP_NOSPACE; term_word(p, bp->text); + if (*bp->text != '\0' && strchr("\"'([{", + bp->text[strlen(bp->text) - 1]) != NULL) + p->flags |= TERMP_NOSPACE; + } /* Special box types. */ Index: precedence.out_ascii =================================================================== RCS file: /home/cvs/mandoc/mandoc/regress/eqn/over/precedence.out_ascii,v retrieving revision 1.5 retrieving revision 1.6 diff -Lregress/eqn/over/precedence.out_ascii -Lregress/eqn/over/precedence.out_ascii -u -p -r1.5 -r1.6 --- regress/eqn/over/precedence.out_ascii +++ regress/eqn/over/precedence.out_ascii @@ -4,7 +4,7 @@ NNAAMMEE oovveerr--pprreecceeddeennccee - precedence of the fraction operator DDEESSCCRRIIPPTTIIOONN - initial text 1 + _x + (_x^2)/2 + (_x^3)/(2 * 3) ; _a^/_c~ ; aa/cc ; - sqrt(_a)/sqrt(_c) final text + initial text 1 + _x + (_x^2)/2 + (_x^3)/(2 * 3); _a^/_c~; aa/cc; sqrt(_a)/sqrt(_c) + final text OpenBSD July 6, 2017 OpenBSD Index: precedence.out_ascii =================================================================== RCS file: /home/cvs/mandoc/mandoc/regress/eqn/subsup/precedence.out_ascii,v retrieving revision 1.3 retrieving revision 1.4 diff -Lregress/eqn/subsup/precedence.out_ascii -Lregress/eqn/subsup/precedence.out_ascii -u -p -r1.3 -r1.4 --- regress/eqn/subsup/precedence.out_ascii +++ regress/eqn/subsup/precedence.out_ascii @@ -4,6 +4,6 @@ NNAAMMEE ssuubbssuupp--pprreecceeddeennccee - precedence of subscripts and superscripts DDEESSCCRRIIPPTTIIOONN - initial text (_x^)_(1_)^2- + (_e~)^((_x^)__s<->) ; I_II^_I + I^(II__I) final text + initial text (_x^)_(1_)^2- + (_e~)^((_x^)__s<->); I_II^_I + I^(II__I) final text OpenBSD July 6, 2017 OpenBSD -- To unsubscribe send an email to source+unsubscribe@mandoc.bsd.lv