bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#49731: 28.0.50; Filter xref results by filename


From: Juri Linkov
Subject: bug#49731: 28.0.50; Filter xref results by filename
Date: Wed, 23 Nov 2022 20:20:25 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu)

>>> Do you plan on adding an outline-[minor-]mode command to hide/show by
>>> regexp?
>> Do you mean enabling outline-minor-mode in the xref buffer?
>> Currently to enable it, the users need to add to the init file:
>>    (add-hook 'xref-after-update-hook 'outline-minor-mode)
>> that is not too self-evident.  Maybe a new option could help?
>
> No, I mean suppose I have enabled outline-minor-mode manually.
>
> How do I filter the groups by name/regexp?

Ah, now I see.  This is easy as well, for example,
this is what I use for the Emacs source repo:

#+begin_src emacs-lisp
(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)))
#+end_src

where "ChangeLog" and "test/manual/etags" are not interesting groups.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]