2

I noticed biblatex uses the language option passed to polyglossia first, before acknowledging the option passed to it via the language = <language> option.

Here is the MWE that illustrates the problem.

\documentclass[slovene,a4paper,12pt]{article}
\usepackage{polyglossia}
\usepackage[language=slovene, backend=biber]{biblatex}
\usepackage[autostyle]{csquotes}

\setdefaultlanguage{slovenian}
\DeclareLanguageMapping{slovene}{slovene-apa}

\addbibresource{biblatex-examples.bib}

\begin{document}
Cite here \parencite{aksin}.
\printbibliography
\end{document}

The example compiles fine, but how can I avoid the warning given:

Package biblatex Warning: Language 'slovenian' not supported.

(biblatex) Using fallback language 'slovene' on input line 25.

  • 1
    You can't really avoid this currently as biblatex will always try to automatically detect the language from the default polyglossia/babel language first. This is an annoying artefact due to biblatex and polyglossia naming languages differently. I hope in the future that polyglossia and babel can standardise on BCP47 locale names (biber already supports these and maps internally to the polyglossia/babel names). – PLK May 8 '16 at 13:23
  • Thank you for your answer, @PLK. Care to write this as an answer I can accept? I would say it is indeed (a temporary) answer anyhow. – Fato39 May 10 '16 at 18:02
  • @Fato39 I tried your MWE and it compiles indeed, but the problem with language naming incompatibility persists. The bibliography strings like andothers or pages still lack translation into Slovene/Slovenian language (sl-SI). PS: What is the \DeclareLanguageMapping for? – Vid Merljak May 24 '17 at 10:23
3

Consulting with biblatex maintainer Philip Kime, I give you his solution:

\DeclareLanguageMapping{slovenian}{slovene}

makes biblatex and biber understand that both language identifiers refer to the same sl-SI language (see package documentation, as @moewe suggests). Hence the bibliography strings like andothers or pages successfully get their respective translations - which was not the case when I compiled the MWE provided in the question.

Regarding the warnings in the log file, I would confirm that they cannot be avoided. That is, until the slovenian identifier is hard-coded into biblatex as a synonym for slovene, just like UKenglish is for british.

| improve this answer | |
1

biblatex will always try to automatically detect the language from the default polyglossia/babel language first. The problem you are seeing is an annoying artefact due to biblatex and polyglossia naming languages differently. I hope in the future that polyglossia and babel can standardise on BCP47 locale names (biber already supports these and maps internally to the polyglossia/babel names).

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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