- 1 Summary
- 2 Where to download Emfatic from
- 3 Screenshots
- 3.1 Outline view
- 3.2 Mark Occurrences
- 3.3 Folding
- 3.4 Problem and warning markers
- 3.5 Validation on conversion attempt
- 3.6 Outline selection follows cursor
- 3.7 Hyperlinks
- 3.8 Wizard
- 3.9 Hovers showing declaration for the element under the cursor
- 3.10 AutoEdits
- 3.11 Preference pages
- 3.12 Time-saving Templates
- 3.13 Show in EMF Type Hierarchy
- 4 Organization
Emfatic is a text editor supporting navigation, editing, and conversion of Ecore models, using a compact and human-readable syntax similar to Java (see Emfatic language reference). The EPLed Emfatic now hosted at EMFT extends the Feb 2005 alphaworks release with support for EMF Generics, folding, "red squigglies", an EMF Type Hierarchy, hyperlinks, AutoEdits, and the possibility to define templates to speed up document creation, among other usability features. The best way to gain hands-on experience with Emfatic is to right-click on any .ecore file and choose Generate Emfatic source, a similar converter works in the opposite direction. Online help is also available.
Emfatic itself builds upon Gymnast, a framework for jumpstarting text editors for custom Domain Specific Languages. Documentation on how to extend Emfatic, as well as on using Gymnast, can be found in this technical report.
Where to download Emfatic from
Emfatic can be downloaded from the eclipse repository http://download.eclipse.org/emfatic/update
The Outline view displays the same elements as the Sample Ecore Editor, toolbar actions are available for hiding/showing annotations, attributes, references, operations.
Mark Occurrences highlights usages of the same EClassifier, range indication on the vertical bar spans the EClassifier declaration.
Folding is supported, with an annotation hover for collapsed regions
Problem and warning markers
Validation on conversion attempt
Outline selection follows cursor
The selected outline node follows the cursor position in the text.
Navigable hyperlinks (from usages of classifiers and from type variables to their declarations). Hyperlinks are very handy for example to follow an eOpposite to its declaration (alternatively, letting the mouse cursor rest over an eOpposite displays its definition in a text hover, see below) Open declaration is also supported, i.e. pressing F3 (or whatever key binding is in effect for it) moves the cursor to the declaration.
A File > New > Other … wizard is available, which initializes the just created .emf file to
a syntactically correct state:
Hovers showing declaration for the element under the cursor
Hovers for usages of classifiers, type parameter variables, and eOpposite references: the definition is shown.
SmartBrace: typing an opening brace automatically adds its closing brace and leaves the cursor indented on its own line (end result shown below). Besides that strategy the usual ones:
- Closing quote for opening quote
Preference pages, to control AutoEdits and templates (see example below).
A template for each kind of annotation saves typing. In the example, the template definition for adding OCL invariants is shown (the error marker is transient, once the template is inserted it disappears).
Show in EMF Type Hierarchy
Show in EMF Type Hierarchy can be activated from the editor and from the outline view.
The supertype and subtype relationships can be followed, with a list of (inherited) class members displayed on the lower pane. Double-clicking on any of these elements navigates in the editor to its declaration.
- Miguel Garcia
- Chris Daly
Releng + Lead Interim Commiter