pyvista.RenderWindowInteractor.remove_observer

pyvista.RenderWindowInteractor.remove_observer#

RenderWindowInteractor.remove_observer(observer)[source]#

Remove an observer.

Parameters:
observerint

The identifier of the observer to remove.

Examples

Add an observer and immediately remove it.

>>> import pyvista as pv
>>> pl = pv.Plotter()
>>> obs_enter = pl.iren.add_observer(
...     "EnterEvent", lambda *_: print('Enter!')
... )
>>> pl.iren.remove_observer(obs_enter)
../../../_images/pyvista-RenderWindowInteractor-remove_observer-1_00_00.png