File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -856,7 +856,8 @@ def _notify_change_observers(self):
856856
857857 def begin_typing (self , x ):
858858 self .capturekeystrokes = True
859- if rcParams ['toolbar' ] != 'toolmanager' :
859+ # Check for toolmanager handling the keypress
860+ if self .ax .figure .canvas .manager .key_press_handler_id is not None :
860861 # disable command keys so that the user can type without
861862 # command keys causing figure to be saved, etc
862863 self .reset_params = {}
@@ -872,7 +873,8 @@ def stop_typing(self):
872873 # user's code, we only want to call it once we've already done
873874 # our cleanup.
874875 if self .capturekeystrokes :
875- if rcParams ['toolbar' ] != 'toolmanager' :
876+ # Check for toolmanager handling the keypress
877+ if self .ax .figure .canvas .manager .key_press_handler_id is not None :
876878 # since the user is no longer typing,
877879 # reactivate the standard command keys
878880 for key in self .params_to_disable :
You can’t perform that action at this time.
0 commit comments