emacs-devel
[Top][All Lists]
Advanced

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

Re: address@hidden: C++-mode: Syntax highlighting: wrong color for funct


From: Ralf Angeli
Subject: Re: address@hidden: C++-mode: Syntax highlighting: wrong color for function identifier depending on the kind of whitespace that follows]
Date: Thu, 16 Feb 2006 12:54:37 +0100

* Alan Mackenzie (2006-02-16) writes:

> Hi, Ralf!
>
> On Wed, 5 Feb 2006, Ralf Angeli wrote:
>
>>This is all well and good, but in contrast to the after-change hook, a
>>hook in `font-lock-default-fontify-region' could not only adjust the
>>region after a change but also during fontification by chunks as done
>>by jit-lock.  (That's an advantage I haven't noticed before.)
>
> That is horrible.  f-l-d-f-r currently fontifies the region requested by
> the caller, not a different region that Font Lock finds more convenient.

As Stefan already pointed out this is not the case because the region
may be extended if `font-lock-multiline' is activated.

> If we change its functionality, something somewhere will surely break.
>
>>Following your reasoning of separating the determination of the region
>>to be fontified from the fontification itself would require that
>>jit-lock determines the chunks to be fontified more intelligently.
>
> I don't follow that.  There are several different ways that jit-lock
> determines its chunks.  There's after-change, after-scrolling, stealth,
> at least.  I don't see why determining a jit-lock after-change region
> need have anything to do with determining an after-scrolling or stealth
> region.

I was referring to stealth fontification during which jit-lock
fontifies chunks of the size determined by `jit-lock-chunk-size' one
after another.  If the start of one of those chunks is located inside
of a "<<...>>" construct an after-change hook will not let me extend
the region backwards to the starting tag in that case because there
hasn't happened a change.

-- 
Ralf




reply via email to

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