interpretation of visual notations in the recopla editor generator · 2011. 12. 6. · vast number...

1
Interpretation of Visual Notations In the Recopla Editor Generator Bernd Meyer [email protected] Hubert Zweckstetter hsz©fast.de Ludwig-Maximilians Universitiit, Insitut fur Informatik Oettingenstr. 67, D-80538 Munchen, Germany Even in application domains where diagrammatic notations are a natural element of discourse and their meaning is well-understood, their usage in the human- computer interface is still very limited. Mainly this is because of the difficulties encountered when imple- menting a diagrammatic interface. Despite the fact that a number of editor generators or compilers are available, only a handful of research prototypes sup- port the high-level specification of syntax and inter- pretation of diagrams. These issues in the context of incremental interactive systems are addressed by the RecopJa editor generator that we are demonstrating. Recopla is a Java-based editor generator used to construct interactive graphical front-ends (so-called Recopla instances) that are specialized for particular types of diagrams, like e.g. an editor for electronic cir- cuit diagrams. Recopla lets the user specify appear- ance, syntax and semantics of a diagram language and compiles this into a Java implementation of an interac- tive editor for this particular notation which is capable of automatically interpreting the user's input. .\. vast number of diagrammatic notations used in practice essentially have a (hierarchical) graph as their underlying backbone structure. The Recopla environ- ment is therefore Jesigned to offer special support for the definition of and interaction with graph structures. However, the system also supports editing and inter- pretation of other diagrammatic notations. The appearance of the graphical entities, i.e. the vocabulary, that may be used by an editor instance is specified interactively on the meta-level by draw- ing prototype entities with a normal object-oriented graphics editor . The syntax, i.e. the permissible ways to arrange these graphical entities spatially and topo- logically in a valid diagram, is specified by conditional relational grammars, a multidimensional grammar for- malism that inherits from both relational grammars and constraint multiset grammars (Marriott, Meyer, & Wittenburg 1998). The interpretation and transla- tion of diagrams is specified in the same formalism by using attributed productions and/or by attaching ac- tions to productions. The following production is an example taken from a simple grammar for state tran- sition diagrams: -1 07 - Transi tion --> Arrow, Label ; '!. where exists(State_1, State_2), '!. such that starts_atCState_1, Arrow), ends_at(State_2, Arrow), close_to (Label, Arrow); '!. and set Transition.condition = Label.string, Transition.from = State_1.name, Transition.to = State_2.name. The formalism allows the usage of context-sensitive productions and of arbitrary user-defined predicates that are evaluated as conditions over the objects' at- tributes. Such a grammar is processed in bottom-up fashion by simultaneously rewriting a set of graphical objects and a set of spatial relations between these ob- jects. In interactive systems it is desirable to support im- mediate feedback from the interpretation without re- stricting the admissible user-interactions. For systems working on the basis of a formal synta.-x definition this is a difficult problem since for this they have to address the issue of incremental parsing and, more importantly, of non-monotonic incremental interpretation. In Recopla's interpretation component this is solved by viewing parsing as logical deduction: The grammar execution can essentially be understood as a bottom-up derivation of horn-clauses with set-valued attributes. This perspective allows us to employ deduction tech- niques developed in the area of Truth Maintenance Systems by which a consistent interpretation can incre- mentally be maintained when the diagram is changing without having to initiate a complete reinterpretation from scratch. The demonstration will show some editors built with Recopla as well as the process of constructing a new editor. Acknow ledgments The authors would like to thank Luis Mandel and Zoltan Gassmann who have designed and implemented the original Recopla environment on top of which we have built the interpretation component. References Marriott, K.; Meyer, B.; and Wittenburg, K. 1998. A survey of visual language specification and recog- nition. In Marriott, K., and Meyer, B., eds., Visual Language Theory. New York: Springer-Verlag. From AAAI Technical Report FS-98-04. Compilation copyright © 1998, AAAI. (www.aaai.org). All rights reserved.

Upload: others

Post on 01-Apr-2021

