Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I am using biblatex with the biber backend and the citation style biblatex-juardiss. I am using the option uniquename=allfull to avoid ambigious author names. My problem is that the uniquename list includes authors and editors from @BOOK, @ARTICLE and @COMMENTARY. But the editors of @INCOLLECTION are not included in the uniquename list. \value{uniquename} from an @INCOLLECTION editor always returns zero.

I tried the following minimal code:

\begin{filecontents*}{lit.bib}

@BOOK{werner,
  author = {Werner, Dennis},
  title = {Title of the Book}
}

@INCOLLECTION{werner2,
  editor = {Schneider, Uwe AND Werner, Hans},
  title = {Title of the Article},
  booktitle = {Title of the Book},
  Author = {Tester, Hans}
}


@COMMENTARY{werner3,
  editor = {Schneider, Uwe AND Werner, Hans},
  title = {Title of the Article}
}

\end{filecontents*}



\documentclass{article}
\usepackage[a5paper, left=1.9cm, right=2.1cm, top=1.2cm, bottom=2.3cm]{geometry}

\usepackage[
backend=biber,
style=authortitle,
uniquename=allfull
]{biblatex}

\bibliography{lit}

\renewbibmacro*{cite}{%
  \iffieldundef{shorthand}
    {\ifnameundef{labelname}
       {}
       {\printnames{labelname}%
        \setunit{\nametitledelim}}%
     \usebibmacro{cite:title}}%
    {\usebibmacro{cite:shorthand}}%
    \ifentrytype{incollection}{\addcomma\addspace\printnames{editor}}{}%
    }

\DeclareNameFormat[incollection]{editor}{%
  \iffootnote{%
    \ifcase\value{uniquename}%
      {\usebibmacro{name:first-last}{#1}{#6}{}{#7}}%
    \or
      \ifuseprefix
        {\usebibmacro{name:first-last}{#1}{#4}{#5}{#8}}
        {\usebibmacro{name:first-last-init}{#1}{#4}{#6}{#8}}%
    \or
      \usebibmacro{name:first-last-init}{#1}{#3}{#5}{#7}%
    \fi%
    \usebibmacro{name:andothers}%
    }
    {\mkbibemph{%
      \iffirstinits%
        {\usebibmacro{name:last-first}{#1}{#4}{#5}{#7}}%
        {\usebibmacro{name:last-first}{#1}{#3}{#5}{#7}}%
      \usebibmacro{name:andothers}%
    }}%
}%

\begin{document}

1\footcite{werner}
2\footcite{werner2}
% 3\footcite{werner3}

\end{document}

As a result I get:

1 Werner, Title of the Book.

2 Tester, “Title of the Article”, Schneider and Werner.

This result is abmibious since both Werners are differnet people.

If I cite the werner3, I get:

1 D. Werner, Title of the Book.

2 Tester, “Title of the Article”, Schneider and Werner.

3 Schneider and H. Werner, Title of the Article.

How do I get the editors of @INCOLLECTION included in the uniquename list?

share|improve this question

1 Answer 1

up vote 2 down vote accepted

Name disambiguation only considers names in the labelname list. For your @incollection entry the editors aren't part of labelname because the author field is available. One way around this is to cross-reference a @collection entry in which the editors form the labelname.

\begin{filecontents*}{\jobname.bib}
@BOOK{werner,
  author = {Werner, Dennis},
  title = {Title of the Book}}
@COLLECTION{schneider,
  options = {skipbib},
  editor = {Schneider, Uwe AND Werner, Hans},
  title = {Title of the Book}}
@INCOLLECTION{tester,
  title = {Title of the Article},
  author = {Tester, Hans},
  crossref = {schneider}}
\end{filecontents*}

\documentclass{article}
\usepackage[backend=biber,style=authortitle,uniquename=allfull,mincrossrefs=1]{biblatex}
\bibliography{\jobname}

\newbibmacro*{in:labelname}[1]{%
  \entrydata{#1}{\printnames{labelname}}}

\renewbibmacro*{cite}{%
  \iffieldundef{shorthand}
    {\ifnameundef{labelname}{}{%
       \printnames{labelname}%
       \setunit{\nametitledelim}}%
     \usebibmacro{cite:title}%
     \ifentrytype{incollection}
       {\setunit{\addcomma\space}%
        \usebibmacro{in:labelname}{\thefield{crossref}}}{}}
    {\usebibmacro{cite:shorthand}}}

\begin{document}
\null\vfill
Filler.\footcite{werner} Filler.\footcite{tester}
\printbibliography
\end{document}

enter image description here

Note that the mincrossrefs=1 setting ensures that the cross-referenced entry is considered in name disambiguation. To suppress this entry in the bibliography, we set skipbib=true in the bib file.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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