godotengine / godot-vscode-plugin

Godot development tools for VSCode
MIT License
1.59k stars 170 forks source link

Fixed the textmate grammar erroneously tagging enum members and const variables as language constants #737

Closed miss-programgamer closed 1 month ago

miss-programgamer commented 1 month ago

The title says all. Related to Issue #735.

DaelonSuzuka commented 1 month ago

What exactly is the difference between variable.other.constant.gdscript and constant.language.gdscript? Are they actually highlighted differently?

miss-programgamer commented 1 month ago

What exactly is the difference between variable.other.constant.gdscript and constant.language.gdscript? Are they actually highlighted differently?

Yes, using the default vscode colors as a frame of reference, language constants are colored with the same dark blue as other keywords, whereas user constants are colored in a lighter electric blue.

Before my changes: image

After my changes: image

This is standard in several other languages grammars, like for instance C++ and Python.