1 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Interpretation of Visual Notations In the Recopla Editor Generator · 2011. 12. 6. · vast number of diagrammatic notations used in practice essentially have a (hierarchical) graph

Interpretation of Visual Notations In the Recopla Editor Generator

Bernd Meyer [email protected]

Hubert Zweckstetter hsz©fast.de

Ludwig-Maximilians Universitiit, Insitut fur Informatik Oettingenstr. 67, D-80538 Munchen, Germany

Even in application domains where diagrammatic notations are a natural element of discourse and their meaning is well-understood, their usage in the human­computer interface is still very limited. Mainly this is because of the difficulties encountered when imple­menting a diagrammatic interface. Despite the fact that a number of editor generators or compilers are available, only a handful of research prototypes sup­port the high-level specification of syntax and inter­pretation of diagrams. These issues in the context of incremental interactive systems are addressed by the RecopJa editor generator that we are demonstrating.

Recopla is a Java-based editor generator used to construct interactive graphical front-ends (so-called Recopla instances) that are specialized for particular types of diagrams, like e.g. an editor for electronic cir­cuit diagrams. Recopla lets the user specify appear­ance, syntax and semantics of a diagram language and compiles this into a Java implementation of an interac­tive editor for this particular notation which is capable of automatically interpreting the user's input.

.\. vast number of diagrammatic notations used in practice essentially have a (hierarchical) graph as their underlying backbone structure. The Recopla environ­ment is therefore Jesigned to offer special support for the definition of and interaction with graph structures. However, the system also supports editing and inter­pretation of other diagrammatic notations.

The appearance of the graphical entities, i.e. the vocabulary, that may be used by an editor instance is specified interactively on the meta-level by draw­ing prototype entities with a normal object-oriented graphics editor . The syntax, i.e. the permissible ways to arrange these graphical entities spatially and topo­logically in a valid diagram, is specified by conditional relational grammars, a multidimensional grammar for­malism that inherits from both relational grammars and constraint multiset grammars (Marriott, Meyer, & Wittenburg 1998). The interpretation and transla­tion of diagrams is specified in the same formalism by using attributed productions and/or by attaching ac­tions to productions. The following production is an example taken from a simple grammar for state tran­sition diagrams:

-1 07 -

Transi tion --> Arrow, Label ; '!. where exists(State_1, State_2), '!. such that starts_atCState_1, Arrow), ends_at(State_2, Arrow), close_to (Label, Arrow); '!. and set

Transition.condition = Label.string, Transition.from = State_1.name, Transition.to = State_2.name.

The formalism allows the usage of context-sensitive productions and of arbitrary user-defined predicates that are evaluated as conditions over the objects' at­tributes. Such a grammar is processed in bottom-up fashion by simultaneously rewriting a set of graphical objects and a set of spatial relations between these ob­jects.

In interactive systems it is desirable to support im­mediate feedback from the interpretation without re­stricting the admissible user-interactions. For systems working on the basis of a formal synta.-x definition this is a difficult problem since for this they have to address the issue of incremental parsing and, more importantly, of non-monotonic incremental interpretation.

In Recopla's interpretation component this is solved by viewing parsing as logical deduction: The grammar execution can essentially be understood as a bottom-up derivation of horn-clauses with set-valued attributes. This perspective allows us to employ deduction tech­niques developed in the area of Truth Maintenance Systems by which a consistent interpretation can incre­mentally be maintained when the diagram is changing without having to initiate a complete reinterpretation from scratch.

The demonstration will show some editors built with Recopla as well as the process of constructing a new editor.

Acknow ledgments The authors would like to thank Luis Mandel and Zoltan Gassmann who have designed and implemented the original Recopla environment on top of which we have built the interpretation component.

References Marriott, K.; Meyer, B.; and Wittenburg, K. 1998. A survey of visual language specification and recog­nition. In Marriott, K., and Meyer, B., eds., Visual Language Theory. New York: Springer-Verlag.

From AAAI Technical Report FS-98-04. Compilation copyright © 1998, AAAI. (www.aaai.org). All rights reserved.