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

Allow use of CM (cm-super) #388

Closed
ViktorQvarfordt opened this issue Apr 29, 2017 · 13 comments
Closed

Allow use of CM (cm-super) #388

ViktorQvarfordt opened this issue Apr 29, 2017 · 13 comments

Comments

@ViktorQvarfordt
Copy link

ViktorQvarfordt commented Apr 29, 2017

I must be missing something, but why not support the font we all know and love? You'll tell me to use LM instead, well it does not give satisfactory results. Example:

CM: image

LM: image

Produced with xelatex and

\documentclass[a4paper]{article}
\usepackage{mathrsfs}
\begin{document}
$\mathcal{H}\mathscr{H}$
\end{document}

and

\documentclass[a4paper]{article}
\usepackage{unicode-math}
\begin{document}
$\mathcal{H}\mathscr{H}$
\end{document}

Besides the result being wrong, LM has terrible hinting (why?). Next you'll tell me to use another math font. I might respond with that font not going well with CM as I want for the text. But that's not the point: I don't want to use another math font, CM gives good results, lets support it!

Using the standard CM for unicode math input can be achieved by

\documentclass[a4paper]{article}
\usepackage{newunicodechar}
\newunicodechar{α}{\alpha}
\begin{document}
$α$
\end{document}

giving image as expected.

@davidcarlisle
Copy link
Member

davidcarlisle commented Apr 29, 2017 via email

@ViktorQvarfordt
Copy link
Author

Sure, but (not mockingly) who cares? Correct me if I'm wrong, but the purpose of unicode-math is to allow us to input unicode and get the expected output. As demonstrated, this is doable with CM. I'm certain that this is a wanted feature. Let's do it!

(Arguably, using a font that is not CM does not give the expected output. But I don't want to or need to use this line of argument, since my point is: People want CS. It can be done. Let's do it.)

@davidcarlisle
Copy link
Member

davidcarlisle commented Apr 29, 2017 via email

@ViktorQvarfordt
Copy link
Author

mathspec is the opposite of what I want, mathspec alters the output, I'm talking about altering the input yet having the same output.

what would you want unicode-math to do other than just quit and do nothing?

Allow me to write α in my source instead of \alpha and still get the standard LaTeX output (with CM font).

Perhaps this is not at all what unicode-math is about, then close this issue (and please explain to me why, because clearly one feature of unicode-math is to allow for α in the source instead of \alpha).

@davidcarlisle
Copy link
Member

davidcarlisle commented Apr 29, 2017 via email

@ViktorQvarfordt
Copy link
Author

Ok, I see.

Essentially nothing that Unicode-math does applies to a font that is not an OpenType math font.

Could we not extend the coverage of unicode-math then?

@davidcarlisle
Copy link
Member

davidcarlisle commented Apr 30, 2017 via email

@jfbu
Copy link
Contributor

jfbu commented Apr 30, 2017 via email

@ViktorQvarfordt
Copy link
Author

I might create such a package. Alphabeta is limited to only greek chars.

I'll start by just parsing https://raw.githubusercontent.com/wspr/unicode-math/master/unicode-math-table.tex.

However, in that file I see lots of non-standard definitions \muptau, and \BbbC, etc. Where do these come from? Suggestions for how to best translate them back to standard LaTeX?

@ViktorQvarfordt
Copy link
Author

I did it: https://github.com/ViktorQvarfordt/unicode-latex. Still WIP but all is there, it works. Except sub/superscripts, see the todo remark in the readme. Anyone knows how to implement parsing of ¹² to ^{12}?

If anyone likes this, I welcome all contribution and collaboration.

@wspr
Copy link
Collaborator

wspr commented May 2, 2017 via email

@wspr
Copy link
Collaborator

wspr commented May 2, 2017 via email

@wspr
Copy link
Collaborator

wspr commented May 2, 2017

To summarise, as @davidcarlisle mentioned, extending unicode-math to handle legacy maths is not really on the radar — so I'll close this issue now.

@wspr wspr closed this as completed May 2, 2017
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

4 participants