4

I am trying to mimick the "done-by-hand" reference style my friend used in his PhD thesis and I have decided that backreferences may be a nice finishing touch.

Unfortunately, as this is philology, there are some multi-volume collected works for some authors, which are cited per-volume, but bibliography has the whole collection only.

To the point. When compiled, the file:

\documentclass{article}

\usepackage[backend=biber,style=verbose-trad2,backref]{biblatex}
\usepackage{filecontents}

\begin{filecontents}{test.bib}

@mvbook{AuthorAll,
    author = {Prolific Author},
    volumes = {1--1000},
    title = {Collected Works},
    editor = {Tireless Editor}
}

@book{Author1,
    crossref = {AuthorAll},
    title = {Collected Works. Vol.~1. Poems part 1},
    options = {skipbib=true}
}

@book{Author2,
    crossref = {AuthorAll},
    title = {Collected Works. Vol.~2. Poems part 2},
    options = {skipbib=true}
}

@book{Author3,
    crossref = {AuthorAll},
    title = {Collected Works. Vol.~3. Poems part 3},
    options = {skipbib=true}
}
and so on...
\end{filecontents}

\addbibresource{test.bib}

\begin{document}

\cite[11]{Author1}\clearpage

\cite[22]{Author2}\clearpage

\cite[33]{Author3}\clearpage

\printbibliography
\end{document}

will give you a References list that has just one item, the one corresponding to AuthorAll. Is it possible for this item to refer back to all the citations made to the items Author1, Author2, Author3 (in this case to pages 1--3)?

4

An easy solution is to cite AuthorAll exclusively with \volcite and friends. These citation commands have a mandatory argument for the volume number:

\volcite[<prenote>]{<volume number>}[<pages>]{<key>}

This generates the same output as \cite, but the postnote <pages> is preceded by the text <volume string> <volume number>. Similar results hold for \pvolcite and \parencite, \tvolcite and \textcite, etc.

Alternatively you can use the \AtEveryCitekey hook and some internals to generate backreferences for cross-referenced entries.

\documentclass{article}
\usepackage[backend=biber,style=verbose-trad2,backref]{biblatex}
\usepackage[colorlinks]{hyperref}

\makeatletter
\AtEveryCitekey{%
  \ifboolexpr{
    test {\iftoggle{blx@skipbib}}
    and
    not test {\iffieldundef{crossref}}
  }
    {\blx@backref{\thefield{crossref}}}
    {}}
\makeatother

\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@mvbook{AuthorAll,
    author = {Prolific Author},
    volumes = {1--1000},
    title = {Collected Works},
    editor = {Tireless Editor}}
@book{Author1,
    crossref = {AuthorAll},
    title = {Collected Works. Vol.~1. Poems part 1},
    options = {skipbib=true}}
@book{Author2,
    crossref = {AuthorAll},
    title = {Collected Works. Vol.~2. Poems part 2},
    options = {skipbib=true}}
@book{Author3,
    crossref = {AuthorAll},
    title = {Collected Works. Vol.~3. Poems part 3},
    options = {skipbib=true}}
\end{filecontents}
\addbibresource{\jobname.bib}

\begin{document}
\volcite{1}[11]{AuthorAll}\clearpage
\cite[11]{Author1}\clearpage
\cite[22]{Author2}\clearpage
\cite[33]{Author3}\clearpage
\printbibliography
\end{document}

enter image description here

  • I didn't know about \volcite, but this wouldn't work as I have different titles for the volumes (real-life example I might add). But \AtEveryCitekey seems promising. – Michał Goliński Jul 9 '13 at 15:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.