title: Class inherits tkinter.Tk(), how to access objects?
body: <p>I am using this code, which I  found online, to set up my Tkinter GUI.</p>
  <pre><code>import tkinter as tk
  
  class App(tk.Tk):
      def __init__(self,*args,**kwargs):
          tk.Tk.__init__(self, *args, **kwargs)
          self.geometry(&quot;600x400&quot;)
          container = tk.Frame(self)
          container.pack(side=&quot;top&quot;, fill=&quot;both&quot;, expand=True)
  
          self.test = &quot; this is a test&quot;
  
  print(XXXX.test)
  
  App().mainloop()
  </code></pre>
  <p>Now I would like to acces the &quot;self.test&quot; from somewhere else in the program (see: XXXX.test).<br />
  -How can I achieve this?</p>
  <p>I'm very new to object oriented programming and I am a little bit irritated by what my code above is actually doing<br />
  -Have I created one instance by inheriting the tkinter.Tk() class? If yes what is the &quot;self&quot; of this instance?</p>