git.iko.soy/typeable/pandoc
on master help sign in
Merge pull request #2295 from dev-zero/master

DokuWiki: write $..$ instead of <math>..</math>

commitdb989854d37179f590e41cbdd594dc92249779af authorJohn MacFarlane <jgm@berkeley.edu> dateMon 13 Jul 2015, 08:29 (11 years ago) parent2df3dfef464e49
2 files changed+8−8
src/Text/Pandoc/Writers/DokuWiki.hs+1−1 tests/writer.dokuwiki+7−7
src/Text/Pandoc/Writers/DokuWiki.hs+1−1
@@ -451,7 +451,7 @@ inlineToDokuWiki _ (Code _ str) =
451451
452452inlineToDokuWiki _ (Str str) = return $ escapeString str
453453
454−inlineToDokuWiki _ (Math _ str) = return $ "<math>" ++ str ++ "</math>"
454+inlineToDokuWiki _ (Math _ str) = return $ "$" ++ str ++ "$"
455455 -- note: str should NOT be escaped
456456
457457inlineToDokuWiki _ (RawInline f str)
tests/writer.dokuwiki+7−7
@@ -454,13 +454,13 @@ Ellipses…and…and….
454454====== LaTeX ======
455455
456456 *
457− * <math>2+2=4</math>
458− * <math>x \in y</math>
459− * <math>\alpha \wedge \omega</math>
460− * <math>223</math>
461− * <math>p</math>-Tree
462− * Here’s some display math: <math>\frac{d}{dx}f(x)=\lim_{h\to 0}\frac{f(x+h)-f(x)}{h}</math>
463− * Here’s one that has a line break in it: <math>\alpha + \omega \times x^2</math>.
457+ * $2+2=4$
458+ * $x \in y$
459+ * $\alpha \wedge \omega$
460+ * $223$
461+ * $p$-Tree
462+ * Here’s some display math: $\frac{d}{dx}f(x)=\lim_{h\to 0}\frac{f(x+h)-f(x)}{h}$
463+ * Here’s one that has a line break in it: $\alpha + \omega \times x^2$.
464464
465465These shouldn’t be math:
466466