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

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

Re: editing buffer -> call function


From: Nikolaj Schumacher
Subject: Re: editing buffer -> call function
Date: Mon, 18 May 2009 21:24:48 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.93 (darwin)

Sebastien LE MAGUER <Sebastien.Le_maguer@irisa.fr> wrote:

> I wonder how to call a function everytime a buffer is updated. For example :
> - I want to highlight each instance a specific word
> - Every time I write this word after the search, I want to highlight it
> automatically or if I delete an instance of it clear the overlay.
>
> Can you help me ?

Use the hook `after-change-functions'.

Or you can leave the work to `highlight-regexp'.  Look at
highlight-symbol.el[1] for an example.


regards,
Nikolaj Schumacher

[1]: http://nschum.de/src/emacs/highlight-symbol/




reply via email to

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