From: Ihor Radchenko <yantar92@posteo.net>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: 60399-done@debbugs.gnu.org, Eli Zaretskii <eliz@gnu.org>,
60399@debbugs.gnu.org, juri@linkov.net
Subject: bug#60399: 30.0.50; Usage of `isearch-open-invisible-temporary' is not documented
Date: Tue, 03 Jan 2023 09:02:14 +0000 [thread overview]
Message-ID: <87mt70kn3d.fsf@localhost> (raw)
In-Reply-To: <jwvh6x9klyn.fsf-monnier+emacs@gnu.org>
Stefan Monnier <monnier@iro.umontreal.ca> writes:
> But it's very natural that the caller of that
> `isearch-open-invisible-temporary` may still want to know the boundaries
> of this overlay after its content is made visible, so as to know when to
> make it invisible again.
I am not sure why isearch should decide this instead of letting
`isearch-open-invisible-temporary' decide what to close.
> The caller could store that information on its own (with a pair of
> markers or another overlay), but it's very natural for the caller to
> just use that overlay.
I'd say easy, not natural. The callee may want to do something with
_all_ the overlays it originally opened, not just the overlays it
originally opened, which _are also intersecting some unspecified
boundary_.
>> I am not even sure how to achieve the desired custom behavior using the
>> current isearch implementation.
>
> `reveal-toggle-invisible` works basically the same way as
> `isearch-open-invisible-temporary` and in
> `outline-reveal-toggle-invisible` I had the same problem as you do,
> which I solved with:
>
> (let ((o1 (copy-overlay o)))
> (overlay-put o 'invisible nil) ;Show (most of) the text.
This is a nice trick, which is unfortunately not very useful in my
situation. Some text should still remain invisible in Org even when
opening is requested. Your code reveals everything unconditionally.
--
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>
next prev parent reply other threads:[~2023-01-03 9:02 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
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 [this message]
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87mt70kn3d.fsf@localhost \
--to=yantar92@posteo.net \
--cc=60399-done@debbugs.gnu.org \
--cc=60399@debbugs.gnu.org \
--cc=eliz@gnu.org \
--cc=juri@linkov.net \
--cc=monnier@iro.umontreal.ca \
/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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).