title: AttributeError: 'Event' object has no attribute 'Text1'
body: <p>My purpose is to get the mouse selected text through the Tkinter <code>Text</code> control.</p>
  
  <p>Part of the code:</p>
  
  <pre><code>self.Text1 = Text(top)
  self.Text1.place(relx=0.07, rely=0.09, relheight=0.04, relwidth=0.34)
  self.Text1.configure(background="white")
  self.Text1.configure(font="TkTextFont")
  self.Text1.configure(foreground="black")
  self.Text1.configure(highlightbackground="#d9d9d9")
  self.Text1.configure(highlightcolor="black")
  self.Text1.configure(insertbackground="black")
  self.Text1.configure(selectbackground="#c4c4c4")
  self.Text1.configure(selectforeground="black")
  self.Text1.configure(width=294)
  self.Text1.configure(wrap=WORD)
  
  self.Scrolledtext1 = ScrolledText(top)
  self.Scrolledtext1.place(relx=0.46, rely=0.19, relheight=0.62
          , relwidth=0.4)
  self.Scrolledtext1.configure(background="white")
  self.Scrolledtext1.configure(font="TkTextFont")
  self.Scrolledtext1.configure(foreground="black")
  self.Scrolledtext1.configure(highlightbackground="#d9d9d9")
  self.Scrolledtext1.configure(highlightcolor="black")
  self.Scrolledtext1.configure(insertbackground="black")
  
  def button_down(self,):
      global s
      s = self.Text1.index('@%s,%s wordstart' % (event.x, event.y))
  
  def button_up(self, ):
      global e
      e = self.Text1.index('@%s,%s wordend' % (event.x, event.y))
  
  
  def test(self,):
      print(self.Scrolledtext1.get(s,e))
  
  self.Scrolledtext1.bind("&lt;Button-1&gt;", button_down)
  self.Scrolledtext1.bind("&lt;ButtonRelease-1&gt;", button_up)
  self.Button2.configure(command=test(self,))
  </code></pre>
  
  <p>Exception in Tkinter callback：</p>
  
  <p><a href="https://i.stack.imgur.com/c2012.png" rel="nofollow noreferrer">screenshot of traceback showing exception being generated</a></p>
  
  <pre class="lang-none prettyprint-override"><code>AttributeError: 'Event' object has no attribute 'Text1'
  </code></pre>