Skip to content
/ goggles Public

goggles.el - Pulse modified region

License

Notifications You must be signed in to change notification settings

minad/goggles

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

47 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

goggles.el - Pulse modified region

GNU Emacs MELPA MELPA Stable

Goggles highlights the modified region using pulse. Currently the commands undo, yank, kill and delete are supported.

This library is the holy counterpart of evil-goggles. Another comparable library is volatile-highlights, which does not use pulse. By setting goggle-pulse to nil, the goggles-mode behaves similarily to the volatile-highlights-mode.

https://github.com/minad/goggles/blob/main/goggles.gif?raw=true

Usage

(use-package goggles
  :hook ((prog-mode text-mode) . goggles-mode)
  :config
  (setq-default goggles-pulse t)) ;; set to nil to disable pulsing

Comparison to volatile-highlights

Goggles is mainly meant as a replacement for the popular volatile-highlights (vhl).

  • vhl does not support pulse. The request to use pulse for modification highlighting has come up a few times (e.g. recently on reddit).
  • vhl is unmaintained and contains obsolete code (e.g. cl instead of cl-lib).
  • vhl is unnecessarily complicated, with its extension mechanism. The extension mechanism seems to require bytecode compilation at startup.

Since improving volatile-highlights would require a rewrite, I decided to create another package. This way breakage for volatile-highlights users is avoided.