summaryrefslogtreecommitdiff
path: root/elisp/geiser-edit.el
diff options
context:
space:
mode:
authorJose Antonio Ortega Ruiz <jao@gnu.org>2013-08-25 07:12:07 +0200
committerJose Antonio Ortega Ruiz <jao@gnu.org>2013-08-25 07:12:07 +0200
commit2a903ff81c1696a05d99bc78ebc9558f64b41c81 (patch)
treea7d0cb5f4a7929cdba277b01685c1a550f6b4346 /elisp/geiser-edit.el
parentf417431b8b72fbc6e98c1310b99cba50882b13d2 (diff)
downloadgeiser-2a903ff81c1696a05d99bc78ebc9558f64b41c81.tar.gz
geiser-2a903ff81c1696a05d99bc78ebc9558f64b41c81.tar.bz2
Let's make it *any* submodule
So the new functions are named geiser-racket-*-submodules, and by default all submodule forms are hidden. Now that we have the helpers in geiser-edit, we could have a generic command in geiser-mode to change the visibility of form at point.
Diffstat (limited to 'elisp/geiser-edit.el')
-rw-r--r--elisp/geiser-edit.el6
1 files changed, 5 insertions, 1 deletions
diff --git a/elisp/geiser-edit.el b/elisp/geiser-edit.el
index f75e303..d43cf9b 100644
--- a/elisp/geiser-edit.el
+++ b/elisp/geiser-edit.el
@@ -191,7 +191,7 @@ or following links in error buffers.")
(let ((cloak (geiser-edit--cloak form)))
(save-excursion
(goto-char (point-min))
- (while (re-search-forward (format "(%s\\b" (regexp-quote form)) nil t)
+ (while (re-search-forward (format "(%s\\b" form) nil t)
(let* ((beg (match-beginning 0))
(end (progn (ignore-errors (goto-char beg) (forward-sexp))
(point))))
@@ -204,6 +204,10 @@ or following links in error buffers.")
(remove-overlays nil nil 'invisible cloak)
(remove-from-invisibility-spec (cons cloak t))))
+(defun geiser-edit--show-all ()
+ (remove-overlays)
+ (setq buffer-invisibility-spec '(t)))
+
(defun geiser-edit--toggle-visibility (form)
(if (and (listp buffer-invisibility-spec)
(assoc (geiser-edit--cloak form) buffer-invisibility-spec))