Code Monkey home page Code Monkey logo

Comments (4)

lurch avatar lurch commented on August 15, 2024

It might be worth trying to narrow down your testcase and identify exactly which of the STEM snippets isn't working? The simpler the testcase, the easier it'll be for the developers to debug it.

from asciidoctor-mathematical.

lurch avatar lurch commented on August 15, 2024

... I had a bit of spare time this evening, so I decided to have a go at creating my own minimal test case 😉

I'm not using the docker container, but these locally-installed versions: (according to gem info)
asciidoctor (2.0.10)
asciidoctor-mathematical (0.3.1)

With the (simpler) test-file below, the symbols next to "Omega 1", "Omega 2" and "Omega 4" get displayed correctly, but the symbol next to "Omega 3" doesn't get displayed.

:stem: latexmath

Omega 1:
[stem]
++++
\Omega
++++

Omega 2:
[stem]
++++
 \Omega 
++++

Omega 3:
stem:[ \Omega ]

Omega 4:
stem:[\Omega]

I'm using the command asciidoctor --trace -r asciidoctor-mathematical -a mathematical-format=svg test.adoc, and as above the only error-output on the command-line is Failed to parse mtex.

from asciidoctor-mathematical.

jfernandz avatar jfernandz commented on August 15, 2024

@lurch I'm having a similar issue, in my case the error message is

Failed to parse mtexasciidoctor: WARNING: could not embed image: /path/to/stem-xxxxxx.png; image file is an unrecognised format; install prawn-gmagick gem to add support
asciidoctor: WARNING: could not embed image: /path/to/stem-xxxxxx.png; image file is an unrecognised format; install prawn-gmagick gem to add support

I've got prawn-gmagick already installed but the issue persist. Indeed the stem-xxxxxx.png file generated is not a valid .png file cause I cannot open it with a picture viewer like eog. So I guess something must be generating bad this particular stem-xxxxxx.png file.

I would like to know at least how to debug which particular stem:[] macro is responsible for this bad png file. But I don't know how to do that.

from asciidoctor-mathematical.

Mauville avatar Mauville commented on August 15, 2024

I've also experienced this issue. As an addition to the cases above, I found yet more that do not output correct PNGs or SVGs.

:stem: latexmath

. Calculate \(\nabla f   \) with \( \nabla f =<fx,fy>\)
:stem: latexmath

stem:[
\int_{\theta_1}^{\theta_2} \int_{r_1}^{r_2} (\operatorname{pol}\left(f\left(x\right)\right)-\operatorname{pol}\left(g\left(x\right)\right)) \cdot r \cdot dr dt
 ]

Finally, although this one is pushing it a bit since it's not surrounded by anything, the following syntax works perfectly with MathJax but does not even get recognized by mathematical.

:stem: latexmath

\begin{aligned}
&x=x_{0}+f_{x}\left(x_{0}, y_{0}\right)t\\
&y=y_{0}+f_{y}\left(x_{0}, y_{0}\right)t\\
&z=z_0-t
\end{aligned}

from asciidoctor-mathematical.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.