I have some problem with the following code.
\documentclass{minimal}
\usepackage{fontspec,luatextra,unicode-math}
\usepackage{icomma}
\usepackage[noload=abbr]{siunitx}
\sisetup{decimalsymbol=comma, detect-all}
\let\nbu\SI
\setmathfont[range={\mathscr,\mathbfscr},StylisticSet=0]{xits-math.otf}
\begin{document}
\nbu{7.8}{m} or $7,8 = \nbu{7.8}{m} = \mathscr{A}$ in math mode.\par
\end{document}
I don't want \itshape
for the m
. With the following code, the result is good, but I don't want to put the \setmathfont{}
inside the document environment (but in sty file). How is it possible ?
\documentclass{minimal}
\usepackage{fontspec,luatextra,unicode-math}
\usepackage{icomma}
\usepackage[noload=abbr]{siunitx}
\sisetup{decimalsymbol=comma, detect-all}
\let\nbu\SI
\begin{document}
\setmathfont[range={\mathscr,\mathbfscr},StylisticSet=0]{xits-math.otf}
\nbu{7.8}{m} or $7,8 = \nbu{7.8}{m} = \mathscr{A}$ in math mode.\par
\end{document}
Thanks to all.
minimal
class be avoided?:~)