diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 0d3579109..f2ce31b2f 100755 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -2,6 +2,8 @@ * org-exp.el (org-export-html-format-image): Add the / to the end of the tag. + (org-export-format-source-code): Surround example by empty lines, + to make sure it will not be inside a paragraph. * org.el (org-ido-switchb): New function. diff --git a/lisp/org-exp.el b/lisp/org-exp.el index 9ef05249d..f961ffc4e 100644 --- a/lisp/org-exp.el +++ b/lisp/org-exp.el @@ -2260,9 +2260,9 @@ backends, it converts the segment into an EXAMPLE segment." (point-min) (point-max))))) (if (string-match "]*\\)>\n?" htmltext) (setq htmltext (replace-match - (format "
" lang)
+			      (format "
\n" lang)
 			      t t htmltext)))
-	  (concat "#+BEGIN_HTML\n" htmltext "\n#+END_HTML\n"))))
+	  (concat "\n#+BEGIN_HTML\n" htmltext "\n#+END_HTML\n\n"))))
      (t
       ;; This is not HTML, so just make it an example.
       (when (equal lang "org")