EMF Forms 1.4.0 Feature #4: Enhanced Renderers

October 8, 2014 | 2 min Read

In this blog series, I describe the five most notable new features of EMF Forms 1.4.0. EMF Forms is a framework to efficiently develop form-based UIs based on a given data model. Please refer to this tutorial for an introduction to EMF Forms and to this post for an overview of the series.

As notable feature number four in EMF Forms 1.4.0, I pick the enhanced default renderers. There are some new options within the view model to control the way certain elements are rendered. For example, there are three different types of groups now. A group is a very flexible element in the EMF Forms view model, and implies that the contained elements belong together. Therefore, it leaves the decision to the renderer as to how a group is actually displayed within the form-based UI. This enables you to evolve the UI simply by adapting the renderer.

In 1.4.0, you can chose three different group types, “Normal”, “Collapsible” and “Embedded”. The default renderer will render these group types as shown in the following screenshot, however, a custom renderer could interpret the group type differently. Click here for more details about groups.

The table control has been extended by a new option called “Detailed editing”, which is also interpreted by the default renderer. It allows you to specify in detail how entries in a table are to be edited:

  • None: In place editing in the table

  • WithDialog: A button opens a dialog, which allows you to edit a table entry

  • With Panel: A detailed area underneath the table shows the properties of the currently selected element and allows you to edit it

See here for more details about tables.

Finally, we replaced one of the default renderers completely: the multi-reference control renderer. In the past, multi-references were displayed as a list of hyperlinks. The widget did not allow you to sort, it did not scale well and most of our users replaced it with a table anyway. Therefore, the new default for multi-references is now a table-based widget. The old reference widget can still be used.  To use the old widget,  make sure to exclude the bundle “org.eclipse.emf.ecp.view.control.multireference” from your product, which contains the new reference widget.

Jonas Helming

Jonas Helming

Jonas Helming is co-lead for the EclipseSource team and the project lead of the Eclipse EMF Client Platform and the EMFStore project. He works as an Eclipse Consultant …