Skip to content

Commit

Permalink
MRG: Remove toolbars in PyVista plotter (#7572)
Browse files Browse the repository at this point in the history
* Remove toolbars

* Add attributes checking
  • Loading branch information
GuillaumeFavelier authored Apr 7, 2020
1 parent 1867bfe commit ab50b23
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions mne/viz/backends/_pyvista.py
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,10 @@ def __init__(self, fig=None, size=(600, 600), bgcolor='black',
with _disabled_depth_peeling():
self.plotter = self.figure.build()
self.plotter.hide_axes()
if hasattr(self.plotter, "default_camera_tool_bar"):
self.plotter.default_camera_tool_bar.close()
if hasattr(self.plotter, "saved_cameras_tool_bar"):
self.plotter.saved_cameras_tool_bar.close()
_enable_aa(self.figure, self.plotter)

def subplot(self, x, y):
Expand Down

0 comments on commit ab50b23

Please sign in to comment.