heex-ts-mode icon indicating copy to clipboard operation
heex-ts-mode copied to clipboard

Update font-lock to improve look-and-feel

Open ed7ed opened this issue 1 year ago • 1 comments

Hello @wkirschbaum , hope you are doing well. I came up with an opinionated change to improve optical perception and visual improvement in general of a color scheme I use (it is doom-theme one-light, but it seems the issue with other themes as well). The color palettes seems has almost the same shade of violet, which is a little bit annoying:

Screenshot from 2024-09-16 11-51-59

If a patch will be applied it will look like:

Screenshot from 2024-09-16 11-53-15

Thank you, Illia

ed7ed avatar Sep 16 '24 11:09 ed7ed

Hi @illia-danko.

Yes I can see that being a problem. I will have a look a bit later to see how it matches up with the other html derived modes.

wkirschbaum avatar Sep 16 '24 11:09 wkirschbaum

@illia-danko I had a look and the change brings in some inconsistencies with attributes values and tag contents. I will tinker a bit and propose and update. It is nice seeing the attributes more clearly.

It might also be necessary to add further changes to a new feature level ( perhaps 3 ), as the standard level should not light up the buffer too much.

Give me a day or two then you can confirm if it works for you.

Bear in mind that the heex-ts--font-lock-settings is a defvar and can be modified in your init.el file quite easily.

wkirschbaum avatar Dec 28 '24 08:12 wkirschbaum

@illia-danko the only change which makes sense to be is the one on line 113 from constant to string. I had a look at html-ts-mode and heex-ts-mode's font-lock rules are pretty much the same otherwise.

I would rather that we are consistent with other modes than perfect for a specific mode. You can either update the mode font-lock settings or update the theme you are using.

Closing this for now, but will submit a change for the string -> constant font-lock.

wkirschbaum avatar Dec 30 '24 09:12 wkirschbaum