all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Difference between Font-Lock and Overlays
@ 2008-10-10 11:19 Nordlöw
  2008-10-10 15:50 ` Nikolaj Schumacher
  0 siblings, 1 reply; 2+ messages in thread
From: Nordlöw @ 2008-10-10 11:19 UTC (permalink / raw)
  To: help-gnu-emacs

When should I use font-lock-add-keywords() and when should I use
overlays to realize syntax highlighting?

Finally, in what cases should I prefer to use Toby Cubitt's auto-
overlays package?

/Nordlöw


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Difference between Font-Lock and Overlays
  2008-10-10 11:19 Difference between Font-Lock and Overlays Nordlöw
@ 2008-10-10 15:50 ` Nikolaj Schumacher
  0 siblings, 0 replies; 2+ messages in thread
From: Nikolaj Schumacher @ 2008-10-10 15:50 UTC (permalink / raw)
  To: Nordlöw; +Cc: help-gnu-emacs

Nordlöw <per.nordlow@gmail.com> wrote:

> When should I use font-lock-add-keywords() and when should I use
> overlays to realize syntax highlighting?

I'd say, if what you're highlighting syntax, and the syntax is simple
enough, use font-lock.

If you're highlighting something temporarily or dynamically, use
overlays.

Otherwise, you can also directly set the text's properties as you're
parsing.

regards,
Nikolaj Schumacher




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-10-10 15:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-10-10 11:19 Difference between Font-Lock and Overlays Nordlöw
2008-10-10 15:50 ` Nikolaj Schumacher

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.