Raw LaTeX: latex commands with multiple parameters not supported #2592
randomizedthinking
commented
+++ randomizedthinking [Dec 16 15 14:13 ]:
Is it possible that pandoc adds support to the construction of
consecutive parameters, and simply pass them to latex? It is uncommon
to have constructions in the normal markdown text
That sounds like a reasonable request to me.
Wait! What version of pandoc are you using?
Recent versions allow indefinitely many parameters:
% pandoc -t latex
\mylatexcmd{a}{b}{c}
^D
\mylatexcmd{a}{b}{c}
So you probably just need to upgrade.
It won't work for parameters spanning over multiple lines.
% echo -e "\mylatexcmd{a}\n{b}{c}" | pandoc -t latex
\mylatexcmd{a} \{b\}\{c\}
My example at first is not precise... sorry. Do you think keeping parsing
the text over multiple lines is reasonable?
Thanks!
…
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I would like to define some latex commands to complement the description power of markdown. Given their natures, these commands usually take more than one parameter. Under the current pandoc implementation, only the first parameter is passed to the command, and the rest parameters are treated as markdown instead. For instance,
The curly braces are escaped in the generated tex file.
Is it possible that pandoc adds support to the construction of consecutive parameters, and simply pass them to latex? It is uncommon to have constructions in the normal markdown text.