GNU bug report logs -
#49731
28.0.50; Filter xref results by filename
Previous Next
Reported by: Daniel Martín <mardani29 <at> yahoo.es>
Date: Sun, 25 Jul 2021 08:21:02 UTC
Severity: normal
Found in version 28.0.50
Fixed in version 30.0.50
Done: Juri Linkov <juri <at> linkov.net>
Bug is archived. No further changes may be made.
Full log
Message #104 received at 49731 <at> debbugs.gnu.org (full text, mbox):
>> (add-hook 'xref-after-update-hook
>> (lambda ()
>> (setq-local outline-default-state 1
>> outline-default-rules
>> '((match-regexp . "ChangeLog\\|test/manual/etags")))
>> (outline-minor-mode +1)))
>> where "ChangeLog" and "test/manual/etags" are not interesting groups.
>
> Makes sense.
>
> But IME the files you currently want to filter out depend on your current
> activity: sometimes you want to show the tests, and sometimes
> not. Sometimes you want to see the tests only.
>
> So it might be generally useful to have an interactive command to filter
> out whatever one might prefer. If you agree, of course.
This would be a nice addition to outline.el. For example, new commands
outline-hide-by-regexp and outline-show-by-regexp that could use
existing code extracted from outline--show-headings-up-to-level:
(outline-map-region
(lambda ()
(when (let ((beg (point))
(end (progn (outline-end-of-heading) (point))))
(string-match-p heading-regexp (buffer-substring beg end)))
;; hide entry when heading match regexp
(outline-hide-entry))))
This bug report was last modified 1 year and 49 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.