This may be a trite question, but I haven't found an answer and my tentative at it doesn't work. I am trying to set a document in which I use both serif and sans numerals in math mode. I am running the files on top of XeLaTeX and using the package mathspec. I have the following lines in my preamble (actually, in a class file):
\RequirePackage{mathspec} % This line if in a class or style file
%\usepackage{mathspec} This one if not in a class or a style file
\defaultfontfeatures{Numbers=OldStyle,Ligatures=TeX}
\setmainfont{NewBaskervilleStd-Roman}
\setsansfont{Legacy Sans ITC Std Book}
\setmathsfont(Digits,Latin)[Numbers={Lining,Proportional}]{NewBaskervilleStd-Roman}
\setmathrm[Numbers={Lining,Proportional}]{NewBaskervilleStd-Roman}
\setmathsf[Numbers=Lining,Scale=MatchLowercase]{Legacy Sans ITC Std Book}
Everything works except for the fact that digits in the command \mathsf are typeset in the serif typeface. I know this is related to having Digits in \setmathsfont, which selects the serif face, but I cannot remove it without getting the default typeface (cmr) for the numerals in "plain" math mode. If I don't use \setmathsfont, I get the default (cmr) for both letters and digits in math mode.
I have found the same issue described by somebody else on the Internet, but it seems he didn't get any answer. What would be a right way to solve this?