[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

advanced selective undo demo

From: Barry OReilly
Subject: advanced selective undo demo
Date: Sun, 6 Jul 2014 16:24:12 -0400

> It has some good ideas which could be ported to emacs (timeline,
> etc.).
> Check it out:
> http://www.youtube.com/watch?v=blbIBdlUGIc&feature=youtu.be

Looks neat. Much of capability exists for Emacs, some in the
builtin undo system and some in the Undo Tree package.

To comment by use case presented in the video:

1: View individual changes in the undo history:

  Builtin: The buffer-undo-list variable is a timeline of buffer edits
  and their types. It's not a user friendly way to visualize past

  Undo Tree: The user can navigate the undo tree and see past states
  of the buffer. If the user enabled Undo Tree's diff mode
  (undo-tree-visualizer-toggle-diff) a diff-mode buffer will show the
  current node diffed against its parent. Using
  undo-tree-visualizer-selection-mode, the user can diff against
  arbitrary nodes of the undo tree.

  Undo Tree does not visualize the undo types.

2: See where changes were made in the code editor:

  Builtin: This is not offered to the user as such.

  Undo Tree: The user would have to infer this information from the
  aforementioned diffs.

3: Selectively undo a past edit without undoing more recent edits:

  Builtin: This feature is called "undo in region". The user can
  select a region of the buffer, undo, and Emacs will undo the most
  recent edit in that region.

  Undo Tree: Undo in region is implemented. It has some bugs that make
  it mostly unusable for me when using Undo Tree.

  For trickier cases of extracting past edits from history, it is
  useful to navigate the undo tree to the past state, copy the
  relevant code, return to the present state, paste, and touch it up.

4: View undo history only within a region.

  Builtin: Internally, Emacs builds up this subset of history as the
  pending-undo-list. It is not presented externally to the user.

  Undo Tree: You cannot view history by region.

5: Search history

  Builtin: You can C-h v buffer-undo-list and search for a
  string. This will find strings not in the current buffer. The user
  would copy and paste whatever they find of interest.

  Undo Tree: You can C-h v buffer-undo-tree and do likewise.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]