61 |
|
|
62 |
;; Actual code |
;; Actual code |
63 |
|
|
|
(defvar reveal-backtrace nil) |
|
|
|
|
64 |
(defun reveal-post-command () |
(defun reveal-post-command () |
65 |
;; Refresh the spots that might have changed. |
;; Refresh the spots that might have changed. |
66 |
;; `Refreshing' here means to try and re-hide the corresponding text. |
;; `Refreshing' here means to try and re-hide the corresponding text. |
107 |
(setq repeat t) |
(setq repeat t) |
108 |
(condition-case err |
(condition-case err |
109 |
(funcall open ol nil) |
(funcall open ol nil) |
110 |
(error (setq reveal-backtrace (backtrace)) |
(error (message "!!Reveal-show: %s !!" err) |
|
(message "!!Reveal-show: %s !!" err) |
|
111 |
;; Let's default to a meaningful behavior to avoid |
;; Let's default to a meaningful behavior to avoid |
112 |
;; getting stuck in an infinite loop. |
;; getting stuck in an infinite loop. |
113 |
|
(setq repeat nil) |
114 |
(overlay-put ol 'invisible nil)))))))) |
(overlay-put ol 'invisible nil)))))))) |
115 |
;; Close old overlays. |
;; Close old overlays. |
116 |
(dolist (ol old-ols) |
(dolist (ol old-ols) |
132 |
(get ol 'isearch-open-invisible-temporary))))) |
(get ol 'isearch-open-invisible-temporary))))) |
133 |
(condition-case err |
(condition-case err |
134 |
(funcall open ol t) |
(funcall open ol t) |
135 |
(error (setq reveal-backtrace (backtrace)) |
(error (message "!!Reveal-hide: %s !!" err))) |
|
(message "!!Reveal-hide: %s !!" err))) |
|
136 |
(overlay-put ol 'invisible inv))))))) |
(overlay-put ol 'invisible inv))))))) |
137 |
(error (setq reveal-backtrace (backtrace)) |
(error (message "Reveal: %s" err))))) |
|
(message "Reveal: %s" err))))) |
|
138 |
|
|
139 |
;;;###autoload |
;;;###autoload |
140 |
(define-minor-mode reveal-mode |
(define-minor-mode reveal-mode |