فهرست منبع

org-odt.el: Consider short captions not as org text but as plain text

* lisp/org-lparse.el (org-lparse-insert-org-table): Consider
short caption as plain text and not as org text.
* lisp/org-odt.el (org-export-odt-format-formula)
(org-export-odt-format-image): ditto.

Fixes earlier checkin.  See
http://lists.gnu.org/archive/html/emacs-orgmode/2012-03/msg01212.html

Handling of short captions is only a convenience feature.

From within LibreOffice one can always create an "unprotected"
editable index and later manually delete unwanted index entries (for
example, delete uncaptioned entries which are given automatic names)
or modify existing entries (for example, fix long captions to their
short versions).
Jambunathan K 13 سال پیش
والد
کامیت
8a02f48547
2فایلهای تغییر یافته به همراه5 افزوده شده و 6 حذف شده
  1. 3 4
      lisp/org-lparse.el
  2. 2 2
      lisp/org-odt.el

+ 3 - 4
lisp/org-lparse.el

@@ -1221,12 +1221,11 @@ for formatting.  This is required for the DocBook exporter."
     ;; column and the special lines
     (setq lines (org-table-clean-before-export lines)))
   (let* ((caption (org-find-text-property-in-string 'org-caption (car lines)))
+	 (short-caption (or (org-find-text-property-in-string
+			     'org-caption-shortn (car lines)) caption))
 	 (caption (and caption (org-xml-encode-org-text caption)))
-	 (short-caption (org-find-text-property-in-string
-			 'org-caption-shortn (car lines)))
-	 (short-caption (or short-caption caption))
 	 (short-caption (and short-caption
-			     (org-xml-encode-org-text short-caption)))
+			     (org-xml-encode-plain-text short-caption)))
 	 (label (org-find-text-property-in-string 'org-label (car lines)))
 	 (org-lparse-table-colalign-info (org-lparse-table-get-colalign-info lines))
 	 (attributes (org-find-text-property-in-string 'org-attributes

+ 2 - 2
lisp/org-odt.el

@@ -1558,7 +1558,7 @@ See `org-odt-add-label-definition' and
 		caption))
 	   (caption (and caption (org-xml-format-desc caption)))
 	   (short-caption (and short-caption
-			       (org-xml-format-desc short-caption)))
+			       (org-xml-encode-plain-text short-caption)))
 	   (label (org-find-text-property-in-string 'org-label src))
 	   (latex-frag (org-find-text-property-in-string 'org-latex-src src))
 	   (embed-as (or (and latex-frag
@@ -1812,7 +1812,7 @@ ATTR is a string of other attributes of the a element."
 		caption))
 	   (caption (and caption (org-xml-format-desc caption)))
 	   (short-caption (and short-caption
-			       (org-xml-format-desc short-caption)))
+			       (org-xml-encode-plain-text short-caption)))
 	   (attr (org-find-text-property-in-string 'org-attributes src))
 	   (label (org-find-text-property-in-string 'org-label src))
 	   (latex-frag (org-find-text-property-in-string