all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Matt Lundin <mdl@imapmail.org>
To: emacs-orgmode@gnu.org
Subject: [Bug] isearch errors when org-fold-core-style is 'overlays
Date: Tue, 27 Dec 2022 13:00:11 -0600	[thread overview]
Message-ID: <87pmc4smdg.fsf@fastmail.fm> (raw)

I'm finding that isearch fails to unfold the correct region or to search
in the correct region when there are folded regions in a buffer and
`org-fold-core-style` is set to 'overlays.

Here is a minimal recipe for reproducing the bug:

Use a minimal emacs startup file:

--8<---------------cut here---------------start------------->8---
(add-to-list 'load-path "~/org-mode/lisp/")
(setq org-startup-folded t)
(setq org-fold-core-style 'overlays)
--8<---------------cut here---------------end--------------->8---

Open the following file:

--8<---------------cut here---------------start------------->8---
* One
word
* Two
word
--8<---------------cut here---------------end--------------->8---

Issue #1:

Go to the beginning of headline "Two" when the trees are folded.

Type "M-x isearch word [RET]".

Expected behavior: isearch should reveal the entry under headline two
and shift the highlighted region dynamically as the characters typed
begin to match.

What happens: the beginning of the highlighted region remains stuck at
the beginning of the headline and the entry does not unfold until after
the return key is pressed.

Issue #2:

Cycle headlines to folded state. Go to the beginning of headline "Two".

Type "M-x isearch word [RET]".

Note that during this second search dynamically highlighted region
expands to include the folded headline "One". Once return is pressed,
isearch reveals the entry under headline "One" and moves the point to
the "word" there. 

After running git bisect, I traced the issue to commit
6cd7c6fb1cf6363f1057086760bed9875cdd97c7

Thanks,

Matt


             reply	other threads:[~2022-12-27 19:01 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-27 19:00 Matt Lundin [this message]
2022-12-28 10:43 ` [Bug] isearch errors when org-fold-core-style is 'overlays Ihor Radchenko
2022-12-29  2:21   ` Samuel Wales
2022-12-29  9:37     ` Ihor Radchenko
2022-12-30  5:59       ` Samuel Wales
2022-12-29 13:26   ` Ihor Radchenko
2023-01-16  9:32     ` Ihor Radchenko

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=87pmc4smdg.fsf@fastmail.fm \
    --to=mdl@imapmail.org \
    --cc=emacs-orgmode@gnu.org \
    /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.