is there any package that tracks changes made on an instantaneous basis? That is, just like handwriting captures edits, I would like to see all the changes as a buffer is developing. So, there is no separate ediff or compare call to make, but live tracking of all the deletions, backstrokes, etc. Any pointers? Thanks, -jay

enter image description here

  • The question is not very clear. Track all editing changes how? What kind of tracking? Try to specify more clearly what you have in mind. – Drew Sep 15 '17 at 0:46
  • Apologies for being unclear. Let's say I type a few words and then go back and edit a few of them, I would like to see the changes I just made. So, if I changed "tell" to "well" I should see the "t" changed to "w." Does that make sense? Thanks. – Jay Iyer Sep 15 '17 at 0:50
  • 1
    You should "see" it how? If you have some kind of visualisation in mind, perhaps you could show or describe it in the question. I'm having trouble imagining anything like this which isn't rapidly going to become all but unmanageable. Are you talking about tracking all changes (essentially processing the undo list), or only tracking the differences between the current state and the saved state? – phils Sep 15 '17 at 3:34
  • Phils: I hope the image above clarifies the question. The tracking should show the differences between what was originally typed and subsequent edits, ideally even in an unsaved buffer. – Jay Iyer Sep 15 '17 at 4:00
  • 1
    That's helpful, but a bit simplistic. If it's tracking all changes, can you please show an example with multiple edits to the same piece of text? e.g. After the sequences of transitions from "demontrate" => "demonstrate" => "demoate" => "demotrate" => "demonstrate", what does the buffer look like? – phils Sep 15 '17 at 4:28
  1. Command highlight-changes-mode:

highlight-changes-mode is an interactive autoloaded Lisp function in hilit-chg.el.

(highlight-changes-mode &optional ARG)

Toggle highlighting changes in this buffer (Highlight Changes mode).

With a prefix argument ARG, enable Highlight Changes mode if ARG is positive, and disable it otherwise. If called from Lisp, enable the mode if ARG is omitted or nil.

When Highlight Changes is enabled, changes are marked with a text property. Normally they are displayed in a distinctive face, but command M-x highlight-changes-visible-mode can be used to toggle this on and off.

Other functions for buffers in this mode include:

  • M-x highlight-changes-next-change - move point to beginning of next change

  • M-x highlight-changes-previous-change - move to beginning of previous change

  • M-x highlight-changes-remove-highlight - remove the change face from the region

  • M-x highlight-changes-rotate-faces - rotate different "ages" of changes through various faces.

  • M-x highlight-compare-with-file - mark text as changed by comparing this buffer with the contents of a file

  • M-x highlight-compare-buffers highlights differences between two buffers.

  1. Command diff-backup (less "instantaneous" - just a diff from the last backup):

diff-backup is an interactive autoloaded Lisp function in diff.el.

(diff-backup FILE &optional SWITCHES)

Diff this file with its backup file or vice versa. Uses the latest backup, if there are several numerical backups. If this file is a backup, diff it with its original. The backup file is the first file given to diff. With prefix arg, prompt for diff switches.

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.