Function: hs-isearch-show-temporary
hs-isearch-show-temporary is a byte-compiled function defined in
hideshow.el.gz.
Signature
(hs-isearch-show-temporary OV HIDE-P)
Documentation
Hide or show overlay OV, and set hs-headline, all depending on HIDE-P.
If HIDE-P is non-nil, hs-headline is set to nil and overlay OV is hidden.
Otherwise, hs-headline is set to the line of text at the head of OV, and
OV is shown.
This function is meant to be used as the isearch-open-invisible-temporary
property of an overlay.
Source Code
;; Defined in /usr/src/emacs/lisp/progmodes/hideshow.el.gz
(defun hs-isearch-show-temporary (ov hide-p)
"Hide or show overlay OV, and set `hs-headline', all depending on HIDE-P.
If HIDE-P is non-nil, `hs-headline' is set to nil and overlay OV is hidden.
Otherwise, `hs-headline' is set to the line of text at the head of OV, and
OV is shown.
This function is meant to be used as the `isearch-open-invisible-temporary'
property of an overlay."
(setq hs-headline
(if hide-p
nil
(or hs-headline
(let ((start (overlay-start ov)))
(buffer-substring
(save-excursion (goto-char start)
(beginning-of-line)
(skip-chars-forward " \t")
(point))
start)))))
(force-mode-line-update)
;; handle `display' property specially
(let (value)
(if hide-p
(when (setq value (overlay-get ov 'hs-isearch-display))
(overlay-put ov 'display value)
(overlay-put ov 'hs-isearch-display nil))
(when (setq value (overlay-get ov 'display))
(overlay-put ov 'hs-isearch-display value)
(overlay-put ov 'display nil))))
(overlay-put ov 'invisible (and hide-p 'hs)))