summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Guerry <bzg@altern.org>2012-10-03 08:30:54 (GMT)
committer Bastien Guerry <bzg@altern.org>2012-10-03 08:30:54 (GMT)
commit1700ea7722b4737a9b6569487f3e57fd36bcca5e (patch)
tree364e3ad733cf58fe199ebe91c46253196dc404e3
parent09d6bcda9872a13149019b4883677bb4b672c76f (diff)
parentfc8ad1347e103b399d0fcdb617d99e5bf06b80b6 (diff)
downloadorg-mode-1700ea7722b4737a9b6569487f3e57fd36bcca5e.zip
org-mode-1700ea7722b4737a9b6569487f3e57fd36bcca5e.tar.gz
Merge branch 'maint'
-rw-r--r--contrib/lisp/org-e-odt.el15
-rw-r--r--lisp/org-odt.el10
2 files changed, 16 insertions, 9 deletions
diff --git a/contrib/lisp/org-e-odt.el b/contrib/lisp/org-e-odt.el
index 715a06b..28799e3 100644
--- a/contrib/lisp/org-e-odt.el
+++ b/contrib/lisp/org-e-odt.el
@@ -126,9 +126,12 @@
(defconst org-e-odt-styles-dir
(let* ((d (expand-file-name (org-find-library-dir "org-e-odt.el")))
(styles-dir-list (list
- (concat d "../../etc/styles/") ;; Git
- (concat d "../../etc/org/") ;; system
- (concat d "../etc/org/"))) ;; ELPA org-plus
+ (concat d "etc/styles/") ;; ELPA and Git
+ (concat d "etc/org/") ;; Org from Emacs
+ (concat d "../"
+ (number-to-string emacs-major-version) "."
+ (number-to-string emacs-minor-version) "/etc/org/")
+ (concat data-directory "org/"))) ;; Custom install
styles-dir)
(setq styles-dir
(car
@@ -142,8 +145,8 @@
"OrgOdtStyles.xml" sd)))
sd))
styles-dir-list))))
- (or styles-dir
- (error "Cannot find factory styles files for Org ODT, aborting")))
+ (or (expand-file-name styles-dir)
+ (message "Cannot find factory styles files for Org ODT")))
"Directory that holds auxiliary XML files used by the ODT exporter.
This directory contains the following XML files -
@@ -1785,7 +1788,7 @@ CONTENTS is nil. INFO is a plist holding contextual information."
;;;; Latex Environment
-(eval-after-load 'org-e-odt
+(eval-after-load 'org-odt
'(ad-deactivate 'org-format-latex-as-mathml))
;; (defadvice org-format-latex-as-mathml ; FIXME
diff --git a/lisp/org-odt.el b/lisp/org-odt.el
index c417080..117c824 100644
--- a/lisp/org-odt.el
+++ b/lisp/org-odt.el
@@ -150,7 +150,11 @@ Also add it to `rng-schema-locating-files'."
(let* ((d (expand-file-name "../" (org-find-library-dir "org-odt.el")))
(styles-dir-list (list
(concat d "etc/styles/") ;; ELPA and Git
- (concat d "etc/org/")))
+ (concat d "etc/org/") ;; Org from Emacs
+ (concat d "../"
+ (number-to-string emacs-major-version) "."
+ (number-to-string emacs-minor-version) "/etc/org/")
+ (concat data-directory "org/"))) ;; Custom install
styles-dir)
(setq styles-dir
(car
@@ -164,8 +168,8 @@ Also add it to `rng-schema-locating-files'."
"OrgOdtStyles.xml" sd)))
sd))
styles-dir-list))))
- (or styles-dir
- (error "Cannot find factory styles files for Org ODT, aborting")))
+ (or (expand-file-name styles-dir)
+ (message "Cannot find factory styles files for Org ODT, aborting")))
"Directory that holds auxiliary XML files used by the ODT exporter.
This directory contains the following XML files -