Browse Source

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

Bastien Guerry 12 years ago
parent
commit
988240d5fd
2 changed files with 5 additions and 2 deletions
  1. 4 1
      lisp/org.el
  2. 1 1
      lisp/ox-latex.el

+ 4 - 1
lisp/org.el

@@ -20738,7 +20738,10 @@ With prefix arg UNCOMPILED, load the uncompiled versions."
 
 
 (defun org-in-verbatim-emphasis ()
 (defun org-in-verbatim-emphasis ()
   (save-match-data
   (save-match-data
-    (and (org-in-regexp org-emph-re 2) (member (match-string 3) '("=" "~")))))
+    (and (org-in-regexp org-emph-re 2)
+	 (>= (point) (match-beginning 3))
+	 (<= (point) (match-end 4))
+	 (member (match-string 3) '("=" "~")))))
 
 
 (defun org-goto-marker-or-bmk (marker &optional bookmark)
 (defun org-goto-marker-or-bmk (marker &optional bookmark)
   "Go to MARKER, widen if necessary.  When marker is not live, try BOOKMARK."
   "Go to MARKER, widen if necessary.  When marker is not live, try BOOKMARK."

+ 1 - 1
lisp/ox-latex.el

@@ -1482,7 +1482,7 @@ holding contextual information."
 			(org-export-data
 			(org-export-data
 			 (org-export-get-optional-title headline info) info)
 			 (org-export-get-optional-title headline info) info)
 			(and (eq (plist-get info :with-tags) t) tags))))
 			(and (eq (plist-get info :with-tags) t) tags))))
-	  (if (and opt-title (string-match "\\`\\\\\\(.*?\\){" section-fmt))
+	  (if (and opt-title (string-match "\\`\\\\\\(.*?[^*]\\){" section-fmt))
 	      (format (replace-match "\\1[%s]" nil nil section-fmt 1)
 	      (format (replace-match "\\1[%s]" nil nil section-fmt 1)
 		      ;; Replace square brackets with parenthesis
 		      ;; Replace square brackets with parenthesis
 		      ;; since square brackets are not supported in
 		      ;; since square brackets are not supported in