* isearch and M-x occur questions(several)
@ 2003-04-25 18:23 Javier Oviedo
2003-04-25 18:26 ` Javier Oviedo
2003-04-26 14:16 ` Kai Großjohann
0 siblings, 2 replies; 6+ messages in thread
From: Javier Oviedo @ 2003-04-25 18:23 UTC (permalink / raw)
Hello all:
I'm running emacs 21.2.1 on WindowsXP.
I have just discovered "M-x occur" and like it very much.
1. Is there a way, or an already existing package, to combine isearch and
occur. What I like about occur is the window that lists the line number and
matching expression. Is there a way that isearch could do something similar?
I like the ability to quickly run through all matches in isearch using
isearch-forward, but would also like the option of having that window simply
show me all lines with matches.
2. Can the occur-mode window, which lists all line with matching
expressions, display the line in the particular font-lock-face for the mode
of the file being searched? For example, if my expression happens to exist
in a C function prototype, the occur-more window would show that line with
the appropriate c-mode faces.
3. Can occur highlight the matching expression in the occur-mode window?
I hope that my questions make sense. Thanks in advance.
--
=======
Javier
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: isearch and M-x occur questions(several)
2003-04-25 18:23 isearch and M-x occur questions(several) Javier Oviedo
@ 2003-04-25 18:26 ` Javier Oviedo
2003-04-26 14:16 ` Kai Großjohann
1 sibling, 0 replies; 6+ messages in thread
From: Javier Oviedo @ 2003-04-25 18:26 UTC (permalink / raw)
Please ignore question numbers 2 and 3. Occur-mode already handles these
issues.
--
=======
Javier
"Javier Oviedo" <email_joviedo@yahoo.com> wrote in message
news:b8buaj$ajp$1@tilde.itg.ti.com...
> Hello all:
>
> I'm running emacs 21.2.1 on WindowsXP.
>
> I have just discovered "M-x occur" and like it very much.
>
> 1. Is there a way, or an already existing package, to combine isearch and
> occur. What I like about occur is the window that lists the line number
and
> matching expression. Is there a way that isearch could do something
similar?
> I like the ability to quickly run through all matches in isearch using
> isearch-forward, but would also like the option of having that window
simply
> show me all lines with matches.
>
> 2. Can the occur-mode window, which lists all line with matching
> expressions, display the line in the particular font-lock-face for the
mode
> of the file being searched? For example, if my expression happens to exist
> in a C function prototype, the occur-more window would show that line with
> the appropriate c-mode faces.
>
> 3. Can occur highlight the matching expression in the occur-mode window?
>
> I hope that my questions make sense. Thanks in advance.
>
>
> --
> =======
> Javier
>
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: isearch and M-x occur questions(several)
2003-04-25 18:23 isearch and M-x occur questions(several) Javier Oviedo
2003-04-25 18:26 ` Javier Oviedo
@ 2003-04-26 14:16 ` Kai Großjohann
2003-04-26 19:00 ` Johan Bockgård
1 sibling, 1 reply; 6+ messages in thread
From: Kai Großjohann @ 2003-04-26 14:16 UTC (permalink / raw)
"Javier Oviedo" <email_joviedo@yahoo.com> writes:
> 1. Is there a way, or an already existing package, to combine isearch and
> occur. What I like about occur is the window that lists the line number and
> matching expression. Is there a way that isearch could do something similar?
> I like the ability to quickly run through all matches in isearch using
> isearch-forward, but would also like the option of having that window simply
> show me all lines with matches.
Maybe M-x occur RET could default to (regexp-quote
THE-LAST-ISEARCH-STRING). But this is unimplemented.
Another useful thing might be to bind a key in isearch-mode-map that
runs occur with the right options.
--
file-error; Data: (Opening input file no such file or directory ~/.signature)
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: isearch and M-x occur questions(several)
2003-04-26 14:16 ` Kai Großjohann
@ 2003-04-26 19:00 ` Johan Bockgård
2003-04-26 20:02 ` drf5n
2003-04-28 13:51 ` Javier Oviedo
0 siblings, 2 replies; 6+ messages in thread
From: Johan Bockgård @ 2003-04-26 19:00 UTC (permalink / raw)
kai.grossjohann@gmx.net (Kai Großjohann) writes:
> Another useful thing might be to bind a key in isearch-mode-map that
> runs occur with the right options.
I like that.
(defun isearch-occur ()
"Run `occur' with current isearch string."
(interactive)
(let ((case-fold-search isearch-case-fold-search)
(search-string (if isearch-regexp
isearch-string
(regexp-quote isearch-string))))
(occur search-string)))
(define-key isearch-mode-map [(control o)] 'isearch-occur)
--
Johan Bockgård
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2003-04-28 13:51 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-04-25 18:23 isearch and M-x occur questions(several) Javier Oviedo
2003-04-25 18:26 ` Javier Oviedo
2003-04-26 14:16 ` Kai Großjohann
2003-04-26 19:00 ` Johan Bockgård
2003-04-26 20:02 ` drf5n
2003-04-28 13:51 ` Javier Oviedo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).