> I am not really sure how to use Canviz, especiall in combination with
> jQuery.
Canviz requires Prototype right now. Work is underway to make Canviz library-independent; see issue #66.
http://code.google.com/p/canviz/issues/detail?id=66
Until that's complete, you should be aware of the kinds of issues that can happen if you mix Prototype with other libraries. I'm not an expert on such matters, but the jQuery folks seem to think it should be ok, if you follow these rules:
http://docs.jquery.com/Using_jQuery_with_Other_Libraries
> For my project I need to display some .dot/.gv files which are
> dynamically created by my app.
> Do I need to pipe my .dot/.gv files through xdot to make then usable
> in Canviz?
You need to send your dot/gv files through a Graphviz layout program, such as dot, neato, circo, twopi, fdp, sddp, etc., and instruct it to produce output in xdot format (that's the "-Txdot" command line flag). Then you supply this xdot output to Canviz.
> How do I change which file is being displayed by canviz?
When you create a Canviz instance, you tell it the div you want to contain the graph, and optionally the URL of the xdot file. See the hello_world example included in the source package. For example:
var myCanviz = new Canviz('mydiv', 'mygraph.xdot');
If you want to change what graph a Canviz instance is displaying after the page has already been loaded, you can use the "load" method, like the unnamed example in the root of the source package does. Something like:
myCanviz.load('newgraph.xdot');