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
Incorrect latex generated for \notsubset in editor #790
Comments
Is there some visual difference between \notsubset and \not\subset? Or are you just concerned that that LaTeX is being transformed (normalized) and you weren't expecting that? |
The original symbol is a subset symbol with a line through it. The resultant latex generates a separate "not" and "subset" symbol. It looks like there is some code that is finding subwords in symbol names when generating latex, but I would assume it is already in some tree representation that should have a clear separation between different symbols. So it seems odd that anything would need to be parsed out of the in memory representation to generate the latex. |
I realized this isn't incorrect latex, it is a compound symbol that isn't being recognized by the parser. The proper latex for the symbol is \not\subset, but these two commands together should become one symbol. Will try to take a look at the parser soon to understand how to fix it. @laughinghan is there support for other cases like this in the parser today that I could look at? |
This is also an issue for all of the number sets like \R, \N, \Z |
Part of this was fixed here the symbols for sets of numbers like \R, \N, \Z - #910 Still need to fix all of the symbols that have a preceding \not, there are several beyond \not\subset. Testing things out on overleaf, it appears you can put a \not before just about any symbol to get a version of it with a line through it. So for compatibility with Latex we may want to look at implementing this in a generic way while fixing it, rather than just fixing it for the few symbols with unicode versions of the symbols with a slash through them. For example, while the spacing kind of sucks, this is apparently valid latex. \not a |
And if we do decide to go that route, this is then kind of related to implementing \cancel #953 |
Calling .latex() on a Mathquill editor that contains \notsubset will generate \not \subset.
Planning on trying to debug into the library to try to find a cause, but thought it was worth reporting as I saw it.
The text was updated successfully, but these errors were encountered: