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

\symliteral not resulting in correct output of literal input #615

Open
jasperhabicht opened this issue Jun 23, 2023 · 1 comment
Open

\symliteral not resulting in correct output of literal input #615

jasperhabicht opened this issue Jun 23, 2023 · 1 comment

Comments

@jasperhabicht
Copy link

The package manual (version 0.8q, 2020/01/31) says on page 12:

The \symliteral{⟨syms⟩} command can also be used, regardless of package setting, to force the style to match the literal input characters.

Hence, I would assume that if I set the package option to math-style=ISO, which renders uppercase latin letters (sans and serif) in italic, \symliteral{𝖤} (where 𝖤 is U+1D5A4, i.e. an upright glyph) should output an upright letter. However, the following example shows that this is not the case and the same (italic) glyph is printed twice in the output:

\documentclass{article} 
\usepackage[math-style=ISO]{unicode-math} 

\begin{document} 
$𝖤 \symliteral{𝖤}$ 
\end{document}

Which should be equivalent to:

\documentclass{article} 
\usepackage[math-style=ISO]{unicode-math} 

\begin{document} 
$\char"1D5A4 \symliteral{\char"1D5A4}$ 
\end{document}

image

From the description in the documentation I would assume that the second letter is printed upright.


By the way, I am not at all sure whether it is a good choice to have the package normalize letters from the "Mathematical Alphanumeric Symbols" Unicode block (and related glyphs), since these code points are designed to semantically distinguish different mathematical symbols. So, in my opinion, if the user enters a code point from this Unicode block directly, it should be kept this way, not matter what the setting of the document style is. But I take it that the package authors took into consideration a lot of aspects, so maybe the current choice is still tbe best.

@jasperhabicht jasperhabicht changed the title \symliteral not resulting in correct output of literal input \symliteral not resulting in correct output of literal input Jun 23, 2023
@davidcarlisle
Copy link
Member

I think it would be much more natural if the math-style option (and \symb..) only affected the mapping of the base plane to the math alphabets. The current default that a bold italic 𝒙 is typeset upright is hard to reconcile with the Unicode description and is at odds with mathml and other uses of the fonts where <mi mathvariant="anything">𝒙</mi> is always 𝒙 (math-style=literal doesn't really help here, as it prevents $xyz$ being math italic.)

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

2 participants