class_docstr: Attributes
  ----------
  canvas : `FigureCanvas`
      The FigureCanvas instance
  num : int or str
      The Figure number
  toolbar : Gtk.Toolbar or Gtk.Box
      The toolbar
  vbox : Gtk.VBox
      The Gtk.VBox containing the canvas and toolbar
  window : Gtk.Window
      The Gtk.Window
class_docstr_tok: ["Attributes","--","--","--","--","--","canvas",":","`","FigureCanvas","`","The","FigureCanvas","instance","num",":","int","or","str","The","Figure","number","toolbar",":","Gtk.Toolbar","or","Gtk.Box","The","toolbar","vbox",":","Gtk.VBox","The","Gtk.VBox","containing","the","canvas","and","toolbar","window",":","Gtk.Window","The","Gtk.Window"]
code: def destroy(self, *args):
      if self._destroying:
          # Otherwise, this can be called twice when the user presses 'q',
          # which calls Gcf.destroy(self), then this destroy(), then triggers
          # Gcf.destroy(self) once again via
          # `connect("destroy", lambda *args: Gcf.destroy(self))`.
          return
      self._destroying = True
      self.window.destroy()
      self.canvas.destroy()
  
imports: import logging
  import sys
  import matplotlib
  from matplotlib import _api, backend_tools, cbook
  from matplotlib._pylab_helpers import Gcf
  from matplotlib.backend_bases import _Backend, FigureCanvasBase, FigureManagerBase, NavigationToolbar2, TimerBase
  from matplotlib.backend_tools import Cursors
  import gi
  from gi.repository import Gdk, Gio, GLib, Gtk
label_desc: Use image node_id 2 for calling the _FigureManagerGTK obj's underlying member method code with example usage: obj.destroy() without return types