class_docstr: Helper class that groups all the user interactions for a Figure
  
  Attributes
  ----------
  figure: `Figure`
  keypresslock: `widgets.LockDraw`
      `LockDraw` object to know if the `canvas` key_press_event is locked
  messagelock: `widgets.LockDraw`
      `LockDraw` object to know if the message is available to write
class_docstr_tok: ["Helper","class","that","groups","all","the","user","interactions","for","a","Figure","Attributes","--","--","--","--","--","figure",":","`","Figure","`","keypresslock",":","`","widgets.LockDraw","`","`","LockDraw","`","object","to","know","if","the","`","canvas","`","key_press_event","is","locked","messagelock",":","`","widgets.LockDraw","`","`","LockDraw","`","object","to","know","if","the","message","is","available","to","write"]
docstr: Trigger a tool and emit the tool_trigger_[name] event
  
  Parameters
  ----------
  name : string
      Name of the tool
  sender: object
      Object that wishes to trigger the tool
  canvasevent : Event
      Original Canvas event or None
  data : Object
      Extra data to pass to the tool when triggering
docstr_tok: ["Trigger","a","tool","and","emit","the","tool_trigger_","[","name","]","event","Parameters","--","--","--","--","--","name",":","string","Name","of","the","tool","sender",":","object","Object","that","wishes","to","trigger","the","tool","canvasevent",":","Event","Original","Canvas","event","or","None","data",":","Object","Extra","data","to","pass","to","the","tool","when","triggering"]
code: def trigger_tool(
      self, name, sender=None, canvasevent=None, data=None
  ):
      """
      Trigger a tool and emit the tool_trigger_[name] event
  
      Parameters
      ----------
      name : string
          Name of the tool
      sender: object
          Object that wishes to trigger the tool
      canvasevent : Event
          Original Canvas event or None
      data : Object
          Extra data to pass to the tool when triggering
      """
      tool = self.get_tool(name)
      if tool is None:
          return
  
      if sender is None:
          sender = self
  
      self._trigger_tool(name, sender, canvasevent, data)
  
      s = "tool_trigger_%s" % name
      event = ToolTriggerEvent(s, sender, tool, canvasevent, data)
      self._callbacks.process(s, event)
  
imports: from __future__ import absolute_import, division, print_function, unicode_literals
  import six
  import warnings
  import matplotlib.cbook
  import matplotlib.widgets
  from matplotlib.rcsetup import validate_stringlist
  import matplotlib.backend_tools
label_desc: Use image node_id 18 for calling the ToolManager obj's underlying member method code with example usage: obj.trigger_tool(name, sender, canvasevent, data) without return types