TransWikia.com

How to setup biblatex to not capitalise first author last names

TeX - LaTeX Asked on April 24, 2021

I have a problem with german names with prefix in my bibliography. If the first author surname starts with a small letter, the name gets capitalised anyway. This is not a problem for the second author, etc… It can be fixed putting curly braces around the name in the .bib file, but unfortunately, my citation manager exports the .bib file like this.

Does anybody have an idea, how to fix it? I would be very greatful!

A MWE is here:

documentclass[british]{scrartcl}

usepackage[utf8]{inputenc}
usepackage[T1]{fontenc}    
usepackage{babel}

usepackage{filecontents}

usepackage{csquotes}
usepackage[style=chem-acs,maxbibnames=10,articletitle=true]{biblatex}

begin{filecontents}{jobname.bib}
    @book{Test1,
        author = {von Kling, Alfred and von Klade, Otto},
        booktitle = {This is just a test},
        title = {{This is just a test}},
        year = {2012}
    }
    
    @book{Test2,
        author = {{von} Kling, Alfred and von Klade, Otto},
        booktitle = {This is just a test2},
        title = {{This is just a test2}},
        year = {2012}
    }
end{filecontents}

addbibresource{jobname.bib}

begin{document}
    
    % !TEX TS-program = pdflatex
    % !TEX encoding = UTF-8 Unicode 
    % !BIB TS-program = biber
    
    Doesn't work. autocite{Test1,Test2}
    
    printbibliography
    
end{document}

This produces:

outcome

One Answer

I guess the idea is that the start of a new bib entry is sort of like the start of a sentence. Even a "von" is usually capitalised at the start of a sentence, so it is natural that the "von" would be capitalised here as well.

If you do not want this behaviour, you can tell biblatex not to treat the start of a bibliography entry like the beginning of a sentence by issuing midsentence in begentry.

documentclass[british]{scrartcl}
usepackage[utf8]{inputenc}
usepackage[T1]{fontenc}    
usepackage{babel}
usepackage{csquotes}
usepackage[style=chem-acs, maxbibnames=10, articletitle=true]{biblatex}

renewbibmacro*{begentry}{midsentence}

begin{filecontents}{jobname.bib}
@book{Test1,
  author    = {von Kling, Alfred and von Klade, Otto},
  booktitle = {This is just a test},
  title     = {This is just a test},
  year      = {2012}
}
end{filecontents}
addbibresource{jobname.bib}

begin{document}
  Doesn't work. autocite{Test1}

  printbibliography
end{document}

von Kling, A.; von Klade, O., This is just a test, 2012.

Or you tell biblatex never to capitalise the "von" at the beginning of a sentence.

documentclass[british]{scrartcl}
usepackage[utf8]{inputenc}
usepackage[T1]{fontenc}    
usepackage{babel}
usepackage{csquotes}
usepackage[style=chem-acs, maxbibnames=10, articletitle=true]{biblatex}

renewbibmacro*{name:family}[4]{%
  ifuseprefix
    {usebibmacro{name:delim}{#3#1}%
     usebibmacro{name:hook}{#3#1}%
     mkbibcompletenamefamily{%
       ifdefvoid{#3}
         {}
         {mkbibnameprefix{#3}isdot
          ifprefchar{}{bibnamedelimc}}%
       mkbibnamefamily{#1}isdot}}
    {usebibmacro{name:delim}{#1}%
     usebibmacro{name:hook}{#1}%
     mkbibcompletenamefamily{%
       mkbibnamefamily{#1}isdot}}}%

renewbibmacro*{name:family-given}[4]{%
  ifuseprefix
    {usebibmacro{name:delim}{#3#1}%
     usebibmacro{name:hook}{#3#1}%
     mkbibcompletenamefamilygiven{%
       ifdefvoid{#3}
         {}
         {mkbibnameprefix{#3}isdot
          ifprefchar{}{bibnamedelimc}}%
       mkbibnamefamily{#1}isdot
       ifdefvoid{#4}
         {}
         {bibnamedelimdmkbibnamesuffix{#4}isdot}%
       ifdefvoid{#2}
         {}
         {revsdnamepunctbibnamedelimdmkbibnamegiven{#2}isdot}}}
    {usebibmacro{name:delim}{#1}%
     usebibmacro{name:hook}{#1}%
     mkbibcompletenamefamilygiven{%
       mkbibnamefamily{#1}isdot
       ifdefvoid{#4}
         {}
         {bibnamedelimdmkbibnamesuffix{#4}isdot}%
       ifboolexpe{%
         test {ifdefvoid{#2}}
         and
         test {ifdefvoid{#3}}}
         {}
         {revsdnamepunct}%
       ifdefvoid{#2}
         {}
         {bibnamedelimdmkbibnamegiven{#2}isdot}%
       ifdefvoid{#3}
         {}
         {bibnamedelimdmkbibnameprefix{#3}isdot}}}}

begin{filecontents}{jobname.bib}
@book{Test1,
  author    = {von Kling, Alfred and von Klade, Otto},
  booktitle = {This is just a test},
  title     = {This is just a test},
  year      = {2012}
}
end{filecontents}
addbibresource{jobname.bib}

begin{document}
  Doesn't work. autocite{Test1}

  printbibliography
end{document}

The output in this MWE is the same, but you will see a difference if you use, say Textcite{Test1} at the start of a sentence.

Correct answer by moewe on April 24, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP