BibLaTeX:更改字体大小时缩进错误?

BibLaTeX:更改字体大小时缩进错误?

当我更改字体大小时,BibLaTeX 似乎计算了错误的缩进。第一行后面的行比第一行稍微靠左(见红线)。

显示问题的图片

梅威瑟:

\documentclass[titlepage,listof=totoc,final]{scrbook}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[style=alphabetic,backend=biber,maxnames=4,minnames=3,maxbibnames=99,block=space,abbreviate=true,firstinits=true]{biblatex}

\usepackage{filecontents}

\begin{filecontents}{\jobname.bib}
@online{GLS:datasheet,
    title = "GLS Datasheet",
    organization = "Optoelectronics Research Centre",
    howpublished = "Website",
    date = "2004-09",
    urldate = "2013-07-01",
    url = "http://www.southampton.XXXX",
    address = "Southampton, United Kingdom"
}
@article{Labadie:First_fringes,
    author = {Labadie, L. and Mart\'{\i}n, G. and Anheier, N. C. and Arezki, B. and Qiao, H. A. and Bernacki, B. and Kern, P.},
    title = {First fringes with an integrated-optics beam combiner at 10},
    DOI= "10.1051/0004-6361/201116727",
    journal = {A\&A},
    year = 2011,
    volume = 531,
    pages = "A48"
}
\end{filecontents}

\addbibresource{\jobname.bib}

\begin{document}

\KOMAoptions{fontsize=12pt}
\nocite{*}
\printbibliography

\end{document}

如何避免这种情况?

附言:我的论文中有些文本必须是 10pt,其他文本(如参考书目)必须是 12pt。遗憾的是,这是给我的,我对此无能为力。

答案1

长度的计算\labelalphawidth是根据默认字体大小进行的。您的情况是 11pt。您之前更改了字体大小,\printbibliography这对 的计算没有影响\labelalphawidth。标签宽度是根据 计算的\bibfont

Audrey 在评论中提供了以下解决方案

为了得到正确的计算,biblatex你可以操作命令bibfontbiblatex.def其中定义为:

 \newcommand*{\bibfont}{\normalfont\normalsize}. 

所以你可以使用

 \renewcommand*{\bibfont}{\normalfont\changefontsizes{12pt}}

在序言中。

以你的例子来说:

\documentclass[titlepage,listof=totoc,final]{scrbook}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[style=alphabetic,backend=biber,maxnames=4,minnames=3,maxbibnames=99,block=space,abbreviate=true,firstinits=true]{biblatex}
\renewcommand*{\bibfont}{\normalfont\changefontsizes{12pt}}
\usepackage{filecontents}

\begin{filecontents}{\jobname.bib}
@online{GLS:datasheet,
    title = "GLS Datasheet",
    organization = "Optoelectronics Research Centre",
    howpublished = "Website",
    date = "2004-09",
    urldate = "2013-07-01",
    url = "http://www.southampton.XXXX",
    address = "Southampton, United Kingdom"
}
@article{Labadie:First_fringes,
    author = {Labadie, L. and Mart\'{\i}n, G. and Anheier, N. C. and Arezki, B. and Qiao, H. A. and Bernacki, B. and Kern, P.},
    title = {First fringes with an integrated-optics beam combiner at 10},
    DOI= "10.1051/0004-6361/201116727",
    journal = {A\&A},
    year = 2011,
    volume = 531,
    pages = "A48"
}
\end{filecontents}

\addbibresource{\jobname.bib}

\begin{document}

\nocite{*}
\KOMAoptions{fontsize=12pt}
\printbibliography

\end{document}

相关内容