fontspec
fontspec copied to clipboard
SizeFeature works for opticals with LuaLaTeX but not XeLaTeX
Setting SizeFeature to load different opticals of a font works with LuaLaTeX but not XeLaTeX.
Here is a MWE:
\documentclass{article}
\usepackage{fontspec}
\newfontfamily\fonta[SizeFeatures={{Size={5-120},Font=* Display}}]{Minion Pro}
\newfontfamily\fontb[SizeFeatures={{Size={5-120},Font=* Subhead}}]{Minion Pro}
\newfontfamily\fontc[SizeFeatures={{Size={5-120},Font=*}}]{Minion Pro}
\newfontfamily\fontd[SizeFeatures={{Size={5-120},Font=* Caption}}]{Minion Pro}
\begin{document}
\fontsize{12}{14}
\fonta Test aAbBcCdDeEfFgG (Display)\par
\fontb Test aAbBcCdDeEfFgG (Subhead)\par
\fontc Test aAbBcCdDeEfFgG (Normal)\par
\fontd Test aAbBcCdDeEfFgG (Caption)\par
\end{document}
LuaLaTeX produces this:

While XeLaTeX outputs that:

This was discussed on TeX.SE a while ago, but is apparently sill an issue.