Kolaru / MathTeXEngine.jl

A latex math mode engine in pure Julia.
MIT License
97 stars 19 forks source link

Fix superscript and subscript position #90

Closed Kolaru closed 1 year ago

Kolaru commented 1 year ago

Fix #86

@AshtonSBradley Do you think this looks correct now ?

image

codecov-commenter commented 1 year ago

Codecov Report

Base: 78.97% // Head: 77.10% // Decreases project coverage by -1.87% :warning:

Coverage data is based on head (537bdc5) compared to base (980c338). Patch coverage: 0.00% of modified lines in pull request are covered.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #90 +/- ## ========================================== - Coverage 78.97% 77.10% -1.88% ========================================== Files 7 7 Lines 490 498 +8 ========================================== - Hits 387 384 -3 - Misses 103 114 +11 ``` | [Impacted Files](https://codecov.io/gh/Kolaru/MathTeXEngine.jl/pull/90?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Beno%C3%AEt+Richard) | Coverage Δ | | |---|---|---| | [src/engine/layout.jl](https://codecov.io/gh/Kolaru/MathTeXEngine.jl/pull/90/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Beno%C3%AEt+Richard#diff-c3JjL2VuZ2luZS9sYXlvdXQuamw=) | `90.22% <ø> (ø)` | | | [src/engine/texelements.jl](https://codecov.io/gh/Kolaru/MathTeXEngine.jl/pull/90/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Beno%C3%AEt+Richard#diff-c3JjL2VuZ2luZS90ZXhlbGVtZW50cy5qbA==) | `70.23% <0.00%> (-11.35%)` | :arrow_down: | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Beno%C3%AEt+Richard). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Beno%C3%AEt+Richard)

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

AshtonSBradley commented 1 year ago

Looks great!

This could be amplified in certain tests, and/or could be font specific:

fourth one looks a little cramped, would normally render with a little more space

image

If it helps, this is what mathpix generates, slight variations in spacing but pretty close (last two on your list are identical)

image

Kolaru commented 1 year ago

Just fixed #88 too

Kolaru commented 1 year ago

@AshtonSBradley Thanks for your feedback. I have very slightly changed it, I think it is otherwise a font difference (I can't get to understand the logic otherwise).

image