38

Is it possible to use biblatex with the Tufte document classes (tufte-handout and tufte-book). If so, what modifications should I make to my preamble or class wrapper in order to use biblatex?


I've tried the recommended patch in a simple example:

\documentclass[nobib]{tufte-handout}

\usepackage{hyphenat}
\usepackage[backend=bibtex, natbib=true, style=numeric]{biblatex}
\addbibresource{References.bib}
\renewcommand{\cite}[2][0pt]{\sidenote[][#1]{\fullcite{#2}}}

\begin{document}

This,\cite{Sarukkai:2005} should be a side note and this\cite{Sarukkai:2005} should too.

\printbibliography 

\end{document}

But I don't get the results I should be getting (note the missing second citation):

enter image description here

(I'm also not sure how to combine this with the modifications I've already made to support abbreviated citations after the first occurrence.)

orome
  • 10,459
  • There's some comments on this here: http://code.google.com/p/tufte-latex/issues/detail?id=60 – Alan Munn Feb 27 '12 at 05:02
  • @AlanMunn: I've added an example to show what happens when I do that. – orome Feb 27 '12 at 05:13
  • @raxacoricofallapatorius Are you using the revised tufte-common.def? The link to it on that page is broken. Here's another one. – Audrey Mar 02 '12 at 04:11
  • @Audrey: With that the processing hangs. – orome Mar 02 '12 at 16:09
  • 2
    @raxacoricofallapatorius Omit the redefinition of cite. I tried re-compiling the document here and the log is error-free. – Audrey Mar 02 '12 at 17:19
  • @Audrey: Thanks. If I replace the cite redefinition above with the one below I can get this MWE to work, using the 3.5.2 tufte-common.def (though with a biblatex warning about "Patching footnotes failed...Footnote detection will not work.") So I'm getting there, however when I try to adapt this to my workflow (LyX, following the LyX instructions for using biblatex) all I get is "naked" citekeys, as if the bibliography is not being built. – orome Mar 02 '12 at 19:05
  • @raxacoricofallapatorius You'll often get the footnote warning with packages that alter internal footnote commands. It's just saying that the biblatex test \iffootnote might not work as intended. I have no experience with LyX, so I can't help with your other issue. – Audrey Mar 02 '12 at 19:25
  • @Audry: Ah! The problem with LyX is just that it is not finding the .bib file at all (because of a path specification problem) and silently failing. – orome Mar 02 '12 at 19:33

1 Answers1

33

Rather than redefining the \cite command, I would use biblatex’s ability to let every citation go into a footnote (option autocite=footnote) which then will go into a sidenote (since tufte-latex uses the normal \footnote command for sidenotes). The following works for me with the tufte-common.def 3.5.2 from the tufte-latex svn repository. To override the original def file, just save the revised one as $TEXMFHOME/tex/latex/tufte-latex/tufte-common.def, where $TEXMFHOME is the path returned by kpsewhich -var-value TEXMFHOME.

\documentclass[nobib]{tufte-handout}

\usepackage{hyphenat} \usepackage[ style=verbose, autocite=footnote, backend=biber ]{biblatex} \addbibresource{biblatex-examples.bib}

\begin{document}

This,\autocite{springer} should be a side note and this\autocite{springer} should too.

\printbibliography

\end{document}

enter image description here

Max N
  • 425
domwass
  • 11,563
  • This sort of works for me. But in TeXShop, I can get this to work only (generally) after several attempts (for each build) using the "Bibliography" macro, but not the regular "Typeset" command. In LyX it won't build at all. – orome Feb 27 '12 at 15:18
  • @raxacoricofallapatorius, as I said: there are some error messages, so that LyX will stop compiling a PDF file. It seems as if the nobib option of the tufte class is not working correctly. However, I am not at all familiar with the tufte classes. Maybe you can file a bug report using the above example. – domwass Feb 27 '12 at 15:41
  • @domass: See Audrey's comment above, re: the 3.5.2 tuft-common.def. – orome Mar 02 '12 at 20:04
  • @raxacoricofallapatorius, thanks for the hint, I edited the answer accordingly (and can compile without errors now). – domwass Mar 05 '12 at 09:15
  • @Audrey: done (finally). I impudently made use of the wording in your comment. – domwass Jul 25 '12 at 07:40
  • 1
    @domwass Thanks. Again I prefer not to be acknowledged in edits - it just adds extraneous material the user doesn't need to see. With the tufte-latex classes, biblatex issues a warning about footnotes. I'm not sure how \iffootnote is affected, but the classes break \smartcite inside footnotes/sidenotes. – Audrey Jul 27 '12 at 16:17
  • It might that various editors will throw errors, though the PDF will be produced. At leat this is true for Texpad. – Yrogirg Nov 11 '14 at 17:34
  • 1
    The tufte-comon.def file is now available from https://github.com/Tufte-LaTeX/tufte-latex/blob/master/tufte-common.def . The SVN link is not working now. – M Juckes Nov 15 '21 at 09:30
  • I tried this solution, but could not get it to work. Here is my MWE: https://tex.stackexchange.com/questions/656648/biblatex-sidenote-issue-with-tufte-book-class Any help would be greatly appreciated!! – Steven Sep 09 '22 at 08:14