Subject: Re: bug#11774: bug#11774: bug#11774: org-mode causes undo boundaries to be lost

From: Bastien <[email-masked]>
Date: Wed, 01 Aug 2012 16:26:23 +0200

Stefan Monnier <[email-masked]> writes:

>>>> self-insert-command.  Even just turning that magic 20 number into a
>>>> variable would help.
>>> Providing it as a variable would be very easy, indeed.
>> Maybe the user should be able to set undo boundaries and
>> have them work after self-insert-command?   Dunno, I'm
>> not familiar with internals enough to opine.
>
> I installed the patch below which makes self-insert-command more careful
> to only remove undo boundaries that were auto-added.
> So (add-hook 'post-self-insert-hook #'undo-boundary 'append) should give you
> pretty much the behavior you were looking for.

On Org's side, `org-self-insert-cluster-for-undo' now defaults to nil
for Emacs >=24.1, t otherwise.

Thanks,

-- 
 Bastien