I just don't understand why pandoc can produce the right output directly from markdown, but not intermediately through latex. It should be possible to get the intermediate latex representation that also compiles with pandoc. You're right, I could use pdflatex, I'm just puzzled at why it works for md to pdf then.

On Monday, 2 July 2018 10:08:33 UTC+2, Christophe Demko wrote:
pandoc does not interpret all LaTeX commands. Don't use pandoc if you want to compile a LaTeX file

Le dimanche 1 juillet 2018 13:34:37 UTC+2, Gandalf Saxe a écrit :
It does not work; try to copy the second example above into a test.tex and run:

pandoc test.tex -o test.pdf

It will not color any of the text. pdflatex will work fine though, so something happens with using pandoc.

On Friday, 29 June 2018 16:52:45 UTC+2, Christophe Demko wrote:
The LaTeX code is convert correctly to pdf with correct colors

Le jeudi 28 juin 2018 16:59:43 UTC+2, Gandalf Saxe a écrit :
Why does this convert correctly `pandoc test.md -o test.pdf`:

---
header
-includes: \usepackage{xcolor}
---


This is normal content, \textcolor{orange}{warning content} and
\textcolor{red}{important content}.




But this doesn't ``:
\documentclass[]{article}
\usepackage{xcolor}


\begin{document}


This is normal content, \textcolor{orange}{warning content} and
\textcolor{red}{important content}.


\end{document}




That is, the content is completely the same, but it works from markdown, but just not from latex?

A little ironic since the syntax is latex :)

--
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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/7e3ddc50-55c9-4ee0-950e-555c1e98385c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.