summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas Goaziou <n.goaziou@gmail.com>2012-01-09 18:47:22 +0100
committerNicolas Goaziou <n.goaziou@gmail.com>2012-01-09 18:48:07 +0100
commit56c73255c0bdd27ac42af0a02ecea9336c4594d6 (patch)
tree363fb615d7d66e76af7d9cc64794a8f02a138d16
parent128357b6f4b5c519229da9a92f5766e579478183 (diff)
downloadorg-mode-56c73255c0bdd27ac42af0a02ecea9336c4594d6.tar.gz
org-indent: Handle indentation change with headline manual insertion
* lisp/org-indent.el (org-indent-refresh-maybe): Check for new headlines from the beginning of the line to be sure to catch any newly inserted headline there.
-rw-r--r--lisp/org-indent.el1
1 files changed, 1 insertions, 0 deletions
diff --git a/lisp/org-indent.el b/lisp/org-indent.el
index ae0c91e..99a7584 100644
--- a/lisp/org-indent.el
+++ b/lisp/org-indent.el
@@ -412,6 +412,7 @@ This function is meant to be called by `after-change-functions'."
(if (or org-indent-modified-headline-flag
(save-excursion
(goto-char beg)
+ (beginning-of-line)
(re-search-forward org-outline-regexp-bol end t)))
(let ((end (save-excursion
(goto-char end)