delphiro at zonnet.nl
Fri Jun 20 13:12:37 CEST 2003
I am writing an application where I use Chaco for the excellent graphical output and now I have a question about creating / freeing objects.
I use this code to create and assign a chaco-object (a 'vertical') to my dialog:
self.plotitem = PlotCanvas( pv1, PlotTitle( 'Soilstress in vertical ..' ), plot_type = 'rangebar', axis_index = x_ax, axis = y_ax )
now the user has the possibility to change the view to another 'vertical' so self.plotitem should be assigned to another PlotCanvas and the old one should disappear.
What is the correct way to do this?
should I 'free' self.plotitem before assigning a new PlotCanvas to self.plotitem and if so, how do you 'free' objects in Python?
Thanks in advance,
More information about the Python-list