From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rasmus Subject: Re: What happens to org-export-with-LaTeX-fragments Date: Tue, 14 May 2013 15:02:53 +0200 Message-ID: <87li7hogsi.fsf@pank.eu> References: Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([208.118.235.92]:54413) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UcExz-0006bd-RK for emacs-orgmode@gnu.org; Tue, 14 May 2013 09:08:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UcEsj-0001Iq-LW for emacs-orgmode@gnu.org; Tue, 14 May 2013 09:03:12 -0400 Received: from plane.gmane.org ([80.91.229.3]:59721) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UcEsj-0001IF-Dm for emacs-orgmode@gnu.org; Tue, 14 May 2013 09:03:05 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1UcEsi-0006Hw-Ii for emacs-orgmode@gnu.org; Tue, 14 May 2013 15:03:04 +0200 Received: from ip-pool-142.iue.it ([192.167.90.142]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 14 May 2013 15:03:04 +0200 Received: from rasmus by ip-pool-142.iue.it with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 14 May 2013 15:03:04 +0200 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Hi Leo, > I am upgrading to org 8 and cleaning up my init. There are two variables > that aren't defined any more: org-export-with-LaTeX-fragments and I'm looking at an "old" exporter and assume that you are interested in MathJax and HTML. . .? In any case, the source suggests that org-element only checks :with-latex, which can be set 'globally' with org-export-with-latex (I think). Also, it seems there might be a bug in the docstring as the function below suggests it also support value dvipng and mathjax. But I could be wrong. Anyway, check out this function: #+BEGIN_SRC emacs-lisp ;;;; Latex Fragment [snip from ox-html.el] (defun org-html-latex-fragment (latex-fragment contents info) "Transcode a LATEX-FRAGMENT object from Org to HTML. CONTENTS is nil. INFO is a plist holding contextual information." (let ((latex-frag (org-element-property :value latex-fragment)) (processing-type (plist-get info :with-latex))) (case processing-type ((t mathjax) (org-html-format-latex latex-frag 'mathjax)) (dvipng (let* ((formula-link (org-html-format-latex latex-frag processing-type))) (when (and formula-link (string-match "file:\\([^]]*\\)" formula-link)) (org-html-format-inline-image (match-string 1 formula-link) info)))) (t latex-frag)))) #+END_SRC > org-highlight-latex-fragments-and-specials. This is improved through org-highlight-latex-and-related. Check it out. Hope it helps, Rasmus -- . . . Stallman was indeed the tallest possible mountain and by standing on his shoulders you could see forever. . .