File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11Pausing and Resuming Animations
22-------------------------------
3- We have added public `pause() ` and `resume() ` methods to the base
4- matplotlib.animation.Animation class that allows you to, well, pause
5- and resume animations. These methods can be used as callbacks for event
6- listeners on UI elements so that your plots can have some playback
3+ The `.animation.Animation.pause ` and `.animation.Animation.resume ` methods
4+ allow you to pause and resume animations. These methods can be used as callbacks
5+ for event listeners on UI elements so that your plots can have some playback
76control UI.
Original file line number Diff line number Diff line change 11"""
2- ==================================
3- Pausing and Resuming and Animation
4- ==================================
2+ =================================
3+ Pausing and Resuming an Animation
4+ =================================
55
6- This example showscases :
6+ This example showcases :
77- using the Animation.pause() method to pause an animation.
88- using the Animation.resume() method to resume an animation.
99"""
1616class PauseAnimation :
1717 def __init__ (self ):
1818 fig , ax = plt .subplots ()
19- ax .title . set_text ('Click to pause/resume the animation' )
19+ ax .set_title ('Click to pause/resume the animation' )
2020 x = np .linspace (- 0.1 , 0.1 , 1000 )
2121
2222 # Start with a normal distribution
You can’t perform that action at this time.
0 commit comments