2

When using biblatex-chicago, if you change the \postnotedelim with a command like

\renewcommand*{\postnotedelim}{\addcolon\space}

and compile on Overleaf using TeX Live 2021, things don't turn out too well. Compiling the same code on TeX Live 2020 or previous works great.

Consider the following MWE:

\documentclass{article}

\usepackage[authordate]{biblatex-chicago}
\usepackage{filecontents}

\begin{filecontents}{\jobname.bib}
@book{Jones2016,
    author = {Jones, John},
    title = {Title},
    date = {2016},
}

@book{Smith2018,
    author = {Smith, Sam},
    title = {Title},
    date = {2018},
}
\end{filecontents}

\addbibresource{\jobname.bib}

\renewcommand*{\postnotedelim}{\addcolon\space}

\begin{document}

\textcite[9]{Jones2016} discusses cool things. 
Some have commented that he's the best \autocite[40]{Smith2018}. 
But later in his work, Jones really goes off the rails \autocite[100]{Jones2016}. 
And by the end of the book, he's talking complete nonsense \autocite[500]{Jones2016}

\end{document}

In TeX Live 2020, everything works as expected: Image of MWE as compiled with TeX Live 2020 on Overleaf

However, this is what comes out when compiling with TeX Live 2021:

Image of MWE as compiled with TeX Live 2021 on Overleaf

The standard first-mention \autocite command works fine with a postnote, but \textcite renders as Jones (2016: ), 9, and \autocite commands with a postnote that immediately follow a citation of the same work print the postnote delimiter before the page numbers in the parenthetical, instead of printing the page number in parentheses without the delimiter. Note that everything looks as expected with \renewcommand*{\postnotedelim}{\addcolon\addspace} commented out, regardless of which version of TeX Live I compile with:

Image of output with the renewcommand line commented out. Everything looks as expected.

I don't mind compiling with the 2020 edition of TeX Live, but is there a new "right way" of declaring a global \postnotedelim for biblatex-chicago on newer distributions of TeX Live and/or biblatex-chicago?

2 Answers 2

4

The actual definition of \postnotedelim for authordate in a current version of biblatex-chicago is a bit more complex than the simple \DeclareDelimFormat{postnotedelim}{\addcomma\space} in core biblatex. chicago-dates-common.cbx has

\renewcommand*{\postnotedelim}{% Cf. N&B style
  \ifboolexpr{%
    test {\ifciteibid}%
    and
    (
    test {\ifentrytype{jurisdiction}}%
    or
    test {\ifentrytype{legal}}%
    or
    test {\ifentrytype{legislation}}%
    )
  }%
  {\addspace}%
  {\iftoggle{cms@inlineibid}%
    {\togglefalse{cms@inlineibid}%
      \iffieldundef{prenote}% Bug fix
      {}%
      {\setunit{\cms@testspace}}}%
    {\iffieldequalstr{entrysubtype}{classical}% For Notes+Bib, too?
      {\DeclareNumChars*{abcdeABCDE:}%
        \iffieldpages{postnote}%
        {\setunit{\cms@testspace}}%
        {\newcunit}}%
      {\newcunit}\DeclareNumChars{.}}}}

where \newcunit is essentially \setunit{\addcomma\space}. So if we want colons, we need to replace the \newcunit by \setunit{\addcolon\space}.

\documentclass{article}

\usepackage[authordate]{biblatex-chicago}

\addbibresource{biblatex-examples.bib}

\makeatletter
\renewcommand*{\postnotedelim}{% Cf. N&B style
  \ifboolexpr{%
    test {\ifciteibid}%
    and
    (
    test {\ifentrytype{jurisdiction}}%
    or
    test {\ifentrytype{legal}}%
    or
    test {\ifentrytype{legislation}}%
    )
  }%
  {\addspace}%
  {\iftoggle{cms@inlineibid}%
    {\togglefalse{cms@inlineibid}%
      \iffieldundef{prenote}% Bug fix
      {}%
      {\setunit{\cms@testspace}}}%
    {\iffieldequalstr{entrysubtype}{classical}% For Notes+Bib, too?
      {\DeclareNumChars*{abcdeABCDE:}%
        \iffieldpages{postnote}%
        {\setunit{\cms@testspace}}%
        {\setunit{\addcolon\space}}}%
      {\setunit{\addcolon\space}}\DeclareNumChars{.}}}}
\makeatother

\begin{document}

\textcite[9]{sigfridsson} discusses cool things. 
Some have commented that he's the best \autocite[40]{worman}. 
But later in his work, Jones really goes off the rails \autocite[100]{sigfridsson}. 
And by the end of the book, he's talking complete nonsense \autocite[500]{sigfridsson}

\end{document}

Sigfridsson and Ryde (1998: 9) discusses cool things. Some have commented that he’s the best (Worman 2002: 40). But later in his work, Jones really goes off the rails (Sigfridsson and Ryde 1998: 100). And by the end of the book, he’s talking complete nonsense (500)

1
  • Thanks so much for pointing me in the right direction. This clears up a lot.
    – drewx0r
    Commented Apr 9, 2022 at 1:41
2

Looking at the chicago-dates-common.cbx file that moewe's answer mentions and the \newcunit command in particular, it appears that the text component of \newcunit is defined by \newcunitpunct:

\protected\def\blx@newcunit{%
  \iftoggle{blx@keepunit}%
  {}%
  {\global\let\blx@unitpunct\newcunitpunct
    \global\toggletrue{blx@unit}}}%

\appto\blx@blxinit{%
  \let\newcunit\blx@newcunit}%

\newcommand*{\newcunitpunct}{\addcomma\space}

Adding \renewcommand*{\newcunitpunct}{\addcolon\space} to my preamble did exactly what I wanted.

Thanks again to moewe for pointing me to the appropriate file and the appropriate variable for me to get where I wanted to be.

Update: The above solution has unintended consequences (as @moewe correctly suggested it would), so my ultimate solution was basically to implement @moewe's answer with regexpatch just so it takes up fewer lines (though it probably introduces unnecessary complexity). I've put it here just for completeness's sake, but @moewe's answer seems to be the right way to do it.

\usepackage{regexpatch}

\makeatletter
\xpatchcmd*{\postnotedelim}{\newcunit }{\setunit{\addcolon \addspace} }{}{}
\makeatother

(Note that because there are two instances of \newcunit in the command, the starred version of \xpatchcmd replaces both occurrences of \newcunit.)

I'll mark @moewe's answer as correct, since it doesn't rely on any other packages, but just an explicit redefinition.

2
  • 2
    Note that \newcunit is used in many places in biblatex-chicago (especially in the bibliography style, the authordate cite style doesn't use it that often), so making it produce colons may have unintended side effects.
    – moewe
    Commented Apr 9, 2022 at 5:01
  • @moewe You're right. It definitely changes some commas to colons in the bibliography itself. I was hoping for an easy, memorable solution, but yours seems to do the trick and avoid any incorrect redefining of variables.
    – drewx0r
    Commented Apr 9, 2022 at 17:32

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .