🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.emacs.help
Article #2144

suggestion for new emacs feature: spatial undo

#2144
From: Richard Stallman
Date: Tue, 12 Jan 1993 12:51
23 lines
1545 bytes
People are talking about having non-chronological undo in Emacs.
I once implemented an undo facility that could undo out of order.  
It requires two things:

* Implementing restoration of old values of buffer pointers.  When you
delete, markers formerly unequal can become equal.  Undoing the delete
has to make these markers unequal again.

* Using markers in the undo records.  

Then, if you undo out of order, it automatically updates the markers
in the undo records for more recent operations, so they are undone
correctly.

The hard part is making it efficient to have very large numbers of
markers in one buffer.  With the current data structure, updating them
for a deletion or gap motion might be painfully slow.  Or maybe it
would be acceptable--I'm not sure.

I don't have time to work on this, but it would be a good thing for
someone else to work on.  If you can understand the relevant parts of
Emacs without a lot of questions, and you have a fair amount of time
to spend on this, let me know if you're interested.
Technical Details
Message-ID: <9301122251.AA28106@mole.gnu.ai.mit.edu>
Path: arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!gnu.ai.mit.edu!rms
References: <JXL.93Jan11164152@ontario.opl.com>

Show Full Headers
Complete Article Headers
Newsgroups: gnu.emacs.help
Path: arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!gnu.ai.mit.edu!rms
From: rms@gnu.ai.mit.edu (Richard Stallman)
Subject: suggestion for new emacs feature: spatial undo
Message-ID: <9301122251.AA28106@mole.gnu.ai.mit.edu>
Sender: daemon@cis.ohio-state.edu
Organization: Gatewayed from the GNU Project mailing list help-gnu-emacs@prep.ai.mit.edu
References: <JXL.93Jan11164152@ontario.opl.com>
Date: Tue, 12 Jan 1993 12:51:07 GMT
Lines: 23