6 Dec 2007 10:43
Trouble with GtkPlot
Dan H <dunno <at> stoptrick.com>
2007-12-06 09:43:04 GMT
2007-12-06 09:43:04 GMT
Hello, currently I'm stumped by GtkPlot. Essentially I stripped down the "testgtkplot" example and embedded it into my application, but under most circumstances I can't get any graph to show up (the axes come up, just no data). What's funny is that if I pack all the canvas, dataset, plot creation etc. in a callback connected to the "realize" signal of the containing widget (a GtkFrame), everything shows up fine. But if the plot is created or changed after the gtk_frame is fully operational (from within the main event loop), I only get the white background and the axes, but no plot data. I tried calling gtk_widget_queue_draw() on the GtkPlot but that didn't change anything. Below is a code snippet. The whole thing is contained in a user interface created with Glade. The whole code is here: http://www.nanoscience.de/group_r/members/dhaude/tmp/test-0.1.tar.gz Thanks, --D. ------------------------------------------- /* everything is static so I don't accidentally lose references */ static struct { GtkPlotData *dataset; GtkWidget *plot; GtkWidget *canvas; GtkWidget *container; GtkPlotCanvasChild *child;(Continue reading)
RSS Feed