emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Lawrence Bottorff <borgauf@gmail.com>
To: Rasmus <rasmus@gmx.us>
Cc: emacs-orgmode Mailinglist <emacs-orgmode@gnu.org>
Subject: Re: MathJax beyond org-html-mathjax-options?
Date: Fri, 3 Nov 2017 13:29:53 -0400	[thread overview]
Message-ID: <CAFAhFSXp2Fx3H9U9a5NKejgBGRSmYgv0vPXChxkuAkpBK+TWPA@mail.gmail.com> (raw)
In-Reply-To: <87fu9w7rk7.fsf@gmx.us>

[-- Attachment #1: Type: text/plain, Size: 1994 bytes --]

Bottom line: we can't expand org-html-mathjax-options to add in MathJax's
cancel.js, etc. Yes, your first "quick-and-dirty" worked just fine. Q: How
did you know how to format #+html: \(\require{cancel}\) ? Also, how does
the org world know that we're talking about loading MathJax's cancel.js? As
you all know I'm not a "developer-class" poster here, so my questions often
look dull-witted. Will try the patch once I learn a bit more diff in Emacs
lore. . . .

On Thu, Nov 2, 2017 at 9:12 AM, Rasmus <rasmus@gmx.us> wrote:

> Lawrence Bottorff <borgauf@gmail.com> writes:
>
> > I'm trying to get a typical Latex strikethrough with MathJax in an HTML
> > export, i.e., \cancel{thing} puts line through "thing". This
> > <http://docs.mathjax.org/en/latest/tex.html#cancel> tells me how. But I
> > don't know how to include this MathJax markup in an org file for HTML
> > export. If I forego MathJax -- i.e., #+OPTIONS: tex:dvipng instead
> > of #+OPTIONS: tex:t -- \cancel works, but I need to use MathJax. It
> doesn't
> > look like orhg-html-mathjax-options is expandable. . . .
>
> For now this works for me:
>
>     #+html: \(\require{cancel}\)
>     \begin{equation}
>     \cancel{x = 1}
>     \end{equation}
>
> Cf. http://docs.mathjax.org/en/latest/tex.html#tex-and-latex-extensions
> You could also autoload the extension, cf. https://github.com/mathjax/
> MathJax/blob/master/test/sample-autoload.html
>
>
> That being said, I don’t think extensions were available at the time
> #+HTML_MATHJAX was introduced.  We could add extension support, but the
> questions would be whether to add them to #+HTML_MATHJAX or make a new
> keyword, e.g.
>
>     #+HTML_MATHJAX_EXTENSIONS: ext1 ext2 ... extN
>
> I guess it would default to the "autoload-all" extension.
>
> One issue is that some of them have configuration options, like "noError".
>
> If you want, you can try the attached patch.
>
> Rasmus
>
> --
> Vote for proprietary math!
>

[-- Attachment #2: Type: text/html, Size: 2974 bytes --]

  reply	other threads:[~2017-11-03 17:30 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-01  1:30 MathJax beyond org-html-mathjax-options? Lawrence Bottorff
2017-11-02 13:12 ` Rasmus
2017-11-03 17:29   ` Lawrence Bottorff [this message]
2017-11-03 17:40     ` Rasmus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAFAhFSXp2Fx3H9U9a5NKejgBGRSmYgv0vPXChxkuAkpBK+TWPA@mail.gmail.com \
    --to=borgauf@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=rasmus@gmx.us \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).