# MathJax block equations requires horizontal scrolling

**URL:** <https://forums.ankiweb.net/t/mathjax-block-equations-requires-horizontal-scrolling/7981>\
**Category:** Card Design\
**Created:** [March 3, 2021, 3:05pm UTC](https://forums.ankiweb.net/t/mathjax-block-equations-requires-horizontal-scrolling/7981 "2021-03-03T15:05:19Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![ankipanki](https://sea2.discourse-cdn.com/flex002/user_avatar/forums.ankiweb.net/ankipanki/32/3243_2.png) [@ankipanki](https://forums.ankiweb.net/u/ankipanki)\
**Post date:** [March 3, 2021, 3:05pm UTC](https://forums.ankiweb.net/t/mathjax-block-equations-requires-horizontal-scrolling/7981/1 "2021-03-03T15:05:19Z")

</div>

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:  
 ![image](https://us1.discourse-cdn.com/flex002/uploads/anki2/original/2X/8/89e90bf5cc61b9ea608e51a2a3daf9356d9fe1c6.png)

Any ideas?

---

<div class="post-metadata">

**Author:** ![dae](https://sea2.discourse-cdn.com/flex002/user_avatar/forums.ankiweb.net/dae/32/65_2.png) [@dae](https://forums.ankiweb.net/u/dae)\
**Post date:** [March 4, 2021, 12:52am UTC](https://forums.ankiweb.net/t/mathjax-block-equations-requires-horizontal-scrolling/7981/2 "2021-03-04T00:52:59Z")

</div>

Not supported yet I’m afraid: [Automatic Line Breaking — MathJax 3.1 documentation](http://docs.mathjax.org/en/latest/output/linebreaks.html)

---

<div class="post-metadata">

**Author:** ![ankipanki](https://sea2.discourse-cdn.com/flex002/user_avatar/forums.ankiweb.net/ankipanki/32/3243_2.png) [@ankipanki](https://forums.ankiweb.net/u/ankipanki)\
**Post date:** [March 4, 2021, 2:09pm UTC](https://forums.ankiweb.net/t/mathjax-block-equations-requires-horizontal-scrolling/7981/3 "2021-03-04T14:09:07Z")

</div>

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.

---

<div class="post-metadata">

**Author:** ![dae](https://sea2.discourse-cdn.com/flex002/user_avatar/forums.ankiweb.net/dae/32/65_2.png) [@dae](https://forums.ankiweb.net/u/dae)\
**Post date:** [March 5, 2021, 8:18am UTC](https://forums.ankiweb.net/t/mathjax-block-equations-requires-horizontal-scrolling/7981/4 "2021-03-05T08:18:20Z")

</div>

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

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex002/uploads/anki2/original/1X/8f1279ababc5879d54e4838989f606cfe55af8c7.jpeg) [@system](https://forums.ankiweb.net/u/system)\
**Post date:** [May 1, 2023, 7:41am UTC](https://forums.ankiweb.net/t/mathjax-block-equations-requires-horizontal-scrolling/7981/5 "2023-05-01T07:41:24Z")

</div>


