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

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

bug#21957: 24.5; Make occur search within regions when there is one


From: Juri Linkov
Subject: bug#21957: 24.5; Make occur search within regions when there is one
Date: Mon, 23 Nov 2015 02:22:59 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (x86_64-pc-linux-gnu)

> I've been thinking it might be nice to have an occur-dwim command.
>
> 1. If the selected region has multiple lines, it would search only inside
> the region.
> 2. If the selected region has one line or less, it would use the region as
> the search string.
> 3. If there's no selection it do the usual occur.

This is a useful heuristic, not sure how intuitive it is.

BTW, I recall Drew asked how to do the same in Isearch, but I see no way
because in Isearch it's useful to mark the beginning of the region, and
extend it using Isearch commands by putting the end of the region where
Isearch ends.





reply via email to

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