Re: Graph Widget Development



You might want to take a look at the GIW library (it's hosted on sourceforge). I'm not sure if it will save you any coding or not.

Also, a guy I was working with wrote a patch for GIW's x-y plot that utilized Cairo's anti-aliased drawing capability. I can probably dig that up if you're interested.

HTH,

Keith

David Brigada wrote:
Hello,

I am currently developing an X-Y graph widget that I think could someday be included in GTK+. I'd just like to get a little bit of feedback on the design so that I don't start spinning my wheels in the wrong direction. My plan is to make the usage of GtkGraph similar to that of GtkTreeView---they are both widgets that can show large amounts of data.

The widget would be GtkGraph (analogous to GtkTreeView). This would show axes, labels and numbers on the axes, and provide the drawing region to show the plots on. On the GtkGraph widget, application programmers could add GtkGraphPlot objects (similar to GtkTreeViewColumn), each of which would plot a single series of data. The plot objects would be connected to two things, first a GtkGraphRenderer (similar to GtkCellRenderer) that would determine how to plot the data on the graph, and second a GtkTreeModel (usually a GtkListStore or possibly a lightweight replacement that uses an array instead of a linked list for backing) that provides the data that the renderer uses to generate its plots. Each GtkGraphPlot object would also hold one or more column numbers indexing into the tree model.

At some point, when I'm done with a basic implementation of this, I'll send an update with (a link to) the code to the list, if anyone's interested in giving a brief review so that I can try to fit it better to GTK+'s style.

Please let me know what you think about this idea.

Thanks,
David Brigada
_______________________________________________
gtk-devel-list mailing list
gtk-devel-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-devel-list







[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]