From 9f799cd86ee155f8a68ca12df0680abc439744a5 Mon Sep 17 00:00:00 2001 From: Matthew Flatt Date: Thu, 2 Nov 2017 08:54:55 -0600 Subject: [PATCH] scriblib/autbib: fix the "." in "al." Make the "." in "al." an abbreviation-ending period, instead of a sentence-ending period. --- scribble-lib/scriblib/autobib.rkt | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/scribble-lib/scriblib/autobib.rkt b/scribble-lib/scriblib/autobib.rkt index 33a6ba41..dc812f3b 100644 --- a/scribble-lib/scriblib/autobib.rkt +++ b/scribble-lib/scriblib/autobib.rkt @@ -264,8 +264,8 @@ [(datestring (author-element-cite (extract-bib-author a))) + (content->string (author-element-cite (extract-bib-author b)))) (auto-bib-date a) (auto-bib-date b) (date=? a b))) @@ -593,8 +593,8 @@ (make-other-author-element #f (list "Alia") - "al." - "al.")) + (list "al" ._) + (list "al" ._))) (define (authors name . names*) (define names (map parse-author (cons name names*))) @@ -603,11 +603,12 @@ (case (length names) [(1) (author-element-cite (car names))] [(2) (if (other-author-element? (cadr names)) - (format "~a et al." (author-element-cite (car names))) - (format "~a and ~a" - (author-element-cite (car names)) - (author-element-cite (cadr names))))] - [else (format "~a et al." (author-element-cite (car names)))])) + (list (author-element-cite (car names)) " et al" @._) + (list + (author-element-cite (car names)) + " and " + (author-element-cite (cadr names))))] + [else (list (author-element-cite (car names)) " et al" ._)])) (make-author-element #f (let loop ([names names] [prefix 0]) @@ -615,10 +616,10 @@ (case prefix [(0) names] [(1) (if (other-author-element? (car names)) - (list " et al.") + (list " et al" ._) (list " and " (car names)))] [else (if (other-author-element? (car names)) - (list ", et al.") + (list ", et al" ._) (list ", and " (car names)))])] [else (case prefix