texmath 0.13.3.2 → 0.13.3.3
raw patch · 5 files changed
+10/−5 lines, 5 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- changelog.md +5/−0
- src/Text/TeXMath/Writers/Typst.hs +2/−2
- test/writer/typst/phantom.test +1/−1
- test/writer/typst/sphere_volume.test +1/−1
- texmath.cabal +1/−1
changelog.md view
@@ -1,3 +1,8 @@+texmath (0.13.3.3)++ * Typst writer: add some needed `$` inside `[..]` content blocks.+ This fixes bugs in scaling and phantom on typst (#303).+ texmath (0.13.3.2) * Typst writer: preserve lineless fractions (#302, Don Yin).
src/Text/TeXMath/Writers/Typst.hs view
@@ -244,11 +244,11 @@ writeExp (ECancel ForwardSlash e) = "cancel(" <> writeExp e <> ")" writeExp (ECancel BackSlash e) = "cancel(" <> writeExp e <> ", inverted: #true)" writeExp (ECancel XSlash e) = "cancel(" <> writeExp e <> ", cross: #true)"-writeExp (EPhantom e) = "#hide[" <> writeExp e <> "]"+writeExp (EPhantom e) = "#hide[$" <> writeExp e <> "$]" writeExp (EScaled size e) = "#scale(x: " <> tshow (floor (100 * size) :: Int) <> "%, y: " <> tshow (floor (100 * size) :: Int) <>- "%)[" <> writeExp e <> "]"+ "%)[$" <> writeExp e <> "$]" writeExp (EDelimited "(" ")" [ Right (EFraction NoLineFrac x y) ]) = "binom(" <> writeExp x <> ", " <> writeExp y <> ")" writeExp (EDelimited "(" ")" [Right (EArray _aligns rows)])
test/writer/typst/phantom.test view
@@ -7,4 +7,4 @@ ] ] >>> typst-(#hide[1 / 2])+(#hide[$1 / 2$])
test/writer/typst/sphere_volume.test view
@@ -128,6 +128,6 @@ >>> typst S = { 0 lt.eq phi.alt lt.eq 2 pi\,med 0 lt.eq theta lt.eq pi\,med 0 lt.eq rho lt.eq R } upright(V o l u m e) & = integral.triple_S #h(-0.167em) rho^2 sin theta thin upright(d) rho thin upright(d) theta thin upright(d) phi.alt\ & = integral_0^(2 pi) #h(-0.167em) upright(d) phi.alt thin integral_0^pi #h(-0.167em) sin theta thin upright(d) theta thin integral_0^R #h(-0.167em) rho^2 upright(d) rho\- & = phi.alt #scale(x: 180%, y: 180%)[\|]_0^(2 pi) med (- cos theta) #scale(x: 180%, y: 180%)[\|]_0^pi med 1 / 3 rho^3 #scale(x: 180%, y: 180%)[\|]_0^R\+ & = phi.alt #scale(x: 180%, y: 180%)[$\|$]_0^(2 pi) med (- cos theta) #scale(x: 180%, y: 180%)[$\|$]_0^pi med 1 / 3 rho^3 #scale(x: 180%, y: 180%)[$\|$]_0^R\ & = 2 pi times 2 times 1 / 3 R^3\ & = 4 / 3 pi R^3
texmath.cabal view
@@ -1,5 +1,5 @@ Name: texmath-Version: 0.13.3.2+Version: 0.13.3.3 Cabal-Version: 2.0 Build-type: Simple Synopsis: Conversion between math formats.