iclc / iclc-templates

Templates for paper submissions, technical questionnaires, etc.
Creative Commons Zero v1.0 Universal
14 stars 10 forks source link

Error while generating PDF from markdown using pandoc #5

Closed j0py closed 1 month ago

j0py commented 1 month ago

$ pandoc --template=pandoc/iclc.latex --citeproc --number-sections iclc2025.md --pdf-engine=xelatex -o iclc2025x.pdf Error producing PDF. ! Undefined control sequence. l.323 parameters \out

make: *** [Makefile:16: iclc2025x.pdf] Error 43

In my iclc2025.md i have parts of code in between the code characters that contains strings like "\out", which is the notation for a Symbol in SuperCollider. If i remove the backslash from (some of) these "\out" strings, then the PDF is generated without errors.

Also in the normal text i sometimes have strings starting with a backslash. These also give the same kind of error messages. I think the backslash is the culprit here. I do not know about LaTex but it seems to contain lots of backslashes, so these probably mean something. Or they mean something in a PDF.

Funny though: the HTML and DOCX i can generate with my original md file, which contains the backslashes. Only the PDF generation gives the error message!

How can i have backslashes in my markdown without interfering with the generation of the PDF?

tmhglnd commented 1 month ago

I think the workaround is to not type \out in your text, but instead wrap it in single backticks so it is rendered as a short code-snippet: `\out`

the-drunk-coder commented 1 month ago

Is it in larger code blocks? or inline?

j0py commented 1 month ago

In both, and not only \out, but also \panbus or other symbol sometimes trigger the error. But first i will try what Timo suggests.On Sep 18, 2024 08:42, the-drunk-coder @.***> wrote: Is it in larger code blocks? or inline?

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you authored the thread.Message ID: @.***>

tmhglnd commented 1 month ago

For me the \out doesn't give an error when using block code with ``` some code ```. I can reproduce the error when \out inline. For me the error is fixed when using `\out`.

j0py commented 1 month ago

I confirm: using \out solves the problem and the PDF is generated without the error. Thanks!

Op 18-09-2024 09:53 CEST schreef Timo @.***>:

For me the \out doesn't give an error when using block code with some code. I can reproduce the error when \out inline. For me the error is fixed when using \out.

— Reply to this email directly, view it on GitHub https://github.com/iclc/iclc-templates/issues/5#issuecomment-2357757895, or unsubscribe https://github.com/notifications/unsubscribe-auth/AWOBQYPV37KQFIMIICJRSH3ZXEWRLAVCNFSM6AAAAABOMDZKQ2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGNJXG42TOOBZGU. You are receiving this because you authored the thread.Message ID: @.***>