title: View Google maps inside Tkinter app
body: <p>I have the following function in python,</p>
  
  <pre><code>def in_out(lat,lon,api_key):
      url = "https://maps.googleapis.com/maps/api/staticmap?key=" + api_key + "&amp;center="+ str(lat) + "," + str(lon) + "&amp;zoom=20&amp;format=png&amp;maptype=roadmap&amp;style=element:labels%7Cvisibility:off&amp;style=feature:administrative\
          %7Celement:geometry%7Cvisibility:off&amp;style=feature:administrative.neighborhood%7Cvisibility:off&amp;style=feature:landscape.man_made%7Csaturation:90\
          %7Clightness:-5%7Cvisibility:simplified%7Cweight:8&amp;style=feature:poi%7Cvisibility:off&amp;style=feature:road%7Cvisibility:off&amp;style=feature:road%7Celement:labels.icon\
          %7Cvisibility:off&amp;style=feature:transit%7Cvisibility:off&amp;style=feature:water%7Cvisibility:off&amp;size=" + str(dim)
      display(im(requests.get(url).content))
  </code></pre>
  
  <p>When we pass an lat, long along with google API key, it gives us a image of the map.</p>
  
  <p>For eg,</p>
  
  <pre><code>in_out(47.6935488,-122.1332999, api_key)
  </code></pre>
  
  <p>gives the following,</p>
  
  <p><a href="https://i.stack.imgur.com/fmz6Z.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/fmz6Z.png" alt="enter image description here"></a></p>
  
  <p>Now I want to display the image inside the TKinter app. The following is the code that I have written,</p>
  
  <pre><code>def show_entry_fields():
      print(in_out(e1.get(),e2.get(),key_lst))
      Label(master, text=in_out(e1.get(),e2.get(),api_key)).grid(row=2)
  
  master = tk.Tk()
  Label(master, text="Latitude").grid(row=0)
  Label(master, text="Logitude").grid(row=1)
  Label(master, text="Output: ").grid(row=2)
  
  
  e1 = Entry(master)
  e2 = Entry(master)
  
  e1.grid(row=0, column=1)
  e2.grid(row=1, column=1)
  
  Button(master, text='Quit', command=master.quit).grid(row=5, column=0, sticky=W, pady=4)
  # Button(master, text='Show', command=show_entry_fields).grid(row=3, column=1, sticky=W, pady=4)
  
  Button(master, text='Show', command=show_entry_fields).grid(row=5, column=1, sticky=W, pady=4)
  
  
  mainloop( )
  </code></pre>
  
  <p>When I run this code, I am getting the following,</p>
  
  <p><a href="https://i.stack.imgur.com/zqwAJ.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/zqwAJ.jpg" alt="enter image description here"></a></p>
  
  <p>The image is displayed in the iPython notebook.</p>
  
  <p>I want the image to be shown inside the Tkinter app. I have tried several things to solve this problem, but it is not working for me. Can anybody help solve this issue ? any leads would be helpful.</p>
  
  <p>Thanks</p>