8

I'm trying to cite a chapter from a book using biblatex:

@inbook{ , 
  crossref{X}
}   
@book{X,
}.

This produces a citation in this layout:

    Authors. Title. [...] In: Title. Authors. [...]

I need to swap the Title and Authors in the "In:" reference, i.e. to get

    Authors. Title. [...] In: Authors. Title. [...]

Any idea? Thanks.

1 Answer 1

10

The solution depends on the bibliography style you're using. If it is based on the standard style standard.bbx, the relevant part of the @inbook driver is:

\usebibmacro{in:}%
\usebibmacro{bybookauthor}%
\newunit\newblock
\usebibmacro{maintitle+booktitle}%
\newunit\newblock
\usebibmacro{byeditor+others}%

For @incollection and @inproceedings:

\usebibmacro{in:}%
\usebibmacro{maintitle+booktitle}%
\newunit\newblock
\usebibmacro{byeditor+others}%

and

\usebibmacro{in:}%
\usebibmacro{maintitle+booktitle}%
\newunit\newblock
\usebibmacro{event+venue+date}%
\newunit\newblock
\usebibmacro{byeditor+others}%

The bibliography macros bybookauthor and byeditor+others are defined in biblatex.def.

To change the order of the title and name list after in:, you could redefine each of these drivers and use variants of bybookauthor and byeditor+others to suppress the "by" strings.

Alternatively you can redefine the in: macro to print and clear the name list. This approach has been previously applied for the byeditor case. Here's an example addressing the name list printed by either byeditor+others or bybookauthor.

\documentclass{article}
\usepackage{biblatex}

\renewbibmacro*{in:}{%
  \printtext{\bibstring{in}\intitlepunct}%
  \ifnameundef{bookauthor}
    {\ifnameundef{editor}
       {\printnames{translator}%
        \setunit{\addcomma\space}%
        \usebibmacro{translator+othersstrg}%
        \clearname{translator}}
       {\printnames{editor}%
        \setunit{\addcomma\space}%
        \usebibmacro{editor+othersstrg}%
        \clearname{editor}}}
    {\ifnamesequal{author}{bookauthor}
       {}
       {\printnames{bookauthor}%
        \clearname{bookauthor}}}%
  \newunit\newblock}

\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@inbook{inbook,
  crossref = {book},
  author = {Smith, John},
  title = {Inbook Title}}
@book{book,
  author = {Doe, John and Brown, Bob},
  title = {Book Title}}
@incollection{incollection,
  crossref = {collection},
  author = {Smith, John},
  title = {Incollection Title}}
@collection{collection,
  editor = {Doe, John and Brown, Bob},
  translator = {Smith, Jane},
  title = {Collection Title}}
\end{filecontents}
\addbibresource{\jobname.bib}

\begin{document}
\nocite{inbook,incollection}
\printbibliography
\end{document}

enter image description here

2
  • 3
    As similar questions are asked rather frequently, please consider to incoroarate your answer code into a new package option (e.g. editorbeforetitle, default false) that solves this for all standard styles.
    – lockstep
    Jul 3, 2013 at 16:01
  • @lockstep I am not sure about that as there are many package options already. Regarding this "in title" business I'd sooner omit in: from the @article driver. But please feel free to submit feature requests at github. It'd be good to get your feedback on style improvements.
    – Audrey
    Jul 6, 2013 at 2:31

You must log in to answer this question.

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