Syntax Highlighter for VSCodeSyntax highlighter based on Tree-Sitter. Provides universal syntax coloring engine for almost any programming language. See list of currently supported languages below. Under the hood the extension utilizes VSCode Decoration API to override syntax coloring provided by standard TextMate regex matching. Constructing entire syntax tree, Tree-sitter efficiently overcomes all limitations of built-in TextMate grammars. Being context-aware, it's able to parse complex language structures providing complete coverage of source code. Incremental parsing system ensures high performance. All these advantages enable accurate and consistent syntax highlighting. AttentionTemporarily, extension published in VS Code Marketplace will only work in Windows-x64. This will be fixed in the near future with one of the next updates. For other operating systems, please download precompiled .vsix package from GitHub page. Languages:
CustomizationSyntax Highlighter exposes a number of settings to assign theme colors to syntax terms.
For simple and straightforward customization, we keep a number of syntax terms small,
namely: type, function, variable, string, number, comment, an some others.
They are presented under
For consistency with built-in TextMate grammars, the same colors can be provided
for corresponding TextMate scopes. Or backwards, one can port colors from TextMate
to Syntax Highlighter. In most cases there is one to one match. For example, for
C++:
DistributionDependence on native Node.js modules currently prevents us from publishing of a cross-platform
package in VS Code Marketplace. Published version is compatible only with Windows-x64.
You can download .vsix package for your OS from
GitHub repository.
To install the downloaded extension, execute BuildSyntax Highlighter extension depends on certain Tree-sitter modules. They are native Node.js modules that require a compilation for particular architecture, OS and version of Node.js. Refer to BUILD.md for instructions. ContributeThe best way to contribute is to implement support of new languages. Extension improvements are also welcome. The first thing on ToDo list is to improve distribution and packaging which are complicated by native modules. Refer to CONTRIBUTE.md for details. ToDo |