>> Note that jit-lock is supposed to be a generic framework used by packages
>> such as font-lock (and glasses-mode). So adding font-lock specific code to
>> it is ugly.
> `jit-lock-after-change' already contains that (pretty useless) check for
> `font-lock-multiline'.
Indeed, and I think it was a mistake. But I don't always get to decide.
>> Let's say you have already fontified the whole buffer,
>> and the following things happen:
>> - someone modifies text between positions 50 and 60.
> An after-change-hook would have set `font-lock-syntactically-fontified'
> to something <= 50 here ...
Yes, my patch is not the only workable approach. I wanted to avoid adding
an after-change-function. But admittedly, the right solution (the one
we'll use when we move syntactic-keywords to syntax.el) is basically the one
you describe.
> By the way, wouldn't it make sense to define `syntax-begin-function' for
> perl-mode? Something like a "well-formed" `sub' starting in column zero
> - ignoring any syntax-table properties. I believe it would be less
> costly to run both `font-lock-fontify-syntactic-keywords-region' and
> `font-lock-fontify-syntactically-region' from such a position.
Yes. I haven't spent much/any time on trying to make perl-mode
fontification fast.
Stefan
_______________________________________________
Emacs-pretest-bug mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug