]> code.delx.au - gnu-emacs/blobdiff - lisp/reveal.el
Protect against changes of interval tree when adding/removing text props.
[gnu-emacs] / lisp / reveal.el
index ff5c8807de59e53e7f48006bf224fcb0e401c9db..92c1178041c6100b5f6aa93ad92ce77ae70df055 100644 (file)
@@ -1,7 +1,6 @@
-;;; reveal.el --- Automatically reveal hidden text at point
+;;; reveal.el --- Automatically reveal hidden text at point -*- lexical-binding: t -*-
 
-;; Copyright (C) 2000, 2001, 2002, 2003, 2004,
-;;   2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
+;; Copyright (C) 2000-2013 Free Software Foundation, Inc.
 
 ;; Author: Stefan Monnier <monnier@iro.umontreal.ca>
 ;; Keywords: outlines
@@ -107,7 +106,7 @@ Each element has the form (WINDOW . OVERLAY).")
           (let ((inv (overlay-get ol 'invisible)) open)
             (when (and inv
                        ;; There's an `invisible' property.  Make sure it's
-                       ;; actually invisible, and ellipsised.
+                       ;; actually invisible, and ellipsized.
                        (and (consp buffer-invisibility-spec)
                             (cdr (assq inv buffer-invisibility-spec)))
                        (or (setq open
@@ -190,12 +189,13 @@ Each element has the form (WINDOW . OVERLAY).")
 
 ;;;###autoload
 (define-minor-mode reveal-mode
-  "Toggle Reveal mode on or off.
-Reveal mode renders invisible text around point visible again.
+  "Toggle uncloaking of invisible text near point (Reveal mode).
+With a prefix argument ARG, enable Reveal mode if ARG is
+positive, and disable it otherwise.  If called from Lisp, enable
+Reveal mode if ARG is omitted or nil.
 
-Interactively, with no prefix argument, toggle the mode.
-With universal prefix ARG (or if ARG is nil) turn mode on.
-With zero or negative ARG turn mode off."
+Reveal mode is a buffer-local minor mode.  When enabled, it
+reveals invisible text around point."
   :group 'reveal
   :lighter (global-reveal-mode nil " Reveal")
   :keymap reveal-mode-map
@@ -208,12 +208,12 @@ With zero or negative ARG turn mode off."
 
 ;;;###autoload
 (define-minor-mode global-reveal-mode
-  "Toggle Reveal mode in all buffers on or off.
+  "Toggle Reveal mode in all buffers (Global Reveal mode).
 Reveal mode renders invisible text around point visible again.
 
-Interactively, with no prefix argument, toggle the mode.
-With universal prefix ARG (or if ARG is nil) turn mode on.
-With zero or negative ARG turn mode off."
+With a prefix argument ARG, enable Global Reveal mode if ARG is
+positive, and disable it otherwise.  If called from Lisp, enable
+the mode if ARG is omitted or nil."
   :global t :group 'reveal
   (setq-default reveal-mode global-reveal-mode)
   (if global-reveal-mode
@@ -225,5 +225,4 @@ With zero or negative ARG turn mode off."
 
 (provide 'reveal)
 
-;; arch-tag: 96ba0242-2274-4ed7-8e10-26bc0707b4d8
 ;;; reveal.el ends here