texmath 0.12.8.1 → 0.12.8.2
raw patch · 6 files changed
+37/−43 lines, 6 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- changelog +5/−1
- man/man1/texmath.1 +27/−39
- src/Text/TeXMath/Writers/Typst.hs +2/−0
- test/writer/typst/binomial_coefficient.test +1/−1
- test/writer/typst/choose.test +1/−1
- texmath.cabal +1/−1
changelog view
@@ -1,6 +1,10 @@+texmath (0.12.8.2)++ * Typst writer: use binom instead of a fraction (jgm/pandoc#9063).+ texmath (0.12.8.1) - * Typst Writer: several fixes (#223, Lleu Yang).+ * Typst writer: several fixes (#223, Lleu Yang). + Escape quotes (") in inQuotes + Accent `\8407` corresponds to `arrow()`
man/man1/texmath.1 view
@@ -1,58 +1,46 @@+.\" Automatically generated by Pandoc 3.1.7+.\" .TH "texmath" "1" "July 22, 2014" "texmath manual" "" .SH NAME-.PP-texmath \- convert between math formats.+texmath - convert between math formats. .SH SYNOPSIS-.PP-texmath [\f[I]options\f[]] [file*]+texmath [\f[I]options\f[R]] [file*] .SH DESCRIPTION-.PP-\f[C]texmath\f[] acts as a pipe, reading from stdin or from the+\f[CR]texmath\f[R] acts as a pipe, reading from stdin or from the specified files and writing to stdout.-It converts math in the specified input format (see \f[C]\-f\f[] below)-to math in the specified output format (see \f[C]\-t\f[] below).+It converts math in the specified input format (see \f[CR]-f\f[R] below)+to math in the specified output format (see \f[CR]-t\f[R] below). .PP-If \f[C]texmath\f[] is invoked under the name \f[C]texmath\-cgi\f[] (via-a symbolic link, or through simple renaming), it will act as a CGI+If \f[CR]texmath\f[R] is invoked under the name \f[CR]texmath-cgi\f[R]+(via a symbolic link, or through simple renaming), it will act as a CGI script.-It will expect query parameters for \f[C]from\f[], \f[C]to\f[],-\f[C]input\f[], and optionally \f[C]inline\f[], and return a JSON object-with either \f[C]error\f[] and a message or \f[C]success\f[] and the-converted result.+It will expect query parameters for \f[CR]from\f[R], \f[CR]to\f[R],+\f[CR]input\f[R], and optionally \f[CR]inline\f[R], and return a JSON+object with either \f[CR]error\f[R] and a message or \f[CR]success\f[R]+and the converted result. .SH OPTIONS .TP-.B \f[C]\-f\f[] \f[I]FORMAT\f[]-Specify input ("from") format: \f[C]tex\f[], \f[C]mathml\f[],-\f[C]omml\f[], \f[C]native\f[].-Defaults to \f[C]tex\f[].-.RS-.RE+\f[CR]-f\f[R] \f[I]FORMAT\f[R]+Specify input (\[lq]from\[rq]) format: \f[CR]tex\f[R],+\f[CR]mathml\f[R], \f[CR]omml\f[R], \f[CR]native\f[R].+Defaults to \f[CR]tex\f[R]. .TP-.B \f[C]\-t\f[] \f[I]FORMAT\f[]-Specify output ("to") format: \f[C]tex\f[], \f[C]omml\f[],-\f[C]xhtml\f[], \f[C]mathml\f[], \f[C]pandoc\f[], \f[C]native\f[].-Defaults to \f[C]mathml\f[].-.RS-.RE+\f[CR]-t\f[R] \f[I]FORMAT\f[R]+Specify output (\[lq]to\[rq]) format: \f[CR]tex\f[R], \f[CR]omml\f[R],+\f[CR]xhtml\f[R], \f[CR]mathml\f[R], \f[CR]pandoc\f[R],+\f[CR]native\f[R].+Defaults to \f[CR]mathml\f[R]. .TP-.B \f[C]\-\-inline\f[]+\f[CR]--inline\f[R] Use the inline display style.-.RS-.RE .TP-.B \f[C]\-h,\ \-\-help\f[]+\f[CR]-h, --help\f[R] Print usage information.-.RS-.RE .TP-.B \f[C]\-V,\ \-\-version\f[]+\f[CR]-V, --version\f[R] Print version.-.RS-.RE .SH AUTHORS-.PP John MacFarlane, Matthew Pickering, Jesse Rosenthal. .SH SEE ALSO-.PP-The \f[C]texmath\f[] source code and all documentation may be downloaded-from <http://github.com/jgm/texmath/>.+The \f[CR]texmath\f[R] source code and all documentation may be+downloaded from <http://github.com/jgm/texmath/>.
src/Text/TeXMath/Writers/Typst.hs view
@@ -212,6 +212,8 @@ "#scale(x: " <> tshow (floor (100 * size) :: Int) <> "%, y: " <> tshow (floor (100 * size) :: Int) <> "%)[" <> writeExp e <> "]"+writeExp (EDelimited "(" ")" [ Right (EFraction NoLineFrac x y) ]) =+ "binom(" <> writeExp x <> ", " <> writeExp y <> ")" writeExp (EDelimited "(" ")" [Right (EArray _aligns rows)]) | all (\row -> length row == 1) rows = -- vector "vec(" <> mkArray (transpose rows) <> ")"
test/writer/typst/binomial_coefficient.test view
@@ -40,4 +40,4 @@ ]) ] >>> typst-bold(C) lr((n comma k)) eq bold(C)_k^n eq zws_n bold(C)_k eq lr((n / k)) eq frac(n excl, k excl thin lr((n minus k)) excl)+bold(C) lr((n comma k)) eq bold(C)_k^n eq zws_n bold(C)_k eq binom(n, k) eq frac(n excl, k excl thin lr((n minus k)) excl)
test/writer/typst/choose.test view
@@ -18,4 +18,4 @@ ] ] >>> typst-lr((a / lr({frac(b, c plus 2)})))+binom(a, lr({frac(b, c plus 2)}))
texmath.cabal view
@@ -1,5 +1,5 @@ Name: texmath-Version: 0.12.8.1+Version: 0.12.8.2 Cabal-Version: >= 1.10 Build-type: Simple Synopsis: Conversion between math formats.