Phil Elson <pelson.pub@...83...> writes:
I don't have a good answer to this and have had to implement such a
thing in an outstanding pull request (in my case, I have a figure
which has been un-pickled and needs re-attaching to pyplot).My proposed mechanism goes something like:
figure = matplotlib.figure.Figure(...)
import matplotlib.pyplot as plt
mgr = plt._backend_mod.new_figure_manager_given_figure(num, self)
Obviously this doesn't even exist on master yet, so if you need this
functionality from a version before this you will have to reverse
engineer the pyplot.figure function.
Thank you Phil,
This would be acceptable, although I cannot say that I'm very happy with the way
matplotlib is organized now. Can you point me to a code example where anything
like this reverse engineering is done?
Thanks,
Anton