kmwallio / ThiefMD

The markdown editor worth stealing. Inspired by Ulysses, based on code from Quilter
https://thiefmd.com/
GNU General Public License v3.0
151 stars 8 forks source link

Math Rendering Improperly Renders Super and Subscripts #56

Open johnblommers opened 4 years ago

johnblommers commented 4 years ago

The following examples:

$$f(x)=a_0+a_2x^2$$

$$x_{1,2}=\frac{-b\pm\sqrt{b^2-4ac}}{2a}$$

render badly as shown below:

Screenshot from 2020-10-08 21-00-41

The proper rendering is:

Screenshot from 2020-10-08 21-03-24

kmwallio commented 4 years ago

This is fixed in the beta branch with the ability to change the preview and export CSS.

math-css

It will be included in the next release.

I'm currently torn between having the default CSS be no-styling, or keeping the current one that breaks math rendering. Feel free to let me know your thoughts. It's not immediately discoverable, so I'm leaning towards a more basic default style.

johnblommers commented 3 years ago

As of ThiefMD 0.1.2 this issue persists in the live preview.

The good news is that math formulas render fine in the export preview.

Good job keeping those updates coming!

kmwallio commented 3 years ago

Thanks! I'm still working on new default CSS. We started work on Export CSS support. This will adjust the default preview if you choose none or pick a different theme.

export_preferences

johnblommers commented 3 years ago

Excellent! Thanks for the tip.