__init__.py 351 B

123456789101112131415161718
  1. from . import _base
  2. from ._axes import Axes
  3. # Backcompat.
  4. Subplot = Axes
  5. class _SubplotBaseMeta(type):
  6. def __instancecheck__(self, obj):
  7. return (isinstance(obj, _base._AxesBase)
  8. and obj.get_subplotspec() is not None)
  9. class SubplotBase(metaclass=_SubplotBaseMeta):
  10. pass
  11. def subplot_class_factory(cls): return cls