* Pandoc works with mhchem but not chemfig
@ 2022-01-19 12:10 Mujtaba Alam
0 siblings, 0 replies; only message in thread
From: Mujtaba Alam @ 2022-01-19 12:10 UTC (permalink / raw)
To: pandoc-discuss
[-- Attachment #1.1: Type: text/plain, Size: 1384 bytes --]
Hello,
I'm trying to use pandoc to convert files to html and pdf.
I have all the necessary libraries (mhchem and chemfig) installed on MikTex
(global installation, so it's in the Program Files folder). However, when I
run a pandoc command to convert to html, it seems to work with mhchem but
not chemfig.
Examples:
```
pandoc
$\ce{CO2 + C -> 2 CO}$
```
gives
```
[WARNING] Could not convert TeX math \ce{CO2 + C -> 2 CO}, rendering as TeX:
\ce{CO2 + C -> 2 CO}
^
unexpected control sequence \ce
expecting "%", "\\label", "\\tag", "\\nonumber" or whitespace
```
and
```
pandoc --mathjax
$\ce{CO2 + C -> 2 CO}$
```
gives
```
<p><span class="math inline">\(\ce{CO2 + C -> 2 CO}\)</span></p>
```
but
```
pandoc -s test1.md -f markdown+smart --mathjax -o test1.html
```
gives an html file with the mhchem (/ce) code correctly rendered but with
the chemfig (/chemfig) code rendered as plaintext, and the
"\usepackage{chemfig}" line ignored entirely.
--
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/a22f9312-c3c5-4454-bd38-6a504e08225cn%40googlegroups.com.
[-- Attachment #1.2: Type: text/html, Size: 2113 bytes --]
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2022-01-19 12:10 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-01-19 12:10 Pandoc works with mhchem but not chemfig Mujtaba Alam
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).