2

A couple of years ago, I asked how to make Biblatex cite, in the bibliography, the translation of a work in the form “translated by … as …”.

I was told, in that post, to use relatedtype={bytranslator} instead of relatedtype={translatedas}. This generally works well. However, I have just encountered a little problem, namely in cases where the translator is not specified. In such cases, I think, the words “by …” should be dropped, such that only “translated as [title of work]” remains. What happens, though, is that “translated by [title of work]” is produced. That is, rather than dropping the word “by” preceding the name of the translator, Biblatex drops the word “as” following the name. Can this be fixed?

Here is a MWE (note that this example is fictitious; the translator of that translation is in fact known; but I have encountered cases where the translator is not known):

\documentclass[12pt]{article}

\usepackage{filecontents}

\begin{filecontents}{biblio.bib}
@book{Badiou2006,
author = {Badiou, Alain},
title = {Logiques des mondes},
subtitle = {L'\^{e}tre et l'\'{e}v\'{e}nement 2},
location = {Paris},
publisher = {\'{E}ditions du Seuil},
date = {2006},
related={Badiou2009},
relatedtype={bytranslator},
}
@book{Badiou2009,
author = {Badiou, Alain},
title = {Logics of worlds},
subtitle = {Being and event 2},
location = {London},
publisher = {Continuum},
year = {2009},
}
\end{filecontents}

\usepackage[style=authoryear,abbreviate=false]{biblatex}
\addbibresource{biblio.bib}

\begin{document}

Citing a book by \textcite{Badiou2006}.

\printbibliography

\end{document}

This produces the following entry:

Badiou, Alain (2006). Logiques des mondes. L’être et l’événement 2. Paris: Éditions du Seuil. Translated by Logics of worlds. Being and event 2 (London: Continuum, 2009).

It should be "Translated as" instead of "Translated by". How can this be achieved?

EDIT:

The relatedtype should work not only with books, but also with articles in journals or collections such as the following:

@incollection{Althusser1976a,
author = {Althusser, Louis},
title = {Id\'{e}ologie et appareils id\'{e}ologiques d'\'{E}tat},
subtitle = {Notes pour une recherche},
location = {Paris},
publisher = {\'{E}ditions sociales},
year = {1976},
booktitle = {Positions, 1964--1975},
pages = {67-125},
related = {Althusser1971a},
relatedtype = {translatedbyas},
}
@incollection{Althusser1971a,
author = {Althusser, Louis},
translator = {Brewster, Ben},
title = {Ideology and ideological state apparatuses},
subtitle = {Notes towards an investigation},
location = {New York},
publisher = {Monthly Review Press},
year = {1971},
booktitle = {Lenin and philosophy and other essays},
pages = {127-186},
}
2
  • 1
    Why wouldn't relatedtype={translationas} suffice? In this case what is missing is the translator so the string to be printed before the translation is translationas, not translationby.
    – Ivan
    Feb 1, 2021 at 22:22
  • 1
    @Ivan: You are right, relatedtype={translationas} produces "Translated as". I did not know that this option existed. I only knew of relatedtype={translatedas}, which does not work for me, for the reasons explained in the linked post. Anyway, relatedtype={translationas} does not work for me either because, even though it produces what I want when the translator is missing, it does not produce what I want when the translator is present. In that case, it produces "Translated as [title]. Translated by [name]", whereas I would like "Translated by [name] as [title]". Can that be done?
    – Wolfhart
    Feb 1, 2021 at 23:24

1 Answer 1

1

You can define a new relatedtype based on bytranslator that can deal with a missing translator.

The only trick here is to check if the translator is present and print different strings depending on whether or not it is present. For the remaining part related:translatedbyas below is a copy of related:bytranslator from biblatex.def (ll. 2291-3008 in v3.16).

\documentclass[12pt]{article}

\usepackage[style=authoryear,abbreviate=false]{biblatex}

\NewBibliographyString{translated}
\DefineBibliographyStrings{english}{
  translated = {translated},
}

\makeatletter
\newbibmacro*{related:translatedbyas}[1]{%
  \entrydata{#1}{%
    \ifnameundef{translator}
      {\bibstring{translated}}
      {\bibstring{bytranslator}%
       \setunit{\addspace}%
       \renewbibmacro*{name:hook}[1]{%
         \ifnumequal{\value{listcount}}{1}
           {\mkrelatedstringtext{\lbx@initnamehook{##1}}}
           {}}%
       \printnames[bytranslator]{translator}}%
    \setunit{\addspace}
    \bibstring[\mkrelatedstringtext]{astitle}%
    \setunit{\space}%
    \usebibmacro{title}%
    \setunit{\addspace}%
    \printtext[parens]{%
      \printlist{location}%
      \iflistundef{publisher}
        {\setunit*{\addcomma\space}}
        {\setunit*{\addcolon\space}}%
      \printlist{publisher}%
      \setunit*{\addcomma\space}%
      \printdate}}}
\makeatother

\begin{filecontents}{\jobname.bib}
@book{Badiou2006,
  author      = {Badiou, Alain},
  title       = {Logiques des mondes},
  subtitle    = {L'être et l'événement 2},
  location    = {Paris},
  publisher   = {Éditions du Seuil},
  date        = {2006},
  related     = {Badiou2009},
  relatedtype = {translatedbyas},
}
@book{Badiou2009,
  author    = {Badiou, Alain},
  title     = {Logics of worlds},
  subtitle  = {Being and event 2},
  location  = {London},
  publisher = {Continuum},
  year      = {2009},
}
@book{Badiou2007,
  author      = {Badiou, Alain},
  title       = {Logiques des mondes},
  subtitle    = {L'être et l'événement 3},
  location    = {Paris},
  publisher   = {Éditions du Seuil},
  date        = {2007},
  related     = {Badiou2010},
  relatedtype = {translatedbyas},
}
@book{Badiou2010,
  author     = {Badiou, Alain},
  translator = {Toscano, Alberto},
  title      = {Logics of worlds},
  subtitle   = {Being and event 3},
  location   = {London},
  publisher  = {Continuum},
  year       = {2010},
}
\end{filecontents}
\addbibresource{\jobname.bib}

\begin{document}

Citing a book by \textcite{Badiou2006,Badiou2007}.

\printbibliography

\end{document}

Translated as Logics of worlds. Being and event 2 (London: Continuum, 2009).//Translated by Alberto Toscano as Logics of worlds. Being and event 3 (London: Continuum, 2010).


Together with the code from biblatex: relatedtype={bytranslator} does not work as expected with @article and @incollection you'd probably end up with something like

\makeatletter
\newbibmacro*{related:translatedbyas}[1]{%
  \entrydata{#1}{%
    \ifnameundef{translator}
      {\bibstring{translated}}
      {\bibstring{bytranslator}%
       \setunit{\addspace}%
       \renewbibmacro*{name:hook}[1]{%
         \ifnumequal{\value{listcount}}{1}
           {\mkrelatedstringtext{\lbx@initnamehook{##1}}}
           {}}%
       \printnames[bytranslator]{translator}%
       \clearname{translator}}%
    \setunit{\addspace}
    \bibstring[\mkrelatedstringtext]{astitle}%
    \setunit{\space}%
    \usebibmacro{title}%
    \ifentrytype{article}
      {\usebibmacro{in:}%
       \usebibmacro{journal+issuetitle}}
      {}
    \ifentrytype{inbook}
      {\usebibmacro{in:}%
       \usebibmacro{bybookauthor}%
       \newunit\newblock
       \usebibmacro{maintitle+booktitle}%
       \newunit\newblock
       \usebibmacro{byeditor+others}%
       \newunit\newblock
       \printfield{edition}}
      {}
    \ifentrytype{incollection}
      {\usebibmacro{in:}%
       \usebibmacro{maintitle+booktitle}%
       \newunit\newblock
       \usebibmacro{byeditor+others}%
       \newunit\newblock
       \printfield{edition}%
       \newunit
       \iffieldundef{maintitle}
         {\printfield{volume}%
          \printfield{part}}
         {}}
      {}
    \ifentrytype{inproceedings}
      {\usebibmacro{in:}%
       \usebibmacro{maintitle+booktitle}%
       \newunit\newblock
       \usebibmacro{event+venue+date}%
       \newunit\newblock
       \usebibmacro{byeditor+others}%
       \newunit\newblock
       \iffieldundef{maintitle}
         {\printfield{volume}%
          \printfield{part}}
         {}}
      {}
    \setunit{\addspace}%
    \printtext[parens]{%
      \printlist{location}%
      \iflistundef{publisher}
        {\setunit*{\addcomma\space}}
        {\setunit*{\addcolon\space}}%
      \printlist{publisher}%
      \setunit*{\addcomma\space}%
      \printdate}
      \newunit\newblock
      \printfield{note}%
      \newunit\newblock
      \printfield{chapter}%
      \setunit{\bibpagespunct}%
      \printfield{pages}}}
\makeatother
9
  • Thank you very much, moewe! Your solution works, it produces the desired result. However, at the same it throws an error on my system, namely ! Undefined control sequence. <argument> \mkrelatedstringtext {\csuse {\abx@str @\blx@tempa }}. Why is that, and can it be avoided?
    – Wolfhart
    Feb 2, 2021 at 13:22
  • 1
    @Wolfhart Update your TeX system. \mkrelatedstringtext was added in version v3.16 of biblatex (released 2020-12-31). On an older system \providecommand{\mkrelatedstringtext}[1]{{\mainlang #1}} might work.
    – moewe
    Feb 2, 2021 at 16:23
  • Adding \providecommand{\mkrelatedstringtext}[1]{{\mainlang #1}} solved the problem, thanks! There is one more issue left: I would like to combine the code you provided here with the code you provided in tex.stackexchange.com/questions/167058 in order to make the new relatedtype work with entry types other than books. How can that be done? I thought that it might be as easy as putting the two pieces of code next to each other and replace \newbibmacro*{related:bytranslator}[1]{% in the previous code by \newbibmacro*{related:translatedbyas}[1]{% but that does not work.
    – Wolfhart
    Feb 2, 2021 at 19:24
  • 1
    @Wolfhart Putting the two definitions one after another into the document won't do it: The second definition will just overwrite the first. You have to actually combine the relevant code. See the edit, please.
    – moewe
    Feb 3, 2021 at 8:14
  • 1
    @Wolfhart 1) Yes, the \NewBibliographyString{translated}\DefineBibliographyStrings{english}{ translated = {translated},} is required also for the new code. You can already see a difference in the MWE if you remove it. 2) I forgot to copy a line. Try again now, please.
    – moewe
    Feb 3, 2021 at 19:44

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .