summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas Goaziou <n.goaziou@gmail.com>2012-01-23 19:14:59 +0100
committerNicolas Goaziou <n.goaziou@gmail.com>2012-01-23 19:16:30 +0100
commitcb8847f6fe6f69bd85cd6531e144cad900f526b4 (patch)
treebbf7e2e113e8b02ab66e668bc49a6521a44087de
parenta9510349ea778b42de42e30662d987227f3fed0e (diff)
downloadorg-mode-cb8847f6fe6f69bd85cd6531e144cad900f526b4.tar.gz
org-e-latex: Expand path when file name is absolute in an inline image
* EXPERIMENTAL/org-e-latex.el (org-e-latex-link): In links, expand path when file name is absolute.
-rw-r--r--EXPERIMENTAL/org-e-latex.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/EXPERIMENTAL/org-e-latex.el b/EXPERIMENTAL/org-e-latex.el
index e6266d1..5de0595 100644
--- a/EXPERIMENTAL/org-e-latex.el
+++ b/EXPERIMENTAL/org-e-latex.el
@@ -1360,7 +1360,9 @@ INFO is a plist holding contextual information. See
(path (cond
((member type '("http" "https" "ftp" "mailto"))
(concat type ":" raw-path))
- ((and (not imagep) (string= type "file"))
+ (imagep (if (not (file-name-absolute-p raw-path)) raw-path
+ (expand-file-name raw-path)))
+ ((string= type "file")
(when (string-match "\\(.+\\)::.+" raw-path)
(setq raw-path (match-string 1 raw-path)))
(if (file-name-absolute-p raw-path)