> [The discussion is about a font-locking problem reported in CC Mode: The
> user types the start of a C function, but puts a NL in the middle:
> void function
> (int x);
> The second line gets incorrectly fontified, because in its
> after-change-functions, font-lock considers only that line in and of
> itself.]
[...]
> However: I did complain about this shortcoming of font-lock on
> gnu.emacs.bug way back, on Friday 10th May 2002 (Subject: Font-lock:
> Major mode should be able to specify region to fontify. Message-Id:
> <[EMAIL PROTECTED]>), and that post of mine contained a patch to add
> the facility to font-lock. Nobody apart from Kim Storm (who objected
> (quite reasonably) to the prolix function names I'd used) responded to
> the post at the time, and nothing happened. That's when I decided that
> advising font-lock was the least bad way of solving the problem.
Hmm... I can't remember such a post and I have a hard time imagining why
I wouldn't have jumped on it.
Could you explain smoe more about your two cases (the one in awk and the
one in the subject of this article):
- how do they use your new before-font-lock-after-change-function hook?
- why can't they use the font-lock-multiline property?
- why can't they use the jit-lock-defer-multiline property?
This will allow us the better judge which is the better course of action.
Using advice on font-lock functions from awk-mode is pretty ugly, so it's
important we come up with a better way to solve this issue.
Stefan
_______________________________________________
Emacs-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/emacs-devel