Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Character selection in scriptsize #627

Closed
projekter opened this issue Dec 27, 2023 · 1 comment
Closed

Character selection in scriptsize #627

projekter opened this issue Dec 27, 2023 · 1 comment

Comments

@projekter
Copy link

Description

I'm using the NewCMMath font, which provides a calligraphic and a script alphabet. The latter can be activated by choosing StylisticSet=1. However, the font does (currently) not provide glyphs for the \scriptsize and \scriptscriptsize versions of the script alphabet. As a consequence, even when StylisticSet=1 is activated, as soon as the size changes, the characters also change shape.

The font author writes

But unicode-math should see that the font does not provide these characters and scale the regular size when ss01 is selected.
Instead, it forces the scriptstyle characters even if it has to draw them from the default calligraphic.

Can the glyph selection process be adapted to deal with such a situation as the user would expect? This issue is kind of the opposite to #484, as here, XeTeX does the job correctly, only LuaTeX fails.

Add info or delete as appropriate:

  • Relevant for XeTeX - no
  • Relevant for LuaTeX - yes

Minimal example demonstrating the issue

\documentclass{article}
\usepackage{fontspec,unicode-math}
\setmathfont{NewCMMath-Regular.otf}[StylisticSet=1]
\begin{document}
   \[
     \displaystyle\symcal A \textstyle\symcal A \scriptstyle\symcal A \scriptscriptstyle\symcal A
   \]
\end{document}
@projekter
Copy link
Author

unicode-math seems to be innocent, this is the following bug: latex3/luaotfload#266. With the fix to the fontloader posted there, this is resolved even if the font does not provide the characters explictly; and if it does, it also selects them correctly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant