unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Changes to syntax at fontification
@ 2010-09-13 10:43 Nordlöw
  2010-09-13 10:44 ` Nordlöw
  2010-09-13 21:16 ` Stefan Monnier
  0 siblings, 2 replies; 3+ messages in thread
From: Nordlöw @ 2010-09-13 10:43 UTC (permalink / raw)
  To: help-gnu-emacs

I just noticed some changes in emacs-bzr regarding syntax at
fontification.

What benefits will I have if start using the syntax-propertize-
function?

More efficient partial fontifications?

If I have extended my mode-specific colorings using calls to font-lock-
add-keywords can/should I somehow refactor these into calls to syntax-
propertize-function?

Thanks,
Nordlöw


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

* Re: Changes to syntax at fontification
  2010-09-13 10:43 Changes to syntax at fontification Nordlöw
@ 2010-09-13 10:44 ` Nordlöw
  2010-09-13 21:16 ` Stefan Monnier
  1 sibling, 0 replies; 3+ messages in thread
From: Nordlöw @ 2010-09-13 10:44 UTC (permalink / raw)
  To: help-gnu-emacs

Correction: I mean "syntax *and* fontification".

/Nordlöw


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

* Re: Changes to syntax at fontification
  2010-09-13 10:43 Changes to syntax at fontification Nordlöw
  2010-09-13 10:44 ` Nordlöw
@ 2010-09-13 21:16 ` Stefan Monnier
  1 sibling, 0 replies; 3+ messages in thread
From: Stefan Monnier @ 2010-09-13 21:16 UTC (permalink / raw)
  To: help-gnu-emacs

> What benefits will I have if start using the syntax-propertize-
> function?
[...]
> If I have extended my mode-specific colorings using calls to font-lock-
> add-keywords can/should I somehow refactor these into calls to syntax-
> propertize-function?

The two are unrelated: syntax-propertize-function replaces
font-lock-syntactic-keywords whereas font-lock-add-keywords affects
font-lock-keywords.
The benefit of syntax-propertize-function is that it's independent on
font-lock, so it makes the benefits of font-lock-syntactic-keywords
available even when font-lock is disabled or hasn't touched that
corresponding part of the buffer (e.g. because you have not disabled
jit-lock and haven't displayed this part of the buffer yet).
One example is to use Emacs's indent-region in batch mode to
auto-reindent a bunch of files.


        Stefan


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

end of thread, other threads:[~2010-09-13 21:16 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-09-13 10:43 Changes to syntax at fontification Nordlöw
2010-09-13 10:44 ` Nordlöw
2010-09-13 21:16 ` Stefan Monnier

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).