help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[BUG] 'outline-change-heading' in outline-magic.el adds extra spaces


From: Thorsten Jolitz
Subject: [BUG] 'outline-change-heading' in outline-magic.el adds extra spaces
Date: Mon, 18 Feb 2013 14:32:56 +0100
User-agent: Gnus/5.130002 (Ma Gnus v0.2) Emacs/24.2 (gnu/linux)

Hi List, 

when using 

,--------------------
| M-x outline-demote
| M-x outline-promote
`--------------------

with an outline-regexp that contains (trailing) spaces, like e.g. 

,-----------
| ";; [*]+ "
`-----------

a new space is added between the outline-regexp and the headline each
time 'outline-demote' is used, and not removed afterwards when
'outline-promote' is used. 

E.g. 

;; ** headline

becomes

;; ****   headline

after demoting 2 times, and then becomes

;; **   headline

after promoting again 2 times. 

Proposed FIX:
replace the last line of 'outline-change-heading' in outline-magic.el

,--------------------------------------
| (replace-match newhead t t nil 1)))))
`--------------------------------------

with

,--------------------------------------------------------------
| (replace-match (outline-cleanup-match newhead) t t nil 1)))))
`--------------------------------------------------------------

-- 
cheers,
Thorsten





reply via email to

[Prev in Thread] Current Thread [Next in Thread]