-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Make minus in <mn> produce U+2212 rather than U+002D. #989 #1526
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
Conversation
Since this came from the Content MathML extension's output, should we fix it there as well (or am I missing the fix from some earlier patch)?
I'm ok with that.
I don't mind either way. Perhaps it's more appropriate to be in v3.0 to have an explicit "tweak MathML" option (maybe a light-weight semantic enrichment module). |
Probably. It doesn't look like anything was done about that. I'll look into it further.
Yes, that sounds good.
I'm not sure how light-weight it is. The current arrangement does not change the internal MathML, only the MathML entered into the page. Thus the "Show Math As..." menu shows the natural MathML, not the MathML tweaked for the particular browser (e.g., the hack we have for FF to handle mlabeledtr for example). But I guess this is a different type of thing, where the input MathML can be improved. |
OK, I added code to convert |
MML.mn.Augment({ | ||
SVGremapMinus: function (text) {return text.replace(/^-/,"\u2212")}, | ||
toSVG: function () { | ||
this.SVGgetStyles(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indentation?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure I see the indentation problem here.
I'd suggest a single utility function for the replacement of minus. |
Do you mean the |
OK, I am fine with that. |
Make minus in
<mn>
produce U+2212 rather than U+002D. Resolve issue #989.This also tweaks the NativeMML output; should we do that? Or make a configuration parameter to prevent that?