Giter VIP home page Giter VIP logo

Comments (4)

alhassy avatar alhassy commented on May 28, 2024 1

but i was just curious if there was any particular reason for this.

@Nidish96 This is because Org needs to see some top-level math before loading MathJax ---see Issue #17 for a MWE Org file that mentions this issue and demonstrates it.

from org-special-block-extras.

Nidish96 avatar Nidish96 commented on May 28, 2024

Update: delimiting the $s and /s I could get the above to work with latex but not with html:

SDOF equations are \$m\\ddot{x}=f(t)\$ yields what is expected on latex.

from org-special-block-extras.

alhassy avatar alhassy commented on May 28, 2024

I'm glad you like the package ❤️

The way that the special blocks work is that their main argument is actually a string literal; it is not generally interpreted as Org markup. As such, if we treat it as a string then we just need to escape the relevant parts:

#+begin_details "SDOF equations are \\(m\\ddot{x}=f(t)\\)"
The above is a differential equation with $\ddot{x}$.
#+end_details

This works and produces, in HTML:
Screen Shot 2021-08-04 at 11 21 44 PM

It seems that the above string fact should be better documented. Sorry about that 😅

from org-special-block-extras.

Nidish96 avatar Nidish96 commented on May 28, 2024

Thanks for the response (apologies for my delay).

I can confirm that your solution works.
But I found it interesting that the following works,

#+begin_details "SDOF equations are \\(m\\ddot{x}=f(t)\\)"
The above is a differential equation with $\ddot{x}$.
#+end_details

but this does not:

#+begin_details "SDOF equations are \$m\\ddot{x}=f(t)\$"
The above is a differential equation with $\ddot{x}$.
#+end_details

Output of the second version is:
image

This might just be a minor point, since latex supports both $ eqn $ as well as \( eqn \) for inline math, but i was just curious if there was any particular reason for this.

from org-special-block-extras.

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.