MathJax block equations requires horizontal scrolling

Today I converted a few of my math-heavy cards to use MathJax instead of Latex, and oh boy what a difference! On my iPad Pro I don’t have to squint anymore whenever my math cards show up, it’s super crisp! And the inline equations suddenly look much(!) better where they actually line up with the text. Perfect!

But…I then opened the cards on my Android phone, with a smaller screen and lower resolution, which exposed something really ugly: The equations that are a little longer, usually containing some words, doesn’t scale down horizontally to fit the phone display. This was a bummer.

For very short block equations I can safely use MathJax, my phone can display them fully without needing scrolling. But when creating cards I don’t want to focus on whether equations will fit or not on my phone.

It would also be nice to get rid of my huge collection of Latex-png’s, by using MathJax.

This screenshot is taken from my PC, but mimics almost how it would look on my phone:

Any ideas?

Not supported yet I’m afraid: Automatic Line Breaking — MathJax 3.1 documentation

Thanks for reply.

Yes I guess an automatic line break would work, even better would be to somehow automatically scale down the font size whenever the equation stretches outside the view, just like images scale down. The benefit with MathJax though is that even with a scale it would still look crisp on all screens.

I did some searching after my post and I found a lot of people, outside the Anki sphere, seeking the same feature as I do for MathJax.

In the meantime I’ve found a future-proof workaround: I will write all equations (inline and block) in MathJax, and mark the ones that are to big for my phone so that I can convert them to Latex on Anki Desktop.

Glad to hear you’ve found a workaround for now, and hopefully MathJax will provide better solutions for this in the future.

1 Like