Browse Source

Merge branch 'master' of orgmode.org:org-mode

Bastien Guerry 12 năm trước cách đây
mục cha
commit
3f95d811c2
4 tập tin đã thay đổi với 20 bổ sung23 xóa
  1. 5 8
      lisp/org.el
  2. 0 10
      lisp/ox-html.el
  3. 2 2
      lisp/ox-publish.el
  4. 13 3
      lisp/ox.el

+ 5 - 8
lisp/org.el

@@ -4713,16 +4713,15 @@ but the stars and the body are.")
     (org-set-local 'org-file-properties nil)
     (org-set-local 'org-file-tags nil)
     (let ((re (org-make-options-regexp
-	       '("CATEGORY" "TODO" "COLUMNS"
-		 "STARTUP" "ARCHIVE" "FILETAGS" "TAGS" "LINK" "PRIORITIES"
-		 "CONSTANTS" "PROPERTY" "DRAWERS" "SETUPFILE" "LATEX_CLASS"
-		 "OPTIONS")
+	       '("CATEGORY" "TODO" "COLUMNS" "STARTUP" "ARCHIVE" "FILETAGS"
+		 "TAGS" "LINK" "PRIORITIES" "CONSTANTS" "PROPERTY" "DRAWERS"
+		 "SETUPFILE" "OPTIONS")
 	       "\\(?:[a-zA-Z][0-9a-zA-Z_]*_TODO\\)"))
 	  (splitre "[ \t]+")
 	  (scripts org-use-sub-superscripts)
 	  kwds kws0 kwsa key log value cat arch tags const links hw dws
-	  tail sep kws1 prio props ftags drawers beamer-p
-	  ext-setup-or-nil setup-contents (start 0))
+	  tail sep kws1 prio props ftags drawers ext-setup-or-nil setup-contents
+	  (start 0))
       (save-excursion
 	(save-restriction
 	  (widen)
@@ -4791,8 +4790,6 @@ but the stars and the body are.")
 	      (setq arch value)
 	      (remove-text-properties 0 (length arch)
 				      '(face t fontified t) arch))
-	     ((equal key "LATEX_CLASS")
-	      (setq beamer-p (equal value "beamer")))
 	     ((equal key "OPTIONS")
 	      (if (string-match "\\([ \t]\\|\\`\\)\\^:\\(t\\|nil\\|{}\\)" value)
 		  (setq scripts (read (match-string 2 value)))))

+ 0 - 10
lisp/ox-html.el

@@ -1986,7 +1986,6 @@ CONTENTS is nil.  INFO is a plist holding contextual information."
 	(value (org-element-property :value keyword)))
     (cond
      ((string= key "HTML") value)
-     ((string= key "INDEX") (format "\\index{%s}" value))
      ;; Invisible targets.
      ((string= key "TARGET") nil)
      ((string= key "TOC")
@@ -2908,15 +2907,6 @@ Return output file name."
 ;;;; org-html-with-timestamp
 ;;;; org-html-html-helper-timestamp
 
-;;;; org-export-as-html-and-open
-;;;; org-export-as-html-batch
-;;;; org-export-as-html-to-buffer
-;;;; org-replace-region-by-html
-;;;; org-export-region-as-html
-;;;; org-export-as-html
-
-;;;; (org-export-directory :html opt-plist)
-;;;; (plist-get opt-plist :html-extension)
 ;;;; org-html-toplevel-hlevel
 ;;;; org-html-special-string-regexps
 ;;;; org-html-inline-images

+ 2 - 2
lisp/ox-publish.el

@@ -569,8 +569,8 @@ Return output file name."
 		;; we want to keep it up-to-date in cache anyway.
 		(org-combine-plists
 		 plist `(:filter-parse-tree
-			 (org-publish-collect-index
-			  ,@(plist-get plist :filter-parse-tree)))))))
+			 ,(cons 'org-publish-collect-index
+				(plist-get plist :filter-parse-tree)))))))
       ;; Remove opened buffer in the process.
       (unless visitingp (kill-buffer work-buffer)))))
 

+ 13 - 3
lisp/ox.el

@@ -2622,13 +2622,23 @@ specified filters, if any, are called first."
 INFO is a plist containing the current communication channel.
 Return the updated communication channel."
   (let (plist)
-    ;; Install user defined filters with `org-export-filters-alist'.
+    ;; Install user-defined filters with `org-export-filters-alist'
+    ;; and filters already in INFO (through ext-plist mechanism).
     (mapc (lambda (p)
-	    (setq plist (plist-put plist (car p) (eval (cdr p)))))
+	    (let* ((prop (car p))
+		   (info-value (plist-get info prop))
+		   (default-value (symbol-value (cdr p))))
+	      (setq plist
+		    (plist-put plist prop
+			       ;; Filters in INFO will be called
+			       ;; before those user provided.
+			       (append (if (listp info-value) info-value
+					 (list info-value))
+				       default-value)))))
 	  org-export-filters-alist)
     ;; Prepend back-end specific filters to that list.
     (mapc (lambda (p)
-	    ;; Single values get consed, lists are prepended.
+	    ;; Single values get consed, lists are appended.
 	    (let ((key (car p)) (value (cdr p)))
 	      (when value
 		(setq plist