What's New in MPS 3.4


This release brings important changes to the editor definition languages. The new Transformation Menu Language simplifies the process of defining side-transformations and substitutions. The Context Assistant and Context Actions Tool help the users easily discover and invoke the most relevant actions in the given editor context.

Context Assistant

A new UI mechanism called Context Assistant can guide users through the process of creating code. Using mouse or keyboard the users interact with a dynamically constructed menu and pick from the most appropriate actions in the current context. Despite being embedded directly into the editor, the menu avoids distracting the user by flickering or shifting content as it shows up or disappears.

See a short video

Context Actions Tool

Not all elements of some DSLs can be conveniently represented in text-based completion or context assistant menus. Think of math symbols or diagram elements, for example. These can now be offered separately in a separate tool panel, which lists the actions applicable in the given context in a sidebar. The content of the sidebar is specified by the language designer through the new Transformation Menu Language.

See a short video

Transformation Menu Language

A newly designed Transformation menu language provides a unified way to specify side transformations, substitute menus, the Context Assistant menus as well as items for the new Context Actions Tool. Compared to the now deprecated side-transforms and substitute actions in the Actions aspect, the new approach is tied to the Editor aspect and supports re-use, explicit location, mixing with UI actions as well as multiple projections.

See a short video

Redesigned Substitute Actions

Node Substitute Actions as well as cell menus have all been replaced with new Substitute Menus. These are now defined alongside the editors and can be hooked to individual cells or editor projections.

Migrating existing editor actions

A semi-automated migration path has been provided to assist the language designers during migration of their now deprecated side-transformations and node substitutions from the Actions aspect into the new definitions stored in the Editor aspect. MPS 3.4 will continue working with the old way alongside the new one until the support for the old actions gets dropped in the next version of MPS.

Generator enhancements

The MPS generator is gradually undergoing major redesign. This release is an important milestone on our way towards explicit generation plans and cross-model generation.

Cross-model generation

DevKits now can associate a generation plan. Any model that imports that DevKit will get the DevKit's associated generation plan applied to it. In order to support this approach in the automated builds, the build language has been made aware of DevKits, as well.

See a short video

Explicit generator specification

The jetbrains.mps.lang.generator.plan language for describing the build plans got an entry to identify the applied generators explicitly, in addition to specifying the language to reduce.

Debug information in the checkpoint models

A dedicated root inside each checkpoint model now lists the mapping label names along with pointers to the stored input and output nodes. Investigation of the mapping labels exposed at each checkpoint can substantially help debugging cross-model generation scenarios and fix unresolved references.

Enhanced handling of attributes

With the growing adoption of attributes and their increasing complexity, we enabled the generator to transform the attribute contents using the regular template processing rules:

  • references to nodes in the same model get updated to point to the respective nodes in the output model
  • reduction rules are applied in order to transform children of the attribute node.

Common build infrastructure

Like most open-source projects, MPS shares publicly the sources, documentation, on-line forum as well as the bug tracker. The project accepts external contributions and allows people outside of JetBrains to gain the committer status. With this release we've also gave access to the build infrastructure.

Instant access to builds

The MPS TeamCity installation has been made accessible for the public. Anyone can now check out the builds and download their artifacts at any time. This way you can try out new features and fixes as soon as they get implemented.

Hosting for partnering open-source projects

Projects that partner with MPS may take advantage of the MPS TeamCity facilities, as well. By being hosted closely to MPS they are able to effortlessly build the project against a particular or the newest version of MPS. Your open-source project can also join the club.

Other improvements

Context Assistant for Language Definition

A set of context-assistant actions may help MPS beginners to speedup the DSL structure & editor definition process.

See a short video

Performance improvements

The startup time of MPS has been considerably shortened thanks to various improvements in how the language repository gets loaded initially into MPS. This also effects the performance of standalone IDEs built on top of MPS.

Generating icons

Icons that help users visually identify elements of your language can now be generated from a simple textual description. The icon{} and iconResource{} expressions in the Resources language convert textual description into an javax.swing.Icon or jetbrains.mps.smodel.runtime.IconResource class, respectively. Icons, both generated and loaded from a png file, can be used in any UI component, action etc.

Find usage for solutions and devkits

Solutions and DevKits can now have their usages easily discovered from the Project Pane through the Alt + F7 key shortcut. This mechanism is no longer restricted to Languages only.

Remove unused languages easily

You can remove unused Dependencies and Used Languages in the Model properties dialog with a single click. A new handy button makes it easier to keep the dependencies under control.