TextMate grammars are a very popular format to process (tokenize) code files. They can be used in order to provide some basic edition features (such as checking conformance to grammar and report error, get some basic code completion according to grammar, but there are mostly known for being a very powerful way to implement syntax highlighting on code files.
TextMate grammars already exists for almost all programming languages, and many tools simply reuse them to provide very rich syntax highlighting.
The scope of the Eclipse TM4E project is to provide a TextMate grammar processor as a Java API, and to leverage this API in the Eclipse IDE to provide syntax highlighting in Eclipse IDE editors simply by referencing a TextMate grammar.
The project distributes a “gallery” of TextMate grammars as plugins available for easy installation and consumption into Eclipse IDE.
The project doesn’t aim at hosting directly the development of TextMate grammars. Those TextMate grammars are so far considered to be external artifacts, that the project might repackage.
The project includes the necessary code to easily set up syntax highlighting for a wide diversity of languages in the Eclipse IDE, but reusing TextMate grammars.
The default integration is to provide features into the Platform's Generic and Extensible editor, but some code may be used as API to let integration be done with other Eclipse-based editors.
A piece of the project would be a plain Java (non Eclipse IDE specific) API to easily manipulate TextMate grammars. This API will be used by the Eclipse IDE integration, but might be useful in some other plain Java use-cases. Hence, although it’s not the main goal, some care will be taken in order to keep this part independent of Eclipse IDE and working in a Java environment.
This project targets mostly the Eclipse IDE. It is likely to provide a lot of value to easily add support for new languages into the Eclipse IDE. The Eclipse IDE -extenders and users- can take a big advantage of such integration.
On the other hand, the project would benefit from being inside the Eclipse.org community by attracting more experienced Eclipse developers who're already contributing to some related projects.
The project code currently depends on 2 libraries that will need CQs:
A part of the code has been written as a “transcription” of some code present in VSCode (copyrighted by Microsoft Corporation, licensed under MIT license) from TypeScript to Java. Such pieces of code are clearly identified in their copyright header.
To bootstrap good practices, the project will attempt a first incubation release as soon as it is provisioned at Eclipse.org and the CQs for the dependencies are approved.
Then the target is to have multiple incubation releases, about once a month if there have been changes, to include improvements, bugfixes and new features.
Then, if some other Eclipse IDE projects need it and if the quality is sufficient, the Eclipse TextMate project would be released as 1.0.0 as part of the Oxygen release train. If no other project do require a release of Eclipse TextMate, the development will continue as incubating, until some other project states graduating to 1.0.0 would be helpful.
The following possible areas of work are identified:
- Continuous optimization: As the syntax highlighting is a recurring operations and as user expect very fast reactivity, optimization of the code will be a continuous concern and effort for the project
- Registry of grammars: both extenders and users need to be offered a way to register a new TextMate grammar in the Eclipse IDE to immediately take advantage of it. This will require addition of some extension points and preferences.