소스 검색

org-odt.el: Don't corrupt styles.xml while applying outline numbering

* contrib/lisp/org-odt.el
(org-odt-configure-outline-numbering): Tighten the regular
expression that matches "<text:outline-level-style ...>"
element.

Fixes bug reported here
http://lists.gnu.org/archive/html/emacs-orgmode/2011-10/msg00594.html
Jambunathan K 14 년 전
부모
커밋
9e90239a70
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      contrib/lisp/org-odt.el

+ 1 - 1
contrib/lisp/org-odt.el

@@ -2099,7 +2099,7 @@ visually."
 To disable outline numbering pass a LEVEL of 0."
   (goto-char (point-min))
   (let ((regex
-	 "<text:outline-level-style\\(.*\\)text:level=\"\\([^\"]*\\)\"\\(.*\\)>")
+	 "<text:outline-level-style\\([^>]*\\)text:level=\"\\([^\"]*\\)\"\\([^>]*\\)>")
 	(replacement
 	 "<text:outline-level-style\\1text:level=\"\\2\" style:num-format=\"\">"))
     (while (re-search-forward regex nil t)