* Blank equation when exported to HTML using dvipng @ 2012-05-28 5:43 Richard Stanton [not found] ` <CALnw1fQHCHqH5JBdqbTTwvRq9AR8dL2OHPwbpwug1J4iuBW6=A@mail.gmail.com> 0 siblings, 1 reply; 5+ messages in thread From: Richard Stanton @ 2012-05-28 5:43 UTC (permalink / raw To: emacs-orgmode@gnu.org Here's a very simple ORG file: -------- #+OPTIONS: LaTeX:dvipng * Test file \begin{equation} x=\sqrt{b} \end{equation} ---------- When I export this to HTML (Org-mode version 7.8.11 (release_7.8.11-12-gc55405 @ c:/emacs/site-lisp/org-mode/lisp/)), the equation comes out blank. The HTML file contains the following code: <img src="ltxpng/test_660c6efb146974e9d77e2de45f258385867ef389.png" alt="\begin{equation} x=\sqrt{b} \end{equation}"/> However, directory ltxpng is empty. I'm running Emacs 24.0.97 under Windows Vista with MikTeX 2.09 installed and PATH set so that I can call pdflatex, dvipng, etc. from the command line just fine. Any thoughts about what might be going wrong? ^ permalink raw reply [flat|nested] 5+ messages in thread
[parent not found: <CALnw1fQHCHqH5JBdqbTTwvRq9AR8dL2OHPwbpwug1J4iuBW6=A@mail.gmail.com>]
* Re: Blank equation when exported to HTML using dvipng [not found] ` <CALnw1fQHCHqH5JBdqbTTwvRq9AR8dL2OHPwbpwug1J4iuBW6=A@mail.gmail.com> @ 2012-05-28 6:00 ` Richard Stanton 2012-05-28 14:08 ` Nick Dokos 0 siblings, 1 reply; 5+ messages in thread From: Richard Stanton @ 2012-05-28 6:00 UTC (permalink / raw To: Puneeth Chaganti; +Cc: emacs-orgmode@gnu.org > From: Puneeth Chaganti [mailto:punchagan@gmail.com] > Sent: Sunday, May 27, 2012 10:48 PM > To: Richard Stanton > Subject: Re: [O] Blank equation when exported to HTML using dvipng > > On Mon, May 28, 2012 at 11:13 AM, Richard Stanton > <stanton@haas.berkeley.edu> wrote: > > Here's a very simple ORG file: > > > > -------- > > > > #+OPTIONS: LaTeX:dvipng > > > > * Test file > > \begin{equation} > > x=\sqrt{b} > > \end{equation} > > > > ---------- > > > > When I export this to HTML (Org-mode version 7.8.11 (release_7.8.11-12- > gc55405 @ c:/emacs/site-lisp/org-mode/lisp/)), the equation comes out > blank. > > > > The HTML file contains the following code: > > > > <img src="ltxpng/test_660c6efb146974e9d77e2de45f258385867ef389.png" > > alt="\begin{equation} x=\sqrt{b} \end{equation}"/> > > > > However, directory ltxpng is empty. > > > > I'm running Emacs 24.0.97 under Windows Vista with MikTeX 2.09 installed > and PATH set so that I can call pdflatex, dvipng, etc. from the command line > just fine. > > > > Any thoughts about what might be going wrong? > > Do you get any error messages? Do you have dvipng installed? > > -- > Puneeth The *Messages* buffer shows the following: Exporting... Loading reftex...done Creating LaTeX image 1 Failed to create dvi file from c:/Users/stanton/AppData/Local/Temp/orgtex5660EuC.tex Exporting... image ltxpng/test_660c6efb146974e9d77e2de45f258385867ef389.png t Saving file c:/projects/texintro/web/test.html... Wrote c:/projects/texintro/web/test.html HTML export done, pushed to kill ring and clipboard Investigating further, the log file associated with the tex file listed above shows the following: Package ifplatform Warning: shell escape is disabled, so I can only detect \ifwindows. ) \minted@bgbox=\box31 \minted@code=\write4 \@float@every@listing=\toks22 \c@listing=\count106 ) ! Package minted Error: You must invoke LaTeX with the -shell-escape flag. See the minted package documentation for explanation. Type H <return> for immediate help. ... l.7 \usepackage [latin1]{inputenc} ? ! Emergency stop. ... l.7 \usepackage [latin1]{inputenc} Pass the -shell-escape flag to LaTeX. Refer to the minted.sty documentation for more information. So now I can see what the problem is, but how do I tell org-mode to call latex with the -shell-escape flag? ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Blank equation when exported to HTML using dvipng 2012-05-28 6:00 ` Richard Stanton @ 2012-05-28 14:08 ` Nick Dokos 2012-05-28 20:52 ` Richard Stanton 0 siblings, 1 reply; 5+ messages in thread From: Nick Dokos @ 2012-05-28 14:08 UTC (permalink / raw To: Richard Stanton; +Cc: emacs-orgmode@gnu.org Richard Stanton <stanton@haas.berkeley.edu> wrote: > ... > > So now I can see what the problem is, but how do I tell org-mode to > call latex with the -shell-escape flag? > You can customize org-latex-to-pdf-process (or org-e-latex-pdf-process[fn:1] if you are using the new exporter). In my case, I have ,---- | org-latex-to-pdf-process is a variable defined in `org-latex.el'. | Its value is ("texi2dvi --pdf %f") | Original value was | ("pdflatex -interaction nonstopmode -output-directory %o %f" "pdflatex -interaction nonstopmode -output-directory %o %f" "pdflatex -interaction nonstopmode -output-directory %o %f") `---- but texi2dvi probably does not exist on windows (and you still have to patch it even on linux). Just add --shell-escape after every pdflatex (or whatever command is invoked on windows). Nick Footnotes: [fn:1] NB: different spelling in the two cases - not only the added "e-" but also the missing "-to". ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Blank equation when exported to HTML using dvipng 2012-05-28 14:08 ` Nick Dokos @ 2012-05-28 20:52 ` Richard Stanton 2012-05-28 23:12 ` Nick Dokos 0 siblings, 1 reply; 5+ messages in thread From: Richard Stanton @ 2012-05-28 20:52 UTC (permalink / raw To: nicholas.dokos@hp.com; +Cc: emacs-orgmode@gnu.org In my init.el, I have (setq org-latex-to-pdf-process '("pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f" "pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f" "pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f" "pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f")) The problem is that when I export to HTML with the dvipng option, it's calling latex, not pdflatex, so I don't think this option has an effect. > -----Original Message----- > From: nicholas.dokos@hp.com [mailto:nicholas.dokos@hp.com] > Sent: Monday, May 28, 2012 7:08 AM > To: Richard Stanton > Cc: Puneeth Chaganti; emacs-orgmode@gnu.org > Subject: Re: [O] Blank equation when exported to HTML using dvipng > > Richard Stanton <stanton@haas.berkeley.edu> wrote: > > > ... > > > > So now I can see what the problem is, but how do I tell org-mode to > > call latex with the -shell-escape flag? > > > > You can customize org-latex-to-pdf-process (or org-e-latex-pdf- > process[fn:1] if you are using the new exporter). In my case, I have > > ,---- > | org-latex-to-pdf-process is a variable defined in `org-latex.el'. > | Its value is ("texi2dvi --pdf %f") > | Original value was > | ("pdflatex -interaction nonstopmode -output-directory %o %f" "pdflatex > | -interaction nonstopmode -output-directory %o %f" "pdflatex > | -interaction nonstopmode -output-directory %o %f") > `---- > > but texi2dvi probably does not exist on windows (and you still have to patch > it even on linux). Just add --shell-escape after every pdflatex (or whatever > command is invoked on windows). > > Nick > > Footnotes: > > [fn:1] NB: different spelling in the two cases - not only the added "e-" but > also the missing "-to". ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Blank equation when exported to HTML using dvipng 2012-05-28 20:52 ` Richard Stanton @ 2012-05-28 23:12 ` Nick Dokos 0 siblings, 0 replies; 5+ messages in thread From: Nick Dokos @ 2012-05-28 23:12 UTC (permalink / raw To: Richard Stanton; +Cc: emacs-orgmode@gnu.org Richard Stanton <stanton@haas.berkeley.edu> wrote: > In my init.el, I have > > (setq org-latex-to-pdf-process > '("pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f" > "pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f" > "pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f" > "pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f")) > > The problem is that when I export to HTML with the dvipng option, it's calling latex, not pdflatex, so I don't think this option has an effect. > Ah, right: that's hardwired and needs source code changes. The call is in org.el:org-create-formula-image-with-dvipng. This was reported by Ista Zahn (see http://thread.gmane.org/gmane.emacs.orgmode/50533). I would encourage you to submit a patch for this[fn:1] - maybe make it conditional on the value of org-export-latex-listings. Nick Footnotes: [fn:1] Unfortunately I cannot. ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2012-05-28 23:12 UTC | newest] Thread overview: 5+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2012-05-28 5:43 Blank equation when exported to HTML using dvipng Richard Stanton [not found] ` <CALnw1fQHCHqH5JBdqbTTwvRq9AR8dL2OHPwbpwug1J4iuBW6=A@mail.gmail.com> 2012-05-28 6:00 ` Richard Stanton 2012-05-28 14:08 ` Nick Dokos 2012-05-28 20:52 ` Richard Stanton 2012-05-28 23:12 ` Nick Dokos
Code repositories for project(s) associated with this external index https://git.savannah.gnu.org/cgit/emacs.git https://git.savannah.gnu.org/cgit/emacs/org-mode.git This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.