johnfactotum / foliate

Read e-books in style
https://johnfactotum.github.io/foliate/
GNU General Public License v3.0
5.25k stars 254 forks source link

Equation render problem #1325

Closed samuel-cavalcanti closed 4 weeks ago

samuel-cavalcanti commented 1 month ago

Describe the bug Foliate doesn't render the equation correctly

Expected behavior See the equation

Screenshots

image

Expected image

Version:

Additional context The book: Hands-On Machine Learning with Scikit-Learn, Keras, and TensorFlow: Concepts, Tools, and Techniques to Build Intelligent Systems

samuel-cavalcanti commented 1 month ago

Amazing app btw !!

johnfactotum commented 1 month ago

Works fine for me. It's probably a problem with fonts. MathML won't render properly if the font doesn't support math. Unless you're overriding the font family with user styles, MathML would be rendered with a math font with the browser engine's stylesheet. So the problem is probably that you don't have one installed and it's falling back to a non-math font. You can use the inspector (F12) to see which font is using.

samuel-cavalcanti commented 4 weeks ago

image

image seems the correct font is rendering to me

samuel-cavalcanti commented 4 weeks ago

I never tooth in the foliate configuration until now. I tried to switch the Override Publisher Font but it doesn't work

samuel-cavalcanti commented 4 weeks ago

FIx: install extra/otf-latinmodern-math

sudo pacman -S otf-latinmodern-math

you maybe should but that as a dependence