all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [BUG] 'outline-change-heading' in outline-magic.el adds extra spaces
@ 2013-02-18 13:32 Thorsten Jolitz
  2013-02-18 14:34 ` Thorsten Jolitz
  2013-02-18 18:22 ` Stefan Monnier
  0 siblings, 2 replies; 3+ messages in thread
From: Thorsten Jolitz @ 2013-02-18 13:32 UTC (permalink / raw)
  To: help-gnu-emacs; +Cc: dominik


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





^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-02-18 18:22 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-18 13:32 [BUG] 'outline-change-heading' in outline-magic.el adds extra spaces Thorsten Jolitz
2013-02-18 14:34 ` Thorsten Jolitz
2013-02-18 18:22 ` Stefan Monnier

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.