Browse Source

Bugfix: Indentation for converted headlines with `C-c -'

Carsten Dominik 16 years ago
parent
commit
d9c47b107f
2 changed files with 6 additions and 1 deletions
  1. 2 0
      lisp/ChangeLog
  2. 4 1
      lisp/org.el

+ 2 - 0
lisp/ChangeLog

@@ -1,5 +1,7 @@
 2008-12-31  Carsten Dominik  <carsten.dominik@gmail.com>
 
+	* org.el (org-ctrl-c-minus): Fix indentation for new items.
+
 	* org-footnote.el: New file.
 
 	* org.el (org-footnote): Require footnote code.

+ 4 - 1
lisp/org.el

@@ -13206,7 +13206,10 @@ Calls `org-table-insert-hline', `org-toggle-region-items', or
     (save-excursion
       (beginning-of-line 1)
       (if (looking-at "\\*+ ")
-	  (replace-match (concat (make-string (- (match-end 0) (point) 1) ?\ ) "- ")))))
+	  (replace-match
+	   (concat (make-string
+		    (- (match-end 0) (point) (if org-odd-levels-only 2 1)) ?\ )
+		   "- ")))))
    ((org-region-active-p)
     ;; Convert all lines in region to list items
     (call-interactively 'org-toggle-region-items))