summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Guerry <bzg@altern.org>2013-03-01 18:57:55 +0100
committerBastien Guerry <bzg@altern.org>2013-03-01 18:57:55 +0100
commit7afbf870f2644b79a10cc99a2851953f79c9fedb (patch)
treebd95e3f8fdf471269f5c74eda63b8daecb9b2754
parent7524ef25ff0db230c39ec31b37dd2b4d3d53eaf6 (diff)
downloadorg-mode-7afbf870f2644b79a10cc99a2851953f79c9fedb.tar.gz
org.el (org-mode): Set `paragraph-start'
* org.el (org-mode): Set `paragraph-start'. The value inherited from outline-mode is wrong because outline mode does not enforce the space after the star while Org-mode does. outline-mode value for `paragraph-start' prevents filling paragraphs containing a string like " -- *bold*": in this case, fill-paragraph might think that the "*b" part of the string starts a paragraph while it does not. Thanks to Samuel Wales for reporting this.
-rw-r--r--lisp/org.el2
1 files changed, 2 insertions, 0 deletions
diff --git a/lisp/org.el b/lisp/org.el
index cc4c93f..13fb44d 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -4898,6 +4898,8 @@ The following commands are available:
(org-set-local 'outline-regexp org-outline-regexp)
(org-set-local 'outline-level 'org-outline-level)
(setq bidi-paragraph-direction 'left-to-right)
+ ;; FIXME Circumvent a bug in outline.el (Emacs <24.4)
+ (set (make-local-variable 'paragraph-start) " \\|[ \t]*$\\|\\*+ ")
(when (and org-ellipsis
(fboundp 'set-display-table-slot) (boundp 'buffer-display-table)
(fboundp 'make-glyph-code))