|
From: | Stefan Monnier |
Subject: | Re: address@hidden: C++-mode: Syntax highlighting: wrong color for function identifier depending on the kind of whitespace that follows] |
Date: | Fri, 17 Feb 2006 09:36:35 -0500 |
User-agent: | Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) |
>> Maybe what will cut it is: using some kind of after/before-change-function >> (which doesn't have to be in font-lock-after-change-function) detect when >> a terminator is added/removed and in that case add a font-lock-multiline >> property on the whole element (which will cause the whole element to be >> (re)fontified not matter what jit-lock thinks, but the whole-element >> fontification will only happen this one time since the font-lock-multiline >> property is removed afterwards). > Text within "<<" ... ">>" would have to keep its multiline property > forever. The above way said in the context of: > Now let's say you have a multiline element which your font-lock-keyword is > somehow able to (re)highlight line-by-line, then you indeed don't need to > extend the region in font-lock-fontify-region. So the answer to: > Who'd be responsible for highlighting "baz" specially? is font-lock-keywords. See the "recent" change to smerge-mode's font-lock-keywords for an example. Stefan
[Prev in Thread] | Current Thread | [Next in Thread] |