title: How to call a function when clicking on an image in Tkinter?
body: <p>I know it's easy to call a function with Tkinter buttons by using <code>command</code>, but it doesn't work the same way with images. My question is pretty simple I believe, how can I call a function by clicking on an image?</p>
  
  <p>Here's the code. I want to click on <code>picture</code> and that will call the <code>make_newwindow</code> function.</p>
  
  <pre><code>from tkinter import *
  import tkinter as tk
  
  def make_newwindow():
      global newwindow
      root.withdraw()
      newwindow = tk.Toplevel()
      newwindow.title('Nível da grama região 2')
      newwindow.geometry('580x520')
  
  root = tk.Tk()
  root.title('Nível da grama região 1')
  root.geometry("580x520")
  picture = PhotoImage(file="picture.png")
  label0 = Label(root, image=picture, borderwidth=0, highlightthickness=0)
  label0.place(x=62, y=205)
  
  
  root.mainloop()
  </code></pre>