|
From: | Lennart Borgman (gmail) |
Subject: | Re: A new(?) warning of erase-buffer, which was not seen before. |
Date: | Fri, 23 Mar 2007 18:01:42 +0100 |
User-agent: | Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.10) Gecko/20070221 Thunderbird/1.5.0.10 Mnenhy/0.7.5.666 |
Stefan Monnier wrote:
I've been working on some patches to comint to do this, by selectively disabling undo at various points, but it's not entirely straight-forward because you then have to fix up the undo list to account for the unrecorded buffer changes.FWIW, erc.el does this kind of selective undo.How does it deal with changing buffer locations?Nicely.My attempted solution was to scan through buffer-undo-list, updating those position, every time I inserted some "hidden from undo" text. [This isn't typically a performance problem because _usually_ buffer-undo-list is nil when process output is occuring.]That's exactly what ERC does. See erc-update-undo-list.I.e. we should probably add a "insert-without-undo" function which does just that.
Yes, please. And also an delete-without-undo.
[Prev in Thread] | Current Thread | [Next in Thread] |