title: tkinter 'NoneType' object has no attribute 'config'
body: <p>I got an error for AttributeError: 'NoneType' object has no attribute 'config' when I run a Treasure Island game I created (very original). I've looked at other posts about this and tried the same thing to no solution, anyway, here's the code:</p>
  <pre><code>import tkinter
  window = tkinter.Tk()
  
  window.title(&quot;Treasure Island&quot;)
  window.geometry(&quot;500x500&quot;)
  
  text = tkinter.Label(window, text='''
            |                   |                  |                     |
   _________|________________.=&quot;&quot;_;=.______________|_____________________|_______
  |                   |  ,-&quot;_,=&quot;&quot;     `&quot;=.|                  |
  |___________________|__&quot;=._o`&quot;-._        `&quot;=.______________|___________________
            |                `&quot;=._o`&quot;=._      _`&quot;=._                     |
   _________|_____________________:=._o &quot;=._.&quot;_.-=&quot;'&quot;=.__________________|_______
  |                   |    __.--&quot; , ; `&quot;=._o.&quot; ,-&quot;&quot;&quot;-._ &quot;.   |
  |___________________|_._&quot;  ,. .` ` `` ,  `&quot;-._&quot;-._   &quot;. '__|___________________
            |           |o`&quot;=._` , &quot;` `; .&quot;. ,  &quot;-._&quot;-._; ;              |
   _________|___________| ;`-.o`&quot;=._; .&quot; ` '`.&quot;\` . &quot;-._ /_______________|_______
  |                   | |o;    `&quot;-.o`&quot;=._``  '` &quot; ,__.--o;   |
  |___________________|_| ;     (#) `-.o `&quot;=.`_.--&quot;_o.-; ;___|___________________
  ____/______/______/___|o;._    &quot;      `&quot;.o|o_.--&quot;    ;o;____/______/______/____
  /______/______/______/_&quot;=._o--._        ; | ;        ; ;/______/______/______/_
  ____/______/______/______/__&quot;=._o--._   ;o|o;     _._;o;____/______/______/____
  /______/______/______/______/____&quot;=._o._; | ;_.--&quot;o.--&quot;_/______/______/______/_
  ____/______/______/______/______/_____&quot;=.o|o_.--&quot;&quot;___/______/______/______/____
  /______/______/______/______/______/______/______/______/______/______/_____ /
  ''')
  
  text.pack()
  text = text.config(font=('length',15))
  
  line1 = tkinter.Label(window, text=&quot;Welcome to Treasure Island,\n&quot;
                                     &quot;Your goal is to find the buried Treasure!&quot;)
  
  line1.pack()
  line1 = text.config(font=('length',15))
  
  window.mainloop()
  </code></pre>
  <p>Exact error:</p>
  <pre><code>    line1 = text.config(font=('length',15))
  AttributeError: 'NoneType' object has no attribute 'config'
  </code></pre>