matplotlib.widgets.AxesWidget#
- classmatplotlib.widgets.AxesWidget(ax)[source]#
Bases:
WidgetWidget connected to a single
Axes.To guarantee that the widget remains responsive and not garbage-collected,a reference to the object should be maintained by the user.
This is necessary because the callback registrymaintains only weak-refs to the functions, which are memberfunctions of the widget. If there are no references to the widgetobject it may be garbage collected which will disconnect the callbacks.
- Attributes:
- ax
Axes The parent Axes for the widget.
- canvas
FigureCanvasBase The parent figure canvas for the widget.
activeboolIs the widget active?
- ax
- propertycanvas#
Examples usingmatplotlib.widgets.AxesWidget#
Select indices from a collection using polygon selector
Select indices from a collection using polygon selector
On this page