@@ -141,22 +141,18 @@ class Button(AxesWidget):
141
141
A GUI neutral button.
142
142
143
143
For the button to remain responsive you must keep a reference to it.
144
+ Call :meth:`on_clicked` to connect to the button.
144
145
145
- The following attributes are accessible
146
-
147
- *ax*
146
+ Attributes
147
+ ----------
148
+ ax :
148
149
The :class:`matplotlib.axes.Axes` the button renders into.
149
-
150
- *label*
150
+ label :
151
151
A :class:`matplotlib.text.Text` instance.
152
-
153
- *color*
152
+ color :
154
153
The color of the button when not hovering.
155
-
156
- *hovercolor*
154
+ hovercolor :
157
155
The color of the button when hovering.
158
-
159
- Call :meth:`on_clicked` to connect to the button
160
156
"""
161
157
162
158
def __init__ (self , ax , label , image = None ,
@@ -2451,7 +2447,8 @@ def _rect_bbox(self):
2451
2447
2452
2448
2453
2449
class LassoSelector (_SelectorWidget ):
2454
- """Selection curve of an arbitrary shape.
2450
+ """
2451
+ Selection curve of an arbitrary shape.
2455
2452
2456
2453
For the selector to remain responsive you must keep a reference to
2457
2454
it.
@@ -2464,14 +2461,6 @@ class LassoSelector(_SelectorWidget):
2464
2461
similar to :class:`RectangleSelector` and :class:`SpanSelector` and will
2465
2462
continue to interact with the axes until disconnected.
2466
2463
2467
- Parameters:
2468
-
2469
- *ax* : :class:`~matplotlib.axes.Axes`
2470
- The parent axes for the widget.
2471
- *onselect* : function
2472
- Whenever the lasso is released, the `onselect` function is called and
2473
- passed the vertices of the selected path.
2474
-
2475
2464
Example usage::
2476
2465
2477
2466
ax = subplot(111)
@@ -2481,15 +2470,24 @@ def onselect(verts):
2481
2470
print(verts)
2482
2471
lasso = LassoSelector(ax, onselect)
2483
2472
2484
- *button* is a list of integers indicating which mouse buttons should
2485
- be used for rectangle selection. You can also specify a single
2486
- integer if only a single button is desired. Default is *None*,
2487
- which does not limit which button can be used.
2473
+ Parameters
2474
+ ----------
2475
+ ax : :class:`~matplotlib.axes.Axes`
2476
+ The parent axes for the widget.
2477
+ onselect : function
2478
+ Whenever the lasso is released, the *onselect* function is called and
2479
+ passed the vertices of the selected path.
2480
+ button : list[Int], optional
2481
+ A list of integers indicating which mouse buttons should be used for
2482
+ rectangle selection. You can also specify a single integer if only a
2483
+ single button is desired. Default is ``None``, which does not limit
2484
+ which button can be used.
2488
2485
2489
2486
Note, typically:
2490
- 1 = left mouse button
2491
- 2 = center mouse button (scroll wheel)
2492
- 3 = right mouse button
2487
+
2488
+ - 1 = left mouse button
2489
+ - 2 = center mouse button (scroll wheel)
2490
+ - 3 = right mouse button
2493
2491
2494
2492
"""
2495
2493
0 commit comments