summaryrefslogtreecommitdiff
path: root/cider-overlays.el
diff options
context:
space:
mode:
authorArtur Malabarba <bruce.connor.am@gmail.com>2015-10-03 15:55:27 +0100
committerArtur Malabarba <bruce.connor.am@gmail.com>2015-10-03 17:19:39 +0100
commit0c5c92a6acaa698ed6cf5f6c0c8f7190a8dc1f7f (patch)
tree997b10fbb4d1dcd0d5de80ffe2ac38d5ce6e0283 /cider-overlays.el
parent396af5f54eebe873a19003c8199a43db5aac2284 (diff)
Speed up cider--make-result-overlay
pos-visible-in-window-p is very slow.
Diffstat (limited to 'cider-overlays.el')
-rw-r--r--cider-overlays.el2
1 files changed, 1 insertions, 1 deletions
diff --git a/cider-overlays.el b/cider-overlays.el
index 1446ada0..a8dc2023 100644
--- a/cider-overlays.el
+++ b/cider-overlays.el
@@ -168,7 +168,7 @@ overlay."
(cider--remove-result-overlay-after-command))))
(-when-let (win (get-buffer-window buffer))
;; Left edge is visible.
- (when (and (pos-visible-in-window-p (point) win)
+ (when (and (<= (window-start win) (point) (window-end win))
;; Right edge is visible. This is a little conservative
;; if the overlay contains line breaks.
(or (< (+ (current-column) (string-width value))