moewew / biblatex-trad

traditional bibliography styles with biblatex
LaTeX Project Public License v1.3c
31 stars 7 forks source link

Alpha style label consistent with BibTeX alpha by default? #22

Closed andrewdbate closed 8 years ago

andrewdbate commented 10 years ago

Firstly, thanks for your efforts in developing this package!

When I use BibTeX alpha for a publication with many authors (e.g. Smith, Jones, Motik, Lehman, Lowe, Wang, Grau), the default label in BibTeX alpha looks like [SJML+96], but with trad-alpha I get [SJMLLWG96], which is too long.

Setting maxalphanames=4 in the usepackage options results in [Smi+96], which is not what I wanted either.

Any help would be appreciated.

(I am sorry if this is not a bug, but an error in my misunderstanding!)

marcodaniel commented 10 years ago

Hi,

I guess you need the option minalphanames

\RequirePackage{filecontents}
\begin{filecontents}{\jobname.bib}
@book{test,
author={Smith and Jones and Motik and Lehman and Lowe and Wang and Grau},
title={Title},
year={2013},
}

\end{filecontents}
\documentclass{report}
\usepackage[style=trad-alpha,minalphanames=4,maxalphanames=4]{biblatex}
\addbibresource{\jobname.bib}
\addbibresource{biblatex-examples.bib}

\begin{document}

\cite{test}

\cite{companion}

\cite{knuth:ct:a}

\end{document}

regards Marco

andrewdbate commented 10 years ago

That's great, it worked -- thanks!

Also, for the benefit of others who may be reading this, if you require the plus in the label [SJML+96] to be superscripted, then after the usepackage statement, include the following line in the preamble:

\renewcommand*{\labelalphaothers}{\textsuperscript{+}}

obama commented 9 years ago

you should put that into the manual or something ;)

moewew commented 8 years ago

I have now settled with maxalphanames=3, minalphanames=3 as well as \renewcommand*{\labelalphaothers}{\textsuperscript{+}} for trad-alpha (see the commits linked above). In my tests I only got three names and not four with alpha.bst.

Let me know what you think.

moewew commented 8 years ago

This should be fixed in version 0.3 which has been on CTAN for a bit now. Testing is, of course, still very much appreciated.