Modelling languages are essential in many disciplines to express knowledge in a precise way. Furthermore, some domains require families of notations (rather than individual languages) that account for variations of a language. Some examples of language families include those to define automata, Petri nets, process models or software architectures. Several techniques have been proposed to engineer families of languages, but they often neglect the language’s concrete syntax, especially if it is graphical.
To fill this gap, we propose a modular method to build product lines of graphical modelling languages. Language features are defined in modules, which comprise both the abstract and graphical concrete syntax of the feature. A language variant is selected by choosing a valid configuration of modules, from which the abstract and concrete syntax of the variant is synthesised. Our approach permits composition and overriding of graphical elements (e.g., symbol styles, visualisation layers), the injection of pre-defined graphical styles into language families (e.g., to obtain a high-intensity contrast variant for accessibility), and the analysis of graphical conflicts at the product line level.We report on an implementation atop Eclipse/Sirius, and demonstrate its benefits by an evaluation which shows a substantial specification size reduction of our product line method with respect to a case-by-case specification approach.