-
Notifications
You must be signed in to change notification settings - Fork 10
Description
tolk-vm wrote there:
I fine-tuned grammar and palette the way I prefer it (for example, structures and variables have different colors, because of the capital letter). The current VS Code tmLanguage file is not suitable for this — it must be updated.
Currently, colors are a bit mangled, you can see it in the preview of this PR. In addition to the notes above, we should also remove or override the colors of regular identifiers and focus on built-in types and capitalized identifiers. Plus, it's easy to colorize function identifiers well since they are always followed by optional spaces and a required ( — both in definition and at the call site.
IIRC, TextMate grammars use a "first-win" strategy: only the first matching pattern is used, with no overrides later. See the Tact's grammar, where comments or strings are captured first, while regular identifiers are captured very last.
Changes would be beneficial both for users of the VSCode extension and the documentation users, since docs support TextMate-based highlighting with Shiki.