# Enable “firstinits” in biblatex only for editors

biblatex has an option firstinits which will abbreviate first and middle names in the bibliography. Is there any way to limit this behavior for the editor field only, so that it doesn't abbreviate names in the author field?

In the example below, the author should appear as Lennon, John, but the editors should appear as P. McCartney, J. Lennon, G. Harrison, and R. Starkey.

\documentclass{article}
\usepackage[style = authoryear-comp, maxnames = 99]{biblatex}
\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@incollection{lennon1965,
AUTHOR = "John Lennon",
BOOKTITLE = "A book with articles",
EDITOR = "Paul McCartney and John Lennon and George Harrison and Richard Starkey",
TITLE = "This is my article in this book",
YEAR = "1965",
LOCATION = "Liverpool",
PAGES = "65--87",
PUBLISHER = "Cavern Club"}
\end{filecontents}
\begin{document}
\nocite{*}
\printbibliography
\end{document}


The name format used there is byeditor, so just go with

\DeclareNameAlias{byeditor}{first-last-inits}

\DeclareNameFormat{first-last-inits}{%
\usebibmacro{name:first-last}{#1}{#4}{#5}{#7}%
\usebibmacro{name:andothers}}


MWE

\documentclass{article}
\usepackage[style = authoryear-comp, maxnames = 99]{biblatex}
\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@incollection{lennon1965,
AUTHOR = "John Lennon",
BOOKTITLE = "A book with articles",
EDITOR = "Paul McCartney and John Lennon and George Harrison and Richard Starkey",
TITLE = "This is my article in this book",
YEAR = "1965",
LOCATION = "Liverpool",
PAGES = "65--87",
PUBLISHER = "Cavern Club"}
\end{filecontents}

\DeclareNameAlias{byeditor}{first-last-inits}

\DeclareNameFormat{first-last-inits}{%
\usebibmacro{name:first-last}{#1}{#4}{#5}{#7}%
\usebibmacro{name:andothers}}

\begin{document}
\nocite{*}
\printbibliography
\end{document}


• What I feared would happen did happen: This doesn't work together with your solution to tex.stackexchange.com/questions/173638/…. If put together, no abbreviations occur. – Sverre Apr 27 '14 at 13:36
• @Sverre It does: I have \DeclareNameAlias{editorin}{first-last} there, change that line to \DeclareNameAlias{editorin}{first-last-inits}. – moewe Apr 27 '14 at 13:39