Comments (5)
The default MathJax fonts don't include the U+224C character, so that is why you get a <text>
element for that. You re correct that it will look different in different fonts, and MathJax won't know how much space to leave for it, so that is not optimal.
There are two possible solutions. First, you could switch to the STIX-web font rather than the default MathJax fonts, since they include many more characters, includuing U+224C. Then define cong: '\u224C'
(do not use the braces as that will alter the spacing).
Alternatively, if you want to stick with the default MathJax fonts, you could use
cong: '\\stackrel{\\Large\\lower.2em\\backsim}{\\lower.1em=}'
which will use the back-sim character over an equal sign. That will give you a symbol that looks correct, but will not be read correctly by screen readers.
from mathjax-node.
@dpvc We have tested the font "STIX-web", the congruent symbol "≌" is normal, but the rendered other letter styles do not meet the requirements.
Default Font ( Tex ):
STIX-web Font:
Using "stackrel" mode, the display is normal in SVG and abnormal in web page.
Finally, we adopt the "stackrel" approach to solve the SVG problem first. As for the web page, we will not make any changes for the time being.
Thank you very much. ^_^
from mathjax-node.
Note that mathjax-node uses MathJax version 2, while the mathjax.org website uses MathJax version 3. Apparently, there is some inconsistency in the layout of \stackrel
between the two versions. I will need to check into that. Since you were using MathJax-node, I gave you a version 2 solution. Are you using version 3 in your website? If so, you could use
\stackrel{\raise.03em{\Large\backsim}}{\smash{\lower.1em=}}
for SVG output. There also seems to be inconsistency between the SVG and CHTML output (in both v2 and v3). If you use CHTML output in v3, you should need to use
\stackrel{\lower.2em{\Large\backsim}}{\smash{\lower.1em=}}
instead.
from mathjax-node.
I see. Thank you very much!
from mathjax-node.
I forgot to mention:
the rendered other letter styles do not meet the requirements.
Not everyone likes the look of the STIX fonts, and they are different from the default MathJax TeX fonts, which are based on the TeX Computer Modern fonts (whereas STIX is supposed to be compatible with the Times font, if I recall correctly). But they do have the advantage of having much greater character coverage, so they help when you want to use characters that aren't in the MathJax TeX fonts. It is a choice you have to make one way or the other.
from mathjax-node.
Related Issues (20)
- how to set it to a transparent background? HOT 1
- Do mathjax-node support MathJax@3 HOT 2
- Mathjax- node:Latex Error converting latex to SVG with "\ \ [" HOT 3
- Cannot read property 'childNodes' of null HOT 3
- '\nolimits is allowed only on operators' which render right in mathjax v3 HOT 2
- width of svg is too small HOT 2
- Unknown node type "mstack" HOT 1
- Cannot get the same result with mathjax-node as with MathJax on the browser HOT 7
- Undefined control sequence even after defining it HOT 2
- "Error: TeX parse error: Missing \end{array}" HOT 2
- MathJax on Linkedom.. HOT 2
- Vercel - Error: Could not load script: "file:///var/task/node_modules/mathjax/unpacked/jax/element/mml/jax.js?V=2.7.9" HOT 5
- Correct mapping for prime symbol HOT 3
- MathJax node does not work with HTML HOT 4
- Cannot read properties of null (reading 'childNodes') HOT 4
- how to fix “missing open brace on subscript”? HOT 6
- use 'tex2svg' cannot generate formula correctly HOT 1
- Setting background-color style to SVG element HOT 1
- Update dependancy to MathJax 3 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mathjax-node.