[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: advice after fontify region with c-mode
From: |
Filippo Argiolas |
Subject: |
Re: advice after fontify region with c-mode |
Date: |
Fri, 15 Sep 2023 05:43:39 +0200 |
On Thu, Sep 14, 2023 at 10:30 PM Filippo Argiolas
<filippo.argiolas@gmail.com> wrote:
> At the moment I'm doing something like this:
> (add-function :after (local 'font-lock-fontify-region-function)
> #'my-fontify-region-function))
Apparently using local here ends up calling my function after
c-fontify-region-function while I want it to be called after default
fontify region.
This:
(add-function :after (default-value 'font-lock-fontify-region-function)
#'clangd-inactive-regions--fontify))
Seems to do the trick and my function gets properly chained to the
major mode one with the new extended region.
Still open to feedback and suggestions if anyone wants to chime in!
Filippo