From 93f4ccbba1785bdd95d4c204223935ee0e615811 Mon Sep 17 00:00:00 2001 From: tj Date: Sat, 13 Apr 2013 16:13:49 +0200 Subject: [PATCH] calculation of outline-level adapted to special case of oldschool elips headings (;;;+). --- outshine.el | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/outshine.el b/outshine.el index 8551c51..dbc3d63 100644 --- a/outshine.el +++ b/outshine.el @@ -506,11 +506,19 @@ Based on `comment-start' and `comment-add'." (and (looking-at (outshine-calc-outline-regexp)) (let ((m-strg (match-string-no-properties 0))) - (setq m-strg - (split-string - m-strg - (format "%s" outshine-normalized-comment-start) - 'OMIT-NULLS)) + (if outshine-enforce-no-comment-padding-p + ;; deal with oldschool elisp headings (;;;+) + (setq m-strg + (split-string + (substring m-strg 2) + nil + 'OMIT-NULLS)) + ;; orgmode style elisp heading (;; *+) + (setq m-strg + (split-string + m-strg + (format "%s" outshine-normalized-comment-start)) + 'OMIT-NULLS)) (length (mapconcat (lambda (str)