我正在尝试添加使用 siunitx,并希望我的所有数字都采用旧样式。但是,我无法正确编译它。像 \SI{\oldstylenums{23}}{\milli\Molar} 这样的命令会给我带来错误。有没有办法让所有数字(如果可能的话,包括参考书目,但不包括 dois)都采用 oldstylenums 格式?我正在使用 TexMaker (pdfLaTeX)。
我目前的序言是:
\documentclass[a4paper,12pt,oneside]{book}
%Page Setting
\usepackage[left=35mm, right=15mm, top=20mm, bottom=15mm]{geometry}
\usepackage{setspace}
%\usepackage{pdfpages}
\usepackage{graphicx} %For adding Figures
\usepackage{float} %For removing figure borders
\usepackage{tabularx} %For making tables
\usepackage{amssymb}
\usepackage{multirow} %For multirow tables
\usepackage{csquotes} %For the ability to use single or double inverted commas
\usepackage{booktabs} % For \toprule, \midrule and \bottomrule in tables
%\usepackage{pgfplotstable} % Generates table from .csv
\usepackage{longtable} %Allows multi-page tables
\usepackage{rotating} %Allows for single page landscape using \sidewaystable{}
\usepackage{pdflscape} %Allows for landscape
\usepackage{multirow} %Allows for merging across rows
\usepackage{tablefootnote}
\usepackage{url} %Allows for writing urls correctly.
\usepackage{hyperref}
\usepackage{footnote}
\usepackage{lineno} %For adding line numbers
\usepackage{threeparttable} %For a more structured tables
\usepackage{caption}
\captionsetup{singlelinecheck=false}
\usepackage[alsoload=synchem]{siunitx} %For the ability to write SI units
\sisetup{input-uncertainty-signs=\pm,
separate-uncertainty=true}
\renewcommand\linenumberfont{\normalfont\bfseries\normalsize}
\usepackage[toc,numberline]{glossaries}
\makeglossaries
\usepackage[%backend=biber,
style=numeric,
natbib=true,
url=false,
giveninits=true,
maxbibnames=200,
sorting=none]{biblatex}
\addbibresource{References.bib}
%To get SIAM-like format in references
\renewcommand*{\newunitpunct}{\addcomma\space}
\renewcommand*{\mkbibnamefamily}[1]{\textsc{#1}}
\DeclareFieldFormat*{title}{\mkbibemph{#1}}
\DeclareFieldFormat*{citetitle}{\mkbibemph{#1}}
\DeclareFieldFormat{journaltitle}{#1}
\renewbibmacro*{in:}{%
\ifentrytype{article}
{}
{\printtext{\bibstring{in}\intitlepunct}}}
\newbibmacro*{pubinstorg+location+date}[1]{%
\printlist{#1}%
\newunit
\printlist{location}%
\newunit
\usebibmacro{date}%
\newunit}
\renewbibmacro*{publisher+location+date}{\usebibmacro{pubinstorg+location+date}{publisher}}
\renewbibmacro*{institution+location+date}{\usebibmacro{pubinstorg+location+date}{institution}}
\renewbibmacro*{organization+location+date}{\usebibmacro{pubinstorg+location+date}{organization}}
% print url if no doi
\renewbibmacro*{doi+eprint+url}{%
\printfield{doi}%
\newunit\newblock%
\iftoggle{bbx:eprint}{%
\usebibmacro{eprint}%
}{}%
\newunit\newblock%
\iffieldundef{doi}{%
\usebibmacro{url+urldate}}%
{}%
}