MCPcopy Index your code
hub / github.com/matplotlib/matplotlib / add_axobserver

Method add_axobserver

lib/matplotlib/figure.py:3354–3358  ·  view source on GitHub ↗

Whenever the Axes state change, ``func(self)`` will be called.

(self, func)

Source from the content-addressed store, hash-verified

3352 self.stale = True
3353
3354 def add_axobserver(self, func):
3355 """Whenever the Axes state change, ``func(self)`` will be called."""
3356 # Connect a wrapper lambda and not func itself, to avoid it being
3357 # weakref-collected.
3358 self._axobservers.connect("_axes_change_event", lambda arg: func(arg))
3359
3360 def savefig(self, fname, *, transparent=None, **kwargs):
3361 """

Callers 1

add_figureMethod · 0.80

Calls 2

funcFunction · 0.50
connectMethod · 0.45

Tested by

no test coverage detected