[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: make `occur' use word at point as default
From: |
Stefan Monnier |
Subject: |
Re: make `occur' use word at point as default |
Date: |
Thu, 01 Sep 2005 09:08:38 -0400 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) |
> 1. word at point - (current-word t)
> 2. tag at point - (funcall (or find-tag-default-function
> (get major-mode 'find-tag-default-function)
> 'find-tag-default))
These are pretty much the same. More specifically the tag should include
the current-word as a substring, so I'd drop the number 1 and just keep
number 2.
> 3. active region - (and transient-mark-mode mark-active
> (buffer-substring-no-properties
> (region-beginning) (region-end)))
You could have done M-w before the current operation. Much simpler/quicker
than doing M-n M-n M-n searching for it.
> 4. last isearch regexp - (car regexp-search-ring)
This one makes sense. Maybe we could simply use the same ring for occur as
for regexp-search so that it is available as M-p.
> 5. last kill from the kill ring - (current-kill 0)
C-y brings it more quickl;y and reliably than M-n M-n M-n M-n.
I.e. there are really only 2 different useful values and we could make one
of the two available via M-p.
Stefan
- Re: make `occur' use word at point as default, Juri Linkov, 2005/09/01
- Re: make `occur' use word at point as default,
Stefan Monnier <=
- Re: make `occur' use word at point as default, Richard M. Stallman, 2005/09/01
- RE: make `occur' use word at point as default, Drew Adams, 2005/09/01
- Re: make `occur' use word at point as default, Richard M. Stallman, 2005/09/02
- RE: make `occur' use word at point as default, Drew Adams, 2005/09/02
- RE: make `occur' use word at point as default, Drew Adams, 2005/09/02
- Re: make `occur' use word at point as default, Benjamin Riefenstahl, 2005/09/03
- Re: make `occur' use word at point as default, Richard M. Stallman, 2005/09/03