Check out the live demo!
The framework comes with two code generators which take the grammars expressed with Xtext or ANTLR and generate two variants of editors.
- Generate Web Editor from Xtext produces a plugin to be packaged with the original Xtext plugin into a workbench application enabling precise interaction between the client and the server.
Below the complete list of features bound by default in the generated editors.
- Syntax highlighting,
- Syntax validation,
- Content assist,
- Sever-side semantic validation,
- Template proposals,
- Text hovering,
- Default Key bindings,
- Undo/Redo Support,
- Code Folding,
- Brace Matching.
- The following use case is a petrinet form made up of an embedded textual editor integrated with D3.js framework. The form is available in the live demo, open the petrinet project folder, right click on a petrinet model file, and select "Open with form editor".
- The following use case is an online coding game made with DSL Forge. It comes with a domain-specific language for specifying the actions of a robot, a remote debugger, next to a canvas animation made with Phaser.js. The game is free and publicly available on CodingPark.
- The following example is an ANTLR v4 web editor embedded in the live demo, it demonstrates the integration of the editor with guiders based on the Guiders.js framework.
- Install Eclipse The current DSL Forge Tooling is based on Eclipse Neon packages. To know which package is the most appropriate for you, select one of the following alternatives.
Eclipse IDE for Java EE Developers You want a static web project with a full integration of ANTLR v3 (v4 is following) and ACE that you can easily debug in the browser. The recommended package in this case is Eclipse IDE for Java EE Developers as it comes with a simple HTTP Preview server easy to debug. The generator outputs the language mode and worker, and does the integration with the lexer/parser generated by ANTLR in the worker script. Once you update the grammar specification file, the parser/lexer are regenerated automatically on save, the language mode/worker are regenerated from contextual menu.
Eclipse for RCP and RAP Developers You want a closer integration with Eclipse Modeling tools such as Xtext and EMF, trigger code generation, do live compilation and execute some generated artefacts, you’d better install Eclipse for RCP and RAP Developers. The tooling comes with a set of runtime plugins that will make the integration of your tool chains (e.g. transformations written in Xtend, Xpand, and Java) very easy. The editor is generated together with a target platform and a build script. The target platform is a super set of the Basic Equinox Target, it contains runtime plugins providing services such as workspace management, persistency, etc. The build script outputs a war bundle that you can deploy either in OSGI environments (Jetty) or JEE environments (Tomcat).
- Install DSL Forge Tooling Use the regular update site.
The two usage scenarios are documented on the website.
Generate Web Editor from Xtext
- Step 1 - Generate Web Editor from Xtext
- Step 2 - Set up Debug Configuration and Test Editor
- Step 3 - Build Web Application Archive
- Step 4 - Deploy Web Archive on Servlet Container
Generate Web Editor from ANTLR
Additional usage informationn and technical details can be found below:
If you still need help, please open an issue we'll try to help as much as possible in a reasonable time.
If you need professional support, drop an email to firstname.lastname@example.org.
We actively encourage and support contributions! DSL Forge is open source, feel free to fork the repository and enhance the tool the way you want.
DSL Forge program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which is available at http://www.eclipse.org/legal/epl-v10.html