[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

46. Redo/Undo System

Emacs' normal undo system allows you to undo an arbitrary number of buffer changes. These undos are recorded as ordinary buffer changes themselves. So when you break the chain of undos by issuing some other command, you can then undo all the undos. The chain of recorded buffer modifications therefore grows without bound, truncated only at garbage collection time.

The redo/undo system is different in two ways:

  1. The undo/redo command chain is only broken by a buffer modification. You can move around the buffer or switch buffers and still come back and do more undos or redos.

  2. The redo command rescinds the most recent undo without recording the change as a _new_ buffer change. It completely reverses the effect of the undo, which includes making the chain of buffer modification records shorter by one, to counteract the effect of the undo command making the record list longer by one.

To use this package, add the following to your initialization file:

  (require 'redo)

[ << ] [ >> ]           [Top] [Contents] [Index] [ ? ]

This document was generated by XEmacs Webmaster on October, 2 2007 using texi2html