title: When using an event in Tkinter, how can you pass in other variables to the event function?
body: <p>In this example, that I used from <a href="http://effbot.org/tkinterbook/tkinter-events-and-bindings.htm" rel="nofollow">http://effbot.org/tkinterbook/tkinter-events-and-bindings.htm</a>, how could you pass in more variables to the function callback. Say you wanted to pass in a dict that you created and use that dict, how could you do that without calling global variables.</p>
  
  <pre><code>from Tkinter import *
  
  root = Tk()
  
  def callback(event):
      print "clicked at", event.x, event.y
  
  frame = Frame(root, width=100, height=100)
  frame.bind("&lt;Button-1&gt;", callback)
  frame.pack()
  
  root.mainloop()
  </code></pre>
  
  <p>Newb here, might have some awkward phrasing, feel free to ask for clarification.</p>