;;; Commentary:
 ;; The function `hide-region-hide' hides the region. You can hide many
 ;; different regions and they will be "marked" by two configurable
 ;; strings (so that you know where the hidden text is).
 ;; The hidden regions is pushed on a kind of hide-region "ring".
 ;; The function `hide-region-unhide' "unhides" one region, starting
 ;; with the last one you hid.
 ;; The best is to try it out.

Get the code here: Lisp:hide-region.el

See Also:


I added a patch for unhiding the region at the point. MathiasDahl’s email (mathias.rem0veth1s.dahl@gmail.com) doesn’t exist anymore, so maybe this is a reasonable place to notify him. – ChrisDone

Woops. I just realised there’s some nonsense (“rem0veth1s”) in the email. Mathias, you use GMail! You don’t need to do this! Anyway, I’ll forward my email onto the correct address. – ChrisDone

Thanks, Chris! ;) I think I stopped that nonsense some time ago after realizing GMail saves me most of the time ;) – MaDa

I make an enhance of hide-region.el, named it hide-region+, add three more functions: 1 hide-region-unhide-below unhide a region just below the point 2 hide-region-unhide-all unhide all the region in the current buffer 3 hide-region-toggle toggle all the gide region in the current buffer

Updates to hide-region+, Version bump to 1.0.2:

  • hide-region-hide now returns the newly created region
  • moved face for “handles” (region pre/postfix) to defcust
  • various docstring and misc fixups
  • mark myself as maintainer (after checking-in with Mathais)

CategoryHideStuff CategoryRegion