Skip to content

pandoc escapes latex in docbook source #2422

Closed
everflux opened this Issue · 3 comments

2 participants

@everflux

I have an asciidoc document that contains latex symbols and formulas.
Since pandoc does not support asciidoc input I export the asciidoc to docbook xml and use that as source for pandoc. This works good so far, except that I can not get latex formulas working.
I tried tex_raw, tex_math_dollars, but pandoc always escapes the formula like

lambda: \$1+ \textbackslash{}lambda\$

expected was

lambda: $1+\lambda$

Is this a bug or is there a way to get pandoc accept latex formulas inside docook?

@jgm
Owner
@everflux

Actually I tried to trick pandoc by not using mathlatex in asciidoc, but plain latex which is retained in docbook:

<simpara>lambda $1+ \lambda$</simpara>

But this gets escaped by pandoc when generating the latex source for the output.
When using mathlatex in asciidoc it seems to be rendered as an image which is then not found by latex called by pandoc.

@jgm
Owner

Try

pandoc -f docbook -t markdown-tex_math_dollars
@jgm jgm closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.