I'm preparing a bibliography for a journal and the request is to have Book Title (Publisher) for book, incollection, etc. I have the following code (MWE):
\documentclass{article}
\usepackage[natbib,maxbibnames=99,uniquename=false,uniquelist=false,useprefix=true,style=ext-authoryear,innamebeforetitle=true]{biblatex}
\usepackage{xpatch}
%% FORMATTING OF THE REFERENCES SECTION
% This starts from "authoryear" style, makes changes
% Comma instead of period to separate fields
\renewcommand{\newunitpunct}{\addcomma\space}
% Remove "pp."
\DeclareFieldFormat{pages}{#1}
% Remove quotes around title
\DeclareFieldFormat[article,unpublished,inbook,incollection]{title}{#1}
% Remove parentheses around year
\DeclareFieldFormat{biblabeldate}{#1}
\DeclareDelimFormat[bib]{nameyeardelim}{\addcomma\space}
% Remove "In: " for articles; "in" without colon for inbook/incollection
\renewbibmacro{in:}{%
\ifentrytype{article}
{}
{\setunit{\space}%
\printtext{%
\addcomma\addspace\bibstring{in}\addspace}}}
% Only output volume, no number
\renewbibmacro{volume+number+eid}{%
\ifentrytype{article}
{\printfield{volume}%
\setunit{\addcomma\space}%
\printfield{eid}}
{}}
% Put parentheses around publisher
\renewbibmacro{publisher+location+date}{%
\printtext[parens]{% ADDED
\printlist{location}%
\iflistundef{publisher}
{\setunit{\addcomma\space}}
{\setunit{\addcolon\space}}%
\printlist{publisher}%
\setunit*{\addcomma\space}%
\usebibmacro{date}%
}
\newunit}
% Colon after editors
\DeclareFieldFormat{editortype}{#1:}
% Remove comma after booktitle
\begin{filecontents}{\jobname.bib}
@incollection{AuthorA,
title = {A paper that didn't get published in a real journal},
publisher = {Publisher},
year = {2001},
author = {First Last},
booktitle = {Book Title},
editor = {Albert Editor and Bob Editor}
}
@Article{AuthorB,
author = {Author One and Author Two and Author Three},
title = {A paper that did},
journal = {Journal Name},
year = {2002},
volume = {99},
number = {9},
pages = {31--60},
}
@Unpublished{AuthorC,
Title = {A paper that didn't get published at all},
Author = {Author Three and Author One and Author Four and Author Five},
Note = {Working paper},
Year = {2003}
}
\end{filecontents}
\addbibresource{\jobname.bib}
\begin{document}
This is the story of \citet{AuthorA}, whose bibliography item had an extra comma after \emph{Book Title}, but also of \citet{AuthorB}, and of course of \citet{AuthorC}.
\printbibliography
\end{document}
This gives me the following result:

I would like to remove the comma between "Book Title" and "(Publisher)" in the first bibliography item. I've tried everything:
- I tried to redefine the booktitle macro (nothing happens)
- I tried the xpatch technique indicated here Biblatex Incollection: Comma after Booktitle (My latex error has the "failed" message provided in the code itself)
Please help!


biblatexorbiblatex-extdocumentation if you still have any doubts - or ask in the comments). Unfortunately, I don't understand your comment about\addspaceinside\newunitpunct. It is the default separator between "units of content" in the bibliography. As such it is almost always going to be either comma+space or period+space. But\newunitpunctdoes not apply in all places, sometimes more specific delimiters are available and used. – moewe Sep 28 '22 at 05:59