Make adjustText available for web frameworks
According to the matplotlib documentation, one should not use pyplot with web frameworks such as Django or Flask. Instead,
[s]ince Matplotlib 3.1, one can directly create figures using the Figure constructor and save them to in-memory buffers. In older versions, it was necessary to explicitly instantiate an Agg canvas (see e.g. CanvasAgg demo).
Now, as I changed this in my Django application, adjustText stopped working*. I see that it is importing pyplot explicitly. Is it feasible to change adjustText so that it only uses matplotlib.figure.Figure?
*) If I annotated a scatter plot with .text(), adjust_text() would remove all texts. If I used .annotate(), it would not move all labels quite a bit right, but not make any useful changes.
It may be that #141 will solve this if you pass the ax argument.