MathView icon indicating copy to clipboard operation
MathView copied to clipboard

LaTeX not working on MathJax android 4.0

Open grapevine2383 opened this issue 10 years ago • 9 comments

LaTeX isn't working in MathJax MathView when using Android API 15 emulator with the sample app example.

grapevine2383 avatar Jan 03 '16 22:01 grapevine2383

I am sorry but I haven't tested it in lower version API. Could you please provide screenshots and logcat information? I am not able to reproduce it.

jianzhongli avatar Jan 05 '16 03:01 jianzhongli

2016-01-04_21-29-01 2016-01-04_21-29-11 2016-01-04_21-31-53

grapevine2383 avatar Jan 05 '16 05:01 grapevine2383

Using the simulator with the sample app (no changes at all)

grapevine2383 avatar Jan 05 '16 05:01 grapevine2383

  1. Perhaps it has something to do with the mathjax configuration. Have you ever try lower version of MathView? (MathView 0.0.1 ~ 0.0.3 doesn't support the engine attribute, it renders tex code with mathjax by default.)
  2. Do you really need to use MathView(with MathJax) on Android 4.1 ? If KaTeX can meet your requirement, please just use KaTeX to render tex code.

jianzhongli avatar Jan 05 '16 08:01 jianzhongli

  1. I just tried 0.0.1, 0.0.2, and 0.0.3 and found that 0.0.3 actually works but the other ones do not.
  2. KaTeX doesn't support many many things that MathJax does, I tried it out but got parsing errors pretty frequently.

What was changed in 0.0.3 from 0.0.2 and 0.04 that fixed then broke compatibility with android 4.0?

grapevine2383 avatar Jan 05 '16 17:01 grapevine2383

Looks like adding MathML support in MathJax is what broke it https://github.com/kexanie/MathView/commit/b35b0c07f2c77b8be64a32dbd6f5a4ffb0482c8f

grapevine2383 avatar Jan 05 '16 17:01 grapevine2383

I was wrong.

KaTeX was added to MathView as the default engine since 0.0.3, so if it works on Android 4.0, I think that's because you were actualy using KaTeX to render the code. It seems that the distribution of MathJax shipped with MathView just doesn't work on Android 4.0. I found an sample app of MathJax on GitHub, which is perfectly functional on Android 4.0.

If we dig deeper it should be possible to make MathView works on lower android version. This issue will remain open until the bug is fixed. If you figure out how to fix it, pull requests are always welcomed.

jianzhongli avatar Jan 06 '16 10:01 jianzhongli

What do you think needs to be changed in order to be compatible with android 4.0. Is it just a configuration issue?

grapevine2383 avatar Jan 06 '16 20:01 grapevine2383

Can you help me with this problem, I'm writing a math text in arabic, and there are some inline equations that need to be aligned to the right. I need the mathview to be displayed in RTL mode.

makhloufabdelkader avatar Jan 10 '17 17:01 makhloufabdelkader