Skip to content

Cant get diagram.lua to work with tikz #46

@MoritzBeroRoos

Description

@MoritzBeroRoos

Hi, im sorry but i have to ask if i miss something obvious.
What i have done on a fresh ubuntu system:

  • installed pandoc and verfied that it works
  • install texlive-latex-base and verify that pdflatex works from the command line
  • install inkscape and verify that the inkscape command works from the command line (for me it opens the program)
  • downloaded the file diagram.lua and put it in my home directory along with the following input.tex:

My input.tex

Some math $x^2$.
Here is a circle:
\begin{tikzpicture}
 \draw (0,0) circle (1in);
\end{tikzpicture}
             
Some more  math $\mathbb{R}$.

Now i call pandoc like this

pandoc input.tex -o output.html -f latex -t html --embed-resources --lua-filter=diagram.lua

Expected outcome:
An output.html file containg an svg div.

Actual outcome:
output.html

<p>Some math <span class="math inline"><em>x</em><sup>2</sup></span>.
Here is a circle:</p>
<p>Some more math <span class="math inline"></span>.</p>

There is no image clue to be seen. Also the conversion is extremely fast, which makes me doubt that inkscape has been used.
(if i start inkscape as a gui it takes a few seconds). I get no errors or warnings that i can see.
Also i get the exact same output file if i leave the filter out completely:

pandoc input.tex -o output.html -f latex -t html --embed-resources

Is there something i have to install to use this package?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions