Ayende @ Rahien

Hi!
My name is Oren Eini
Founder of Hibernating Rhinos LTD and RavenDB.
You can reach me by phone or email:

ayende@ayende.com

+972 52-548-6969

, @ Q c

Posts: 6,124 | Comments: 45,475

filter by tags archive

How to visualize a Domain Specific Language

time to read 2 min | 235 words

Andrey Shchekin made a good point when he commented on my post about graphical DSL:

I do not use DSLs that are purely graphical. But talking about documentation, I think it is very useful to have a graphical _representation_ for some DSLs that is synchronized with (or generated from) the DSL itself.
For example, any workflows or dataflows (think Rhino ETL) are much easier to see at a glance on visual surface. Editing them on visual surface is also an option, but not a requirement.

I certainly am a believer that a DSL should be mostly declarative, and indeed, taking Rhino ETL as an example, it is something that can have a visual representation.

The only remaining question is how?

Long ago there was Lithium and Netron projects, which were good for building the kind of UI that a DSL is composed of. Those have gone commercial now, and while I can probably find the originals somewhere, that is not a very promising concept. There is always the Visual Studio DSL toolkit, but I have a strong suspicion that I would not like it (COM involved), and anyway, I want to do it externally to Visual Studio.

Anyone familiar with useful libraries that can make it happen? Ideally, it would allow me to generate UI similar to the class designer. It should also be simple, but I am not sure how to really quantify that.


Comments

Ken Egozi

VS2008 Shell is promising.

Bruno Alfirevic

Graphviz can be great for such things.

http://www.graphviz.org/

Ayende Rahien

Ken, do you have experience with that?

Ayende Rahien

Bruno ,

It doesn't look like it is can be used to create impressive graphs. And it is static.

That is to say, consider the class designer in VS, that is more like what I had in mind.

Ken Egozi

no.

However, it should allow for creating applications, detached from visual studio itself, that can use the IDE shell. Quite similar to the SharpDevelop component that if I recall correctly, you have used for rhino ETL.

all with a permissive license (as opposed to VS2005 SDK license), and should also be more native, less COM.

all that is from reading white-paper. I'm still waiting to get my hands on a proper 2008 RTM license.

Andrey Shchekin

I suppose Peli's QuickGraph (http://www.codeplex.com/quickgraph) can do something like this, since I've seen some cool QuickGraph samples (http://blog.dotnetwiki.org/FunWithGraphs2GettingTheILExecutionGraphUsingQuickGraphAndIlReader.aspx).

Also GLEE (http://research.microsoft.com/research/downloads/Details/c927728f-8872-4826-80ee-ecb842d10371/Details.aspx) seems interesting though I haven't used it as well.

I tried Microsoft DSLTools and while they can give you the way to define your own designer, I would stay away from them. Way too complex and suited for graphic DSL not a visualization.

A powerful solution would be to write your own visualizer in WPF (it is very powerful and has most potential with zooming or even editing the code inside the representation itself). But it could be quite time-consuming.

Andrey Shchekin

I suppose Peli's QuickGraph (http://www.codeplex.com/quickgraph) can do something like this, since I've seen some cool QuickGraph samples (http://blog.dotnetwiki.org/FunWithGraphs2GettingTheILExecutionGraphUsingQuickGraphAndIlReader.aspx).

Also GLEE (http://research.microsoft.com/research/downloads/Details/c927728f-8872-4826-80ee-ecb842d10371/Details.aspx) seems interesting though I haven't used it as well.

I tried Microsoft DSLTools and while they can give you the way to define your own designer, I would stay away from them. Way too complex and suited for graphic DSL not a visualization.

A powerful solution would be to write your own visualizer in WPF (it is very powerful and has most potential with zooming or even editing the code inside the representation itself). But it could be quite time-consuming.

el
el

Netron is still free for non-commercial. The auther is also working in a WPF version. See:

http://www.orbifold.net/default/

JasonA

Eclipse has the Graphical Editing Framework for creating rich graphical editors.

http://www.eclipse.org/gef/overview.html

Couldn't find a .Net equivalent, though, but that was a while back.

Comment preview

Comments have been closed on this topic.

FUTURE POSTS

  1. RavenDB 3.5 whirl wind tour: You want all the data, you can’t handle all the data - one day from now
  2. The design of RavenDB 4.0: Making Lucene reliable - about one day from now
  3. RavenDB 3.5 whirl wind tour: I’ll find who is taking my I/O bandwidth and they SHALL pay - 3 days from now
  4. The design of RavenDB 4.0: Physically segregating collections - 4 days from now
  5. RavenDB 3.5 Whirlwind tour: I need to be free to explore my data - 5 days from now

And 14 more posts are pending...

There are posts all the way to May 30, 2016

RECENT SERIES

  1. RavenDB 3.5 whirl wind tour (14):
    29 Apr 2016 - A large cluster goes into a bar and order N^2 drinks
  2. The design of RavenDB 4.0 (13):
    28 Apr 2016 - The implications of the blittable format
  3. Tasks for the new comer (2):
    15 Apr 2016 - Quartz.NET with RavenDB
  4. Code through the looking glass (5):
    18 Mar 2016 - And a linear search to rule them
  5. Find the bug (8):
    29 Feb 2016 - When you can't rely on your own identity
View all series

RECENT COMMENTS

Syndication

Main feed Feed Stats
Comments feed   Comments Feed Stats