HTML Export: Fix link creation for hashed LaTeX snippet images

Patch by Eric Schulte, bug reported by Hsiu-Khuern
This commit is contained in:
Carsten Dominik 2009-11-30 15:29:07 +01:00
parent 63fe365b2c
commit 42a2f2299c
2 changed files with 7 additions and 2 deletions

View file

@ -1,3 +1,8 @@
2009-11-30 Carsten Dominik <carsten.dominik@gmail.com>
* org.el (org-format-latex): Fix link creation for processed latex
snippets.
2009-11-29 Carsten Dominik <carsten.dominik@gmail.com>
* org-footnote.el (org-footnote-normalize): Protect replacement

View file

@ -14616,8 +14616,7 @@ Some of the options can be changed using the variable
'org-latex-overlay))))
(setq txt (match-string n)
beg (match-beginning n) end (match-end n)
cnt (1+ cnt)
link (concat block "[[file:" linkfile "]]" block))
cnt (1+ cnt))
(let (print-length print-level) ; make sure full list is printed
(setq hash (sha1 (prin1-to-string
(list org-format-latex-header
@ -14626,6 +14625,7 @@ Some of the options can be changed using the variable
forbuffer txt)))
linkfile (format "%s_%s.png" prefix hash)
movefile (format "%s_%s.png" absprefix hash)))
(setq link (concat block "[[file:" linkfile "]]" block))
(if msg (message msg cnt))
(goto-char beg)
(unless checkdir ; make sure the directory exists