下面是我的字体设置
\documentclass{article}
\usepackage{unicode-math}
\setmainfont{Minion Pro}[Scale=0.93]
\setmathfont{Erewhon Math}
\setmathfont{TeX Gyre Schola Math}[Scale=0.93,
range={up/{latin,Latin,num}, it/{latin,Latin,num},
bfup/{latin,Latin,num}, bfit/{latin,Latin,num}}]
\usepackage[mathcal]{euscript}
\begin{document}
\[\mathscr{H}\]
\end{document}
打印\mathscr{H}
像
有点斜体。但我希望它的效果像
\usepackage[scr=boondoxo]{mathalfa}
看起来像
我该如何设置unicode-math
才能得到它?
\setmathfont[range={\mathscr}]{?}
答案1
我认为\mathscr
几乎Garamond-Math
可以完成这项工作。但是,其默认设置看起来比您想要的倾斜度更大。因此,应用一点负假倾斜会产生以下结果:
\documentclass{article}
\usepackage{unicode-math}
\setmainfont{Minion Pro}[Scale=0.93]
\setmathfont{Erewhon Math}
\setmathfont{TeX Gyre Schola Math}[Scale=0.93,
range={up/{latin,Latin,num}, it/{latin,Latin,num},
bfup/{latin,Latin,num}, bfit/{latin,Latin,num}}]
\usepackage[mathcal]{euscript}
\setmathfont[range={\mathscr}, FakeSlant=-0.3]{Garamond-Math}
\begin{document}
\[\mathscr{H}\]
\end{document}
答案2
您可以boondoxo
通过从 借用相关代码来获得精确的字体mathalpha
。
\documentclass{article}
\usepackage{unicode-math}
\setmainfont{Minion Pro}[Scale=0.93]
\setmathfont{Erewhon Math}
\setmathfont{TeX Gyre Schola Math}[
Scale=0.93,
range={
up/{latin,Latin,num},
it/{latin,Latin,num},
bfup/{latin,Latin,num},
bfit/{latin,Latin,num}
}
]
\DeclareFontFamily{U}{BOONDOX-calo}{}
\DeclareFontShape{U}{BOONDOX-calo}{m}{n}{<-> s*[1] BOONDOX-r-calo}{}
\DeclareFontShape{U}{BOONDOX-calo}{b}{n}{<-> s*[1] BOONDOX-b-calo}{}
\AtBeginDocument{%
\let\mathscr\relax
\DeclareMathAlphabet{\mathscr}{U}{BOONDOX-calo}{m}{n}%
\SetMathAlphabet{\mathscr}{bold}{U}{BOONDOX-calo}{b}{n}%
}
\begin{document}
$H\mathscr{H}$
$A\mathscr{A}B\mathscr{B}$
$\mathscr{ABCDEFGHIJKLM}$
$\mathscr{NOPQRSTUVWXYZ}$
\end{document}
我留下了s*[1]
(这实际上是多余的)以防您想调整放大倍数。
答案3
STIX Two Math 的风格集 1是 Boondoxo 的克隆版。
\documentclass{article}
\usepackage{unicode-math}
\setmathfont{Latin Modern Math} % Or any other.
\setmathfont{STIX Two Math}[range={scr, bfscr}, StylisticSet=1, Scale=MatchUppercase]
\begin{document}
\begin{gather*}
\mathscr{ABCDEFGH} \\
\mathbfscr{ABCDEFGH}
\end{gather*}
\end{document}