views:

284

answers:

2

I am creating an application which will allow a developer to create a program flow-chart by selecting pre-defined functions from a ToolBox (which will show up as small graphical elements). In other words, developer will select one or more pre-defined functions (graphical elements) from ToolBox and drag-drop on the main work area. The application will then, based on the flow of functions selected, will auto-generate ready-to-compile-code.

I looked a GraphViz, but am not sure whether it can be used to create a GUI IDE for editing graphical elements. I am looking for a functionality similart to Microsoft Visio, where users can add/remove/drag-drop/ various shapes to create a diagram.

Does GraphViz fit in here? If yes, can you direct me to some examples showing how to do it? If GraphViz cannot be used, what are the other open source/free components available?

I am intending to build the final application in .Net.

A: 

Yes, graphviz is definitely usable for this. It comes with cairo bindings that allow easy integration in GUI's. You could also go more bare-bones along the lines of dotty or lefty, simple wrappers which come with graphviz.

honk
What are cairo bindings?
macleojw
Hi,I looked around for Cairo and it says it is a graphics rendering engine. We can use various languages (through bindings) to create various shapes. Can you make me understand how will this fit with GraphViz? How does DOT language of Graphviz and Cario work together?Does Graphviz use Cairo internally to display DOT language code as diagrams? Do I need to parse (I do not think so) DOT code and call appropriate Cairo API to create final diagram?I am sorry for so many questions, but it's very important for me to undestand how all these fit together.Thank you so much for your help!-Devang
A: 

While Graphviz could be used for such an interactive graphing environment, I'm not sure it would be the best tool for it. The strength of Graphviz in my opinion is to fairly easily visualize various forms of existing data into graphical form.

If you plan to have your GUI in a browser, then I would recommend either Raphael or Jit. Both are javascript based and more readily give you control. Raphael is good if you want to give the user total control over how things are laid out (example). The JIT is good if you want to add and remove nodes, but have the framework do the layout for you (example).

Mark
Thanks Mark for the pointers. But I am looking for something that suits desktop application. Do you know of any such lib/modules that can be used for .Net/Java desktop applications?