all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: tomer <tomer1levin@walla.co.il>
To: help-gnu-emacs@gnu.org
Subject: Re: hook for search next
Date: Wed, 6 May 2009 23:47:29 -0700 (PDT)	[thread overview]
Message-ID: <883be5cc-7274-4fdd-99b7-5d15084b6887@z7g2000vbh.googlegroups.com> (raw)
In-Reply-To: mailman.6751.1241621587.31690.help-gnu-emacs@gnu.org

On May 6, 5:52 pm, Kevin Rodgers <kevin.d.rodg...@gmail.com> wrote:
> tomer wrote:
> > On May 5, 3:40 pm, Kevin Rodgers <kevin.d.rodg...@gmail.com> wrote:
> >> tomer wrote:
> >>> i want to print message after each search (ctrl-s) in search-minor
> >>> mode.Is it possilbe to hook for this purpose?
> >>> Is there other way other than hook?
> >>> it is very important.
> >> ,----[ C-h v isearch-mode-end-hook RET ]
> >> | isearch-mode-end-hook is a variable defined in `isearch.el'.
> >> | Its value is nil
> >> |
> >> |
> >> | Documentation:
> >> | Function(s) to call after terminating an incremental search.
> >> | When these functions are called, `isearch-mode-end-hook-quit'
> >> | is non-nil if the user quit the search.
> >> |
> >> | [back]
> >> `----
>
> >> --
> >> Kevin Rodgers
> >> Denver, Colorado, USA
>
> > Thanks for the answer,
> > I knew that hooks, these hook are only in the end of the search.
> > I need a hook each time a new search is found (each time pressing ctrl
> > +s in isearch mode).
> > Is it possbile?
>
> Try after-advising isearch-search and check isearch-success.
>
> --
> Kevin Rodgers
> Denver, Colorado, USA- Hide quoted text -
>
> - Show quoted text -

Thanks a lot
I have succeed in other way , but i will try this also.
here is my solution:

(defun tl-isearch-start()
  (if (eq major-mode 'specman-mode)
  (add-hook 'post-command-hook 'specman-describe-context)))

(defun tl-isearch-end()
  (if (eq major-mode 'specman-mode)
  (remove-hook 'post-command-hook 'specman-describe-context)))

(add-hook 'isearch-mode-hook 'tl-isearch-start)

(add-hook 'isearch-mode-end-hook 'tl-isearch-end)

Thanks a lot for the help



  parent reply	other threads:[~2009-05-07  6:47 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-05  8:43 hook for search next tomer
2009-05-05 12:40 ` Kevin Rodgers
     [not found] ` <mailman.6649.1241527217.31690.help-gnu-emacs@gnu.org>
2009-05-06  8:07   ` tomer
2009-05-06 14:52     ` Kevin Rodgers
     [not found]     ` <mailman.6751.1241621587.31690.help-gnu-emacs@gnu.org>
2009-05-07  6:47       ` tomer [this message]
2009-08-12  7:28     ` better search Maindoor
2009-08-12 15:30       ` Lennart Borgman
2009-08-13  5:57         ` Maindoor
2009-08-31  7:15         ` company-mode question Maindoor

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=883be5cc-7274-4fdd-99b7-5d15084b6887@z7g2000vbh.googlegroups.com \
    --to=tomer1levin@walla.co.il \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.