[Kde-extra-gear] KGraphViewer ideas ...

Sandro Andrade sandro.andrade at gmail.com
Wed Jun 17 15:05:05 CEST 2009


Hi Gaël,

At the beginning, it was only a pure visualization tool, but it appeared
> that
> interactions were needed (to support actions, changes during graph life
> time,
> etc). And then I started to add editing features. But, you're right view
> and
> edit features could be separated.


Ok !


> > 2) Can I implement, in the application, the code to be executed when a
> > graph node is clicked or has a mouse over event ? Again, wouldn't the
> > kpart have its reuse improved if such interaction features were not
> > pre-defined ?
> They aren't! They are just signals that you can connect to to handle
> actions.
> Also, when you want to act on a graph element, you use slots to send it
> messages.
> When you click on a node, the selectionIs signal is sent.
> The part is missing hovering signals, though.


Ok, I'll try connect such signals to slots in my KDevelop plugin.
BTW, in the attached image you can see some preliminary result on control
flow graphs inside KDevelop using the KGraphViewer kpart.


> >
> > 3) Why haven't you used Graphviz as a library (as indicated in
> > http://www.graphviz.org/pdf/libguide.pdf) instead of relying in
> > QProcess invocation of dot, twopi and output processing (I know, this
> > is the KCachegrind approach) ?
> You said it: it's the kcachegrind approach and in fact, when I started
> kgraphviewer I reused the kcachegrind code :-) Well, there is not much
> remaining up to now.
> I think it is still a good solution. The xdot format is easy to parse. But
> I
> already thinked to have a look at the graphviz library.


I'm using Graphviz programmatically to construct the graph from the function
calls collected in the source code. It's API is quite ease and complete.

Thanks,
- -
Sandro Santos Andrade
--------------------------------------------------------
Distributed Systems Laboratory (LaSiD)
Computer Science Department (DCC)
Federal University of Bahia
Brazil
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.kde.org/pipermail/kde-extra-gear/attachments/20090617/5556856e/attachment-0001.htm 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: controlflowgraph.png
Type: image/png
Size: 174382 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/kde-extra-gear/attachments/20090617/5556856e/attachment-0001.png 


More information about the Kde-extra-gear mailing list