On 2012/08/23 6:52 PM, Andrew Nelson wrote: > Dear list, > apologies for what might be a simple question. I am creating an > application that uses matplotlib for plotting, using the Qt4Agg backend. > I can create the figures without a problem. > > However, I wish to save the state of the application, including the > graphs. The complicating factor is that the user may have altered the > appearance of the graphs via a NavigationToolbar. > > I have no problems saving the data that makes up the graphs, but how do > I save the properties of the graphs (line colour, linewidth, etc)? > I tried using matplotlib.artist.ArtistInspector(Line2D).properties(). > This gives a dictionary of all the properties. However, when I try to > pickle this I get picking errors: > > cPickle.PicklingError: Can't pickle <class > 'matplotlib.axes.AxesSubplot'>: attribute lookup > matplotlib.axes.AxesSubplot failed > > I am sure that there is an easy way of achieving this, I just can't see > it in the documentation. I appreciate any help the list is able to give me.
Maybe there is not an easy way... See https://github.com/matplotlib/matplotlib/pull/1020. Eric > > regards, > Andrew > ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users