biblatex で latin1 をエンコードする際の問題

biblatex で latin1 をエンコードする際の問題

パッケージで少し問題がありますbiblatex。コンパイルしようとすると (pdflatex を使用)、次の警告メッセージが返されます。

Process started: biber.exe AuxDirectory/"example"

INFO - This is Biber 2.12
INFO - Logfile is 'AuxDirectory/example.blg'
INFO - Reading 'AuxDirectory/example.bcf'
INFO - Found 2 citekeys in bib section 0
INFO - Processing section 0
INFO - Looking for bibtex format file 'example.bib' for section 0
INFO - LaTeX decoding ...
INFO - Found BibTeX data source 'example.bib'
INFO - Overriding locale 'pt-BR' defaults 'variable = shifted' with 'variable = non-ignorable'
INFO - Overriding locale 'pt-BR' defaults 'normalization = NFD' with 'normalization = prenormalized'
INFO - Sorting list 'none/global//global/global' of type 'entry' with template 'none' and locale 'pt-BR'
INFO - No sort tailoring available for locale 'pt-BR'
INFO - Writing 'AuxDirectory/example.bbl' with encoding 'latin1'
WARN - The entry 'Adam2009' has characters which cannot be encoded in 'latin1'.
       - Recoding problematic characters into macros.
WARN - The entry 'Adam2010' has characters which cannot be encoded in 'latin1'.
       - Recoding problematic characters into macros.
INFO - Output to AuxDirectory/example.bbl
INFO - WARNINGS: 2

Process exited normally

私は tex ファイルに次の最小限のコードを使用しました。

\documentclass[a4paper,twoside,openright,final]{memoir}%
\usepackage{fouriernc}
\usepackage[T1]{fontenc}
\usepackage[latin1]{inputenc}
\usepackage{lastpage}
\usepackage{indentfirst}
\usepackage[backend=biber,style=numeric-comp,sorting=none,sortlocale=auto,bibencoding=auto,backref=true,date=year]%
{biblatex}
\usepackage{url}
\usepackage[english,brazilian]{babel}
\usepackage{csquotes}


\settrimmedsize{297mm}{210mm}{*}
\setlength{\trimtop}{0pt}
\setlength{\trimedge}{\stockwidth}
\addtolength{\trimedge}{-\paperwidth}
\settypeblocksize{247mm}{160mm}{*}
\setulmargins{3cm}{*}{*}
\setlrmargins{*}{*}{1.5}
\setmarginnotes{17pt}{51pt}{\onelineskip}
\setheadfoot{\onelineskip}{2\onelineskip}
\setheaderspaces{*}{2\onelineskip}{*}
\checkandfixthelayout
\frenchspacing
\addbibresource{example.bib}

\makeatother


\begin{document}
    \cite{Adam2009}
    \cite{Adam2010}
    \printbibliography
\end{document}

以下に、問題のある 2 つの参考文献の最小限の bib-code も示します。

@Article{Adam2009,
  author    = {Adam, C. and Klimas, P. and S{\'a}nchez-Guill{\'e}n, J. and Wereszczy{\'n}ski, A.},
  title     = {Compact baby Skyrmions},
  journal   = {Physical Review D},
  year      = {2009},
  volume    = {\bfseries 80},
  issue     = {10},
  month     = {11},
  pages     = {105013},
  doi       = {10.1103/PhysRevD.80.105013},
  url       = {https://link.aps.org/doi/10.1103/PhysRevD.80.105013},
  urldate   = {2019-01-31},
  numpages  = {14},
  publisher = {American Physical Society},
}


@Article{Adam2010,
  author       = {Adam, C. and Roma{\'n}czukiewicz, T. and S{\'a}nchez-Guill{\'e}n, J. and Wereszczy{\'n}ski, A.},
  title        = {Investigation of restricted baby Skyrme models},
  journaltitle = {Phys.ical Review D},
  year         = {2010},
  volume       = {\bfseries 81},
  number       = {8},
  month        = {4},
  pages        = {085007},
  doi          = {10.1103/PhysRevD.81.085007},
  url          = {https://link.aps.org/doi/10.1103/PhysRevD.81.085007},
  urldate      = {2019-01-31},
  numpages     = {10},
  publisher    = {American Physical Society},
}

{\'n}どうやら、文字を ' ' でエンコードできないために問題が発生しているようですlatin1。コードを変更しようとしましたが、成功しませんでした。誰かがこの問題を解決できると知っていれば、本当に感謝いたします。

答え1

このメッセージは単なる警告であり、アクション (つまり、 のutf8代わりにを使用するlatin1) を実行する価値がないと判断した場合は無視しても問題ありません (ここではすべてを UTF-8 でエンコードすることが最善の解決策であると確信していますが、理由があるはずです)。

警告が発生するのはńは Latin-1 には含まれていないため、Latin-1 にこだわる場合は、実際の文字ではなく LaTeX マクロの組み合わせとしてのみエクスポートできます (実際、Biber はここで必要以上に過激なことをしています。つまり、問題のある文字だけでなく、エントリ全体を ASCII マクロで書き出します)。これは、文字の入力とは無関係です。Biber は、並べ替えができるように内部ですべてを UTF-8 に変換するからです。これは、.bblでさらに処理するために、文字がファイルに書き込まれる方法にのみ関係しますbiblatex

オプション付きでBiberを呼び出すことで警告を回避できます--output-safechars

biber --output-safechars <filename>

これにより、すべての非 ASCII 文字がマクロ形式のままになり、文字を Latin-1 の非 ASCII 範囲に変換することは試行されません。(したがって、.bblすべての Latin-1 文字を含むエントリがある場合、違いがわかります。)


ご了承ください

volume    = {\bfseries 80},

あまり意味的ではありません。

volume    = {80},

\DeclareFieldFormat[article,periodical]{volume}{\mkbibbold{#1}}% volume of a journal

その代わり。

関連情報