bug#81512: [PATCH] Add command `outline-occur'
Roi Martin <[email protected]>
| Newsgroups | gmane.emacs.bugs |
|---|---|
| Message-ID | <[email protected]> |
Michael Heerdegen <[email protected]> writes: > BTW, what I did not yet understand is why you must locally modify the > behavior of `occur' in this case, but not for other `occur' invocations. The first version of `outline-occur' called `occur' this way: (let ((occur-hook (lambda () (pop-to-buffer "*Occur*")))) (occur (concat "^\\(?:" regexp "\\)"))) This was done because it was convenient to pop to the Occur window and just start navigating the outline. However, Juri pointed out that: > overriding `occur-hook' with `pop-to-buffer' is not the right way to > customize the buffer display behavior. For the specific case of `outline-occur', it was probably fine to just call `occur' and carry on with the default behaviour. However, there were already other similar situations that required workarounds. So, we decided to add `display-buffer-default-alist' and address those as well. One example of such a situation is Bug#81233. https://lists.gnu.org/archive/html/emacs-devel/2026-08/msg00157.html Roi