title: How to tell what Entry has focus (Tkinter)
body: <p>I'm working on a project that has a keypad with the number "0 - 9" + a ".". I'm wanting to update several entry boxes one at a time with whatever combination of numbers that are generated from the buttons. The problem I'm having is trying to figure out how to tell what entry box has focus at that time. I've done some googling and have been able to print out different numbers for the entry box selected using focus_get() but that number changes. In the end, I want to be able to click in a entry box with a name similar to entry_0 and be able to click on a button that will pass an integer to that selected box and then be able to click in another box and pass another integer.</p>
  
  <p>Bellow is some code that I found by googling and is the closest that I've found to being able to do what I want but the numbers it prints are different every time the code is ran.</p>
  
  <pre><code>from Tkinter import *
  root=Tk()
  e1=Entry(root)
  e1.pack()
  e2=Entry(root)
  e2.pack()
  def handleReturn(event):
      print "return: event.widget is",event.widget
      print "focus is:",root.focus_get()
  
  root.bind("&lt;Return&gt;",handleReturn)
  
  root.mainloop()
  </code></pre>