bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#68827: Possible solution


From: Stefan Monnier
Subject: bug#68827: Possible solution
Date: Thu, 15 Feb 2024 15:11:43 -0500
User-agent: Gnus/5.13 (Gnus v5.13)

> I noticed that the tex-verbatim face used in latex-mode to highlight the
> \href argument has priority on font-lock-comment-face.

I'm not sure if it should qualify as a bug or as a feature, to be honest.

> (font-lock-add-keywords nil
>  '(("\\\(ProvidesFile\|href\|nolinkurl\|path\|url\) \(\[[^]]\]
>  \){\(\(?:[^{}\]\|\\.\|{[^}]}\)+\)" 3 'tex-verbatim keep)))

Thanks.  `keep` seems right for the case where the match is inside
a comment, as in your case, but there are other cases where we want
to override the previously applied face (e.g. $math$).

I pushed a patch which re-arranges the rules to avoid that
other problem.


        Stefan






reply via email to

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