= ProMoT Development Topic: Graphical Model Editor for ProMoT with SVG storage = (by [mailto:mginkel@mpi-magdeburg.mpg.de Martin Ginkel]) == Intro == Since 1998 ProMoT has a graphical editor made in [http://java.sun.com Java], since 2000 we are using [http://gef.tigris.org Graph Editing Framework (GEF)]. The graphical attributes are stored directly as attributes of the mathematical model, Symbols for modeling entities are stored as GIF-Images (Raster-Format). There are several inconvenient effects of the current architecture: * It is difficult to extend the graphical attributes, because for every new thing a new storage syntax has to be invented in the MDL. MDL and Lisp have nothing to do with Graphics and these attributes just clutter the source code. * All graphics must be tied to modeling elements. This means additional graphics as explanation, legend or label are not allowed. * GIF-icons are a old-fashioned solution. They are not scalable, they are distributed as separate files, leading to problems when sending a model with icons to Coworkers. The Visual Explorer can use them in the zooming interface (ZUI) but with the bad side-effects of a zoomed-in raster graphics. == Proposal == As a new proposal it would be good to use SVG as storage for the graphics and just couple the graph-like model of the mathematical system (modules, terminals and links) to graphical elements of the diagram. All information about the layout and the graphical attributes are created and edited in the Java-GUI and stored to an SVG-fragment. This fragment is stored in a separate section of the source-code and referenced by the `define-module` and `define-terminal` commands. Icons for module-instances in other model-classes are also created as SVG which can be by default a scaled version of the original view (automatic solution), but can also be reduced with a SVG-graphics editor (manual solution). There are SVG-libraries available to allow rendering of graphics in Java, [http://xmlgraphics.apache.org/batik/ Batik]. This would allow to integrate any graphics into Java-GUIs. There is a SVG-Editor freely available, [http://glipssvgeditor.sourceforge.net/ GLIPS] which could be used to edit graphics and specify graphical attributes. But this editor has no Graph-editing capabilities. There are graph-editors like [http://www.jgraph.com JGraph] that allow editing of graphs, but are much smaller as GEF and allow easy integration of other Swing or Java2D Components into the editor. It could be also a good idea to use just ONE toolkit for the Visual Editor and the Visual Explorer, but in this case it must be possible to have a good graph-editor in [http://www.cs.umd.edu/hcil/jazz/ Piccolo]/[http://csbi.sourceforge.net/ GINY]. Software which uses Piccolo as a zooming library have to build up its own graph editor. Some tools are listed below (all of them do not use GINY): * [http://www.cs.umd.edu/hcil/spacetree/ Spacetree], Novel node-link tree browser, Java 1.4+, free for non-commercial use * [http://www.thechiselgroup.org/shrimp SHriMP], Simple Hierarchical Multi-Perspective, no editor, Java 1.x, ? * [http://www.simbrain.net/ Simbrain], Building, running, and analyzing neural-networks, simple editor, Java 1.5+, ? * [http://www.rimey.com/ray/projects.html#anlan Anlan], Analytic Landscape tool, Java 1.x, ? * [http://www.kerika.com/ Kerika], Sharing documents, ideas and projects within distributed teams, simple editor, Java 1.x, commercial * [http://graphexploration.cond.org/ Guess], Visualizing Zoomable Data Driven Graphs, simple editor, Java 1.4+, GPL Another library which enables ZUI is [http://zvtm.sourceforge.net/ ZVTM (ZGRViewer)]. It computes an SVG file containing a graphical representation of the graph from the GraphViz's DOT representation. Then the generated SVG file is parsed by the ZVTM's SVG import module and displayed to the user. GEF should be dropped because it reimplements lots of things that are available in Java-2D.