emacs-devel
[Top][All Lists]
Advanced

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

Re: Is the doc string for font-lock-add-keywords correct?


From: Glenn Morris
Subject: Re: Is the doc string for font-lock-add-keywords correct?
Date: Thu, 17 Jan 2008 20:47:28 -0500

Lennart Borgman wrote (on Thu, 17 Jan 2008 at 23:51 +0100):

> I just tested to add some keywords in the *scratch* buffer, but I can 
> not get any changes to the fontification of the comment.

Give a complete recipe.

Works fine for me:

(font-lock-add-keywords nil '(("FOOBAR" 0 font-lock-warning-face t)))

Now type:

;; FOOBAR is a warning

(You need to do something to trigger refontification.)

> There was a discussion about the highlighting regular expressions 
> before. hi-lock-mode seems to do a similar thing. I do not understand 
> what it does, but does it not do a bit more to achieve the highlighting 
> everywhere in the buffer? (hi-lock-mode works ok for me.)

What?




reply via email to

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