# Numbers in bibliography cannot be switched on

Using beamer, XeLaTeX and biber, I have single citations in footnotes and a full bibliography on the last slide.

I would like to have numbered entries in the full bibliography but using

\setbeamertemplate{bibliography item}{\insertbiblabel}


did not work. There is simply no number in front of the entries in the bibliography.

Here is the MWE:

\documentclass[10pt]{beamer}

\begin{filecontents*}{test_bib.bib}
@book{Peter1,
author={Peter Muller},
title={My life as Peter Mueller},
publisher={Petersen family},
year={2017}
}
@article{Klaus1,
author = {Peter, Klaus and Petersen, Peter},
title = {A research article about Peter Mueller},
journal = {Intern. Journal on Science},
year = {2018},
volume = {33},
pages = {000007},
doi = {10.10}
}
\end{filecontents*}

\usepackage[style=authortitle,
autocite=footnote,
backend=biber,
]{biblatex}

% I thought this would switch on numbers in bibliography
\setbeamertemplate{bibliography item}{\insertbiblabel}

% change appearance of citations in footnotes
\renewbibmacro*{cite:title}{%
\ifentrytype{article}{
\printtext[bibhyperref]{%
\printfield{journaltitle}%
\setunit{\space}%
\printtext[parens]{\printdate}%
}
}{}%
\ifentrytype{book}{
\printtext[bibhyperref]{%
\printfield[citetitle]{labeltitle}%
\setunit{\space}%
\printtext[parens]{\printdate}%
}%
}{}
}

\begin{document}

\begin{columns}[T]
\begin{column}{0.4\textwidth}
\begin{itemize}
\item Some text in the first column
\item More text\footnotemark
\end{itemize}
\end{column}
\footcitetext{Peter1}
\begin{column}{0.5\textwidth}
\begin{itemize}
\item Guess what: more text\footnotemark
\end{itemize}
\end{column}
\end{columns}
\footcitetext{Klaus1}
\end{frame}

\begin{frame}{Bibliography}
\printbibliography
\end{frame}

\end{document}


I compile with xelatex, biber, xelatex, xelatex and the compiled bibliography looks as follows:

My question: how do I get numbers in the bibliography (and what is the error in my case) ?

You have to change the style of your bibliography. Change

style=authortitle


to

style=numeric


In your case with your using of citing with footnotes you should use:

 citestyle=authortitle, % <============================================
bibstyle=numeric,


With the following complete code

\documentclass[10pt]{beamer}

\begin{filecontents*}{test_bib.bib}
@book{Peter1,
author={Peter Muller},
title={My life as Peter Mueller},
publisher={Petersen family},
year={2017}
}
@article{Klaus1,
author = {Peter, Klaus and Petersen, Peter},
title = {A research article about Peter Mueller},
journal = {Intern. Journal on Science},
year = {2018},
volume = {33},
pages = {000007},
doi = {10.10}
}
\end{filecontents*}

\usepackage[%style=numeric, % authortitle <=============================
citestyle=authortitle, % <============================================
bibstyle=numeric, % <=================================================
autocite=footnote,
backend=biber,
]{biblatex}

% I thought this would switch on numbers in bibliography
\setbeamertemplate{bibliography item}{\insertbiblabel}

% change appearance of citations in footnotes
\renewbibmacro*{cite:title}{%
\ifentrytype{article}{
\printtext[bibhyperref]{%
\printfield{journaltitle}%
\setunit{\space}%
\printtext[parens]{\printdate}%
}
}{}%
\ifentrytype{book}{
\printtext[bibhyperref]{%
\printfield[citetitle]{labeltitle}%
\setunit{\space}%
\printtext[parens]{\printdate}%
}%
}{}
}

\begin{document}

\begin{columns}[T]
\begin{column}{0.4\textwidth}
\begin{itemize}
\item Some text in the first column
\item More text\footnotemark
\end{itemize}
\end{column}
\footcitetext{Peter1}
\begin{column}{0.5\textwidth}
\begin{itemize}
\item Guess what: more text\footnotemark
\end{itemize}
\end{column}
\end{columns}
\footcitetext{Klaus1}
\end{frame}

\begin{frame}{Bibliography}
\printbibliography
\end{frame}

\end{document}


you get the result:

• thanks for you immediate answer! Doing as you suggested works but also destroys my footnote citations: when compiling there is a warning Macro 'cite:title' undefined and only numbers are shown in the footnote citations... (it also does not help to replace renewbibmacro with newbibmacro) – Alf Feb 7 '19 at 14:06
• the code was inspired from a few threads I found on this site (is it somehow weird or confusing code?). I just figured out the solution: citestyle=authortitle and bibstyle=numeric. Thanks for pointing me into the right direction - is it possible that you update your answer accordingly? – Alf Feb 7 '19 at 14:23
• @Alf I don't want to be a spoilsport, but please keep in mind that there is absolutely no guarantee that the footnote number and the label number of your citations in the bibliography coincide. Just cite Klaus1 before Peter1 and compare the footnote and bibliography. This can be made worse by sprinkling in other normal footnotes or citing a work again. – moewe Feb 7 '19 at 14:53
• @moewe ouch, thanks for the warning! I guess I have to think of something else then.... – Alf Feb 7 '19 at 14:59
• @Alf There are a lot of questions about cite styles like this on this site, because it is quite tricky to pull off. I myself am not particularly fond of mixing numeric and verbose-like styles in such a way, but I can see where people are coming from. If you really like that sort of thing I would try with something like tex.stackexchange.com/q/45406/35864 from Audrey's answer. With her answers you can usually be sure that stuff has been thought through. – moewe Feb 7 '19 at 15:09