summaryrefslogtreecommitdiff
path: root/lisp/ox-odt.el
diff options
context:
space:
mode:
authorSébastien Delafond <sdelafond@gmail.com>2014-07-13 13:35:34 +0200
committerSébastien Delafond <sdelafond@gmail.com>2014-07-13 13:35:34 +0200
commit77ddd382df838e38504b822e729250b2a6dd9b63 (patch)
tree797a630f5c1131dcbe01d3105f75b38fb03f92a2 /lisp/ox-odt.el
parentefc77ab6f5e8883fc38d8c6f75b6db54a0965c15 (diff)
Imported Upstream version 8.2.6
Diffstat (limited to 'lisp/ox-odt.el')
-rw-r--r--lisp/ox-odt.el18
1 files changed, 8 insertions, 10 deletions
diff --git a/lisp/ox-odt.el b/lisp/ox-odt.el
index 1e966fe..772017c 100644
--- a/lisp/ox-odt.el
+++ b/lisp/ox-odt.el
@@ -1502,7 +1502,7 @@ original parsed data. INFO is a plist holding export options."
(email (and (plist-get info :with-email) email)))
(concat
;; Title.
- (when title
+ (when (org-string-nw-p title)
(concat
(format "\n<text:p text:style-name=\"%s\">%s</text:p>"
"OrgTitle" (format "\n<text:title>%s</text:title>" title))
@@ -2713,10 +2713,8 @@ INFO is a plist holding contextual information. See
(path (cond
((member type '("http" "https" "ftp" "mailto"))
(concat type ":" raw-path))
- ((string= type "file")
- (if (file-name-absolute-p raw-path)
- (concat "file://" (expand-file-name raw-path))
- (concat "file://" raw-path)))
+ ((and (string= type "file") (file-name-absolute-p raw-path))
+ (concat "file:" raw-path))
(t raw-path)))
;; Convert & to &amp; for correct XML representation
(path (replace-regexp-in-string "&" "&amp;" path))
@@ -2735,11 +2733,11 @@ INFO is a plist holding contextual information. See
((string= type "radio")
(let ((destination (org-export-resolve-radio-link link info)))
(when destination
- (let ((desc (org-export-data (org-element-contents destination) info))
- (href (org-export-solidify-link-text path)))
- (format
- "<text:bookmark-ref text:reference-format=\"text\" text:ref-name=\"OrgXref.%s\">%s</text:bookmark-ref>"
- href desc)))))
+ (format
+ "<text:bookmark-ref text:reference-format=\"text\" text:ref-name=\"OrgXref.%s\">%s</text:bookmark-ref>"
+ (org-export-solidify-link-text
+ (org-element-property :value destination))
+ desc))))
;; Links pointing to a headline: Find destination and build
;; appropriate referencing command.
((member type '("custom-id" "fuzzy" "id"))