# Multibib & indentation

I use multibib to apply more than one bibliography in my document. The problem is when using more than 9 entrys, there occurs an indentation.

\documentclass{article}

\usepackage[resetlabels]{multibib}
\newcites{lit}{Literature1}
%\newcites{lit2}{Literature2}

\usepackage{etoolbox}
\makeatletter
\patchcmd{\thebibliography}{%
\section*{\refname}\@mkboth{\MakeUppercase\refname}{\MakeUppercase\refname}%
}{}{}{}
\makeatother

\usepackage{filecontents}

\begin{filecontents}{Lit1.bib}
@misc{A01,
author = {Author, A.},
year = {2001},
title = {Alpha},
}
@misc{A02,
author = {Author, A.},
year = {2001},
title = {Alpha},
}
@misc{A03,
author = {Author, A.},
year = {2001},
title = {Alpha},
}
@misc{A04,
author = {Author, A.},
year = {2001},
title = {Alpha},
}
@misc{A05,
author = {Author, A.},
year = {2001},
title = {Alpha},
}
@misc{A06,
author = {Author, A.},
year = {2001},
title = {Alpha},
}
@misc{A07,
author = {Author, A.},
year = {2001},
title = {Alpha},
}
@misc{A08,
author = {Author, A.},
year = {2001},
title = {Alpha},
}
@misc{A09,
author = {Author, A.},
year = {2001},
title = {Alpha},
}
@misc{A10,
author = {Author, A.},
year = {2001},
title = {Alpha},
}
@misc{A11,
author = {Author, A.},
year = {2001},
title = {Alpha},
}
\end{filecontents}

\begin{document}

\makeatletter\renewcommand{\@biblabel}[1]{[A\,#1]}\makeatother
\nocitelit{*}
\bibliographystylelit{plain}
\bibliographylit{Lit1}

\end{document}


How can I avoid this indentation?

-

The indentation has nothing to do with multibib but stems from the fact that you enlarging the biblabels with "A ". BibTeX calculates somewhat correctly that the largest label is "10" (see the bbl file), where you want the largest label to be "A 10". The simplest option to circumvent this is to use

\setbiblabelwidth{1000}


from the multibib pakage. The other, more involved option is to hack the bibliography style to output the actually desired labels to the bbl file.

-

The problem is that multibib, with the resetlabels option, always passes 0 for computing the label width, which is an error, in my opinion.

You can solve the issue with another patch:

\usepackage{etoolbox}
\makeatletter
\patchcmd{\thebibliography}{%
\section*{\refname}\@mkboth{\MakeUppercase\refname}{\MakeUppercase\refname}%
}{}{}{}
\begingroup\catcode#=12
\AtBeginDocument{
\patchcmd\thebibliography

The \AtBeginDocument and the \catcode trick are necessary because multibib redefines \thebibliography` at begin document.