all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Ihor Radchenko <yantar92@posteo.net>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 60399-done@debbugs.gnu.org, juri@linkov.net
Subject: bug#60399: 30.0.50; Usage of `isearch-open-invisible-temporary' is not documented
Date: Mon, 02 Jan 2023 08:57:11 +0000	[thread overview]
Message-ID: <875ydp5n6g.fsf@localhost> (raw)
In-Reply-To: <83tu1a2wbv.fsf@gnu.org>

Eli Zaretskii <eliz@gnu.org> writes:

> Thanks, this background was indeed missing.  However, even after
> reading it, I still don't understand how come you need or want to
> delete these overlays -- aren't they needed to hide the text to begin
> with?
>
> Or IOW, if you are deleting and recreating the overlays, why do you
> need to use this isearch feature at all? just delete them when you
> want to show the text, and reapply them later when you want the text
> hidden again.

This is pretty much what is being done: I try to hook into isearch code
to (1) when isearch is about to display the match, I save the old
overlays and re-arrange them to display the match as needed; (2) when
isearch moves to the next match, I restore the old overlays.

However, because isearch expects the overlays to exist even upon
revealing the isearch match, I cannot achieve what I want. Even though
my code would work fine, isearch itself errs in
`isearch-close-unnecessary-overlays'/`isearch-open-necessary-overlays'
where it does additional checks involving `overlay-start' and
`overlay-end' that must be non-nil.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>





  reply	other threads:[~2023-01-02  8:57 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-29 10:10 bug#60399: 30.0.50; Usage of `isearch-open-invisible-temporary' is not documented Ihor Radchenko
2022-12-29 17:33 ` Juri Linkov
2022-12-31 13:03   ` Ihor Radchenko
2023-01-01  9:05     ` Eli Zaretskii
2023-01-01  9:09       ` Ihor Radchenko
2023-01-01 11:00         ` Eli Zaretskii
2023-01-01 12:51           ` Ihor Radchenko
2023-01-01 13:55             ` Eli Zaretskii
2023-01-02  8:57               ` Ihor Radchenko [this message]
2023-01-02 12:29                 ` Eli Zaretskii
2023-01-02 15:34             ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-03  9:02               ` Ihor Radchenko
2023-01-03 14:14                 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=875ydp5n6g.fsf@localhost \
    --to=yantar92@posteo.net \
    --cc=60399-done@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=juri@linkov.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.