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

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

bug#67809: closed ([PATCH] Add font-locking for assignments in typescrip


From: GNU bug Tracking System
Subject: bug#67809: closed ([PATCH] Add font-locking for assignments in typescript-ts-mode)
Date: Sat, 23 Dec 2023 20:58:02 +0000

Your message dated Sat, 23 Dec 2023 22:57:17 +0200
with message-id <a6edbc57-2c74-4392-92ca-1604277807c8@gutov.dev>
and subject line Re: bug#67809: [PATCH] Add font-locking for assignments in 
typescript-ts-mode
has caused the debbugs.gnu.org bug report #67809,
regarding [PATCH] Add font-locking for assignments in typescript-ts-mode
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs@gnu.org.)


-- 
67809: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=67809
GNU Bug Tracking System
Contact help-debbugs@gnu.org with problems
--- Begin Message --- Subject: [PATCH] Add font-locking for assignments in typescript-ts-mode Date: Wed, 13 Dec 2023 00:33:16 -0800
Tags: patch


This patch adds fontification for the left-hand side of assignments in
typescript-ts-mode.

The object and/or property being assigned to is fontified with
`font-lock-variable-name-face` and/or `font-lock-property-name-face`,
while any other identifiers/properties on the left-hand side used in
index expressions are fontified with
`font-lock-variable-use-face`/`font-lock-property-use-face`.

For example, fontification is added in `typescript-ts-mode` for
identifiers in statements like the following:

    arr[obj.x * obj.x] = 1;
    //^ font-lock-variable-name-face
    //    ^ font-lock-variable-use-face
    //      ^ font-lock-property-use-face
    obj.x.y = 0;
    //^ font-lock-variable-name-face
    //  ^ font-lock-property-name-face
    //    ^ font-lock-property-name-face
    ++mat[x][arr[0]];
    // ^ font-lock-variable-name-face
    //        ^ font-lock-variable-use-face

In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version
3.24.33, cairo version 1.16.0) of 2023-12-12 built on noah-X580VD
Repository revision: 75fd7550ed6cede6c9e8224f1f2d62637c43fdd4
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12101004
System Description: Ubuntu 22.04.3 LTS

Configured using:
 'configure --prefix=/usr/local --with-modules --with-tree-sitter
--with-threads --with-x-toolkit=gtk3 --with-xwidgets --with-gnutls
--with-json --with-mailutils --with-jpeg --with-png --with-rsvg
--with-tiff --with-xml2 --with-xpm --with-imagemagick CC=gcc-12
CXX=gcc-12'

Attachment: typescript-ts-fontify-assignments.patch
Description: Text Data


--- End Message ---
--- Begin Message --- Subject: Re: bug#67809: [PATCH] Add font-locking for assignments in typescript-ts-mode Date: Sat, 23 Dec 2023 22:57:17 +0200 User-agent: Mozilla Thunderbird
On 23/12/2023 13:21, Eli Zaretskii wrote:
From: Noah Peart<noah.v.peart@gmail.com>
Date: Sat, 23 Dec 2023 05:39:17 -0500
Cc: Dmitry Gutov<dmitry@gutov.dev>,67809@debbugs.gnu.org

I think this should be closed for now.
If Dmitry agrees, it's fine by me.

Closing. I'm sorry if this was a disappointing response.


--- End Message ---

reply via email to

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