From: Dani Marti <daniel.marti@up...>  20060829 13:44:29

Thank you Michael for your answer. I'm glad I was pointing to the good direction. The concept is now clear to me, but I don't know how to implement it. From my previous example A = generate_graph(0), My question is, what precise object should the function "generate_graph" return? Is there anything wrong in def generate_graph(parameter): g = graph.graphxy(width=1, height=1) g.plot(graph.data.function("y(x)= x**4  %f * x**2" % parameter, min=2, max=2)) return g A = generate_graph(1) ? [There are no errors, but I wonder if this the proper way to do it] > As for the positioning: graph.graphxy() accepts parameters xpos and > ypos just like the first two parameters of text.text() (or translate > the graph canvasses). That's precisely what I prefer not to do: to specify the position at the very beginning, through the 'graph.graphxy' call inside 'generate_graph'. This would require to modify the function 'generate_graph' to add a second argument (the position), which I don't want to do. My idea is to create the 'floating' figure (using Gimp terminology) and then 'anchor' it at the position I choose at the end. Is that possible? Thanks a lot for your answer. d 