From d2ab1c4a9af205bbeeaf5a0b6333797c18e43f86 Mon Sep 17 00:00:00 2001 From: Yuan Fu Date: Tue, 22 Nov 2022 18:47:47 -0800 Subject: Tweak python-ts-mode fontification (bug#59470) * lisp/progmodes/python.el (python--treesit-settings): Only fontify the @ and the identifier of a decorator, not the argument list (if there is any). --- lisp/progmodes/python.el | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'lisp/progmodes/python.el') diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index af59b8e1467..3a919c8cf20 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el @@ -1113,7 +1113,9 @@ fontified." :feature 'decorator :language 'python - '((decorator) @font-lock-type-face) + '((decorator "@" @font-lock-type-face) + (decorator (call function: (identifier) @font-lock-type-face)) + (decorator (identifier) @font-lock-type-face)) :feature 'type :language 'python -- cgit v1.2.3