Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 3baf47f

Browse files
committed
Merge branch 'v2.0.x'
2 parents 957cc90 + 7b0f9b0 commit 3baf47f

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

INSTALL

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,6 @@ libpng 1.2 (or later)
218218
Required for compatibility if running on versions of Python before
219219
Python 3.2.
220220

221-
222221
Optional GUI framework
223222
^^^^^^^^^^^^^^^^^^^^^^
224223

lib/matplotlib/widgets.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1473,6 +1473,7 @@ def new_axes(self, ax):
14731473
transform=trans,
14741474
visible=False,
14751475
**self.rectprops)
1476+
self.stay_rect.set_animated(False)
14761477
self.ax.add_patch(self.stay_rect)
14771478

14781479
self.ax.add_patch(self.rect)
@@ -1487,7 +1488,10 @@ def _press(self, event):
14871488
self.rect.set_visible(self.visible)
14881489
if self.span_stays:
14891490
self.stay_rect.set_visible(False)
1490-
1491+
# really force a draw so that the stay rect is not in
1492+
# the blit background
1493+
if self.useblit:
1494+
self.canvas.draw()
14911495
xdata, ydata = self._get_data(event)
14921496
if self.direction == 'horizontal':
14931497
self.pressv = xdata
@@ -1510,7 +1514,7 @@ def _release(self, event):
15101514
self.stay_rect.set_height(self.rect.get_height())
15111515
self.stay_rect.set_visible(True)
15121516

1513-
self.canvas.draw()
1517+
self.canvas.draw_idle()
15141518
vmin = self.pressv
15151519
xdata, ydata = self._get_data(event)
15161520
if self.direction == 'horizontal':

0 commit comments

Comments
 (0)