Subject: Re: bug#59660: lisp/progmodes/typescript-ts-mode.el: restore method-name fontification

From: Jostein Kjønigsen <[email-masked]>
Date: Mon, 28 Nov 2022 17:44:14 +0100

This additional patch further improves fontification by fontifying 
function-arguments as variables too.

--

Kind regards
*Jostein Kjønigsen*

[email-masked] 🍵 [email-masked]
https://jostein.kjønigsen.no <https://jostein.kjønigsen.no>
On 28.11.2022 16:09, Jostein Kjønigsen wrote:
>
> Attached is a simple patch which addresses this font-lock issue and 
> makes typescript-ts-mode much better to use.
>
> -- 
> Kind regards
> *Jostein Kjønigsen*
>
> [email-masked] 🍵 [email-masked]
> https://jostein.kjønigsen.no <https://jostein.kjønigsen.no>

From b1066f1d36eaba7e4c15d1629e08254979e37c62 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jostein=20Kj=C3=B8nigsen?= <[email-masked]>
Date: Mon, 28 Nov 2022 17:43:01 +0100
Subject: [PATCH 5/5] lisp/progmodes/typescript-ts-mode.el: Fontify
 function-arguments as variables.

---
 lisp/progmodes/typescript-ts-mode.el | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/lisp/progmodes/typescript-ts-mode.el b/lisp/progmodes/typescript-ts-mode.el
index 3a392bb8d5f..bb00d873161 100644
--- a/lisp/progmodes/typescript-ts-mode.el
+++ b/lisp/progmodes/typescript-ts-mode.el
@@ -150,6 +150,8 @@ typescript-ts-mode--font-lock-settings
 
      (method_definition
       name: (property_identifier) @font-lock-function-name-face)
+     (required_parameter (identifier) @font-lock-variable-name-face)
+     (optional_parameter (identifier) @font-lock-variable-name-face)
 
      (variable_declarator
       name: (identifier) @font-lock-variable-name-face)
-- 
2.37.2