title: Adding an image to text widget of Tkinter in python 2.7
body: <p>I am new to Tkinter and i am trying to add an image to a text widget in Tkinter python 2.7
  I have looked up some resources on the internet and as far as i have gotten is this code but it is giving error - 
   " </p>
  
  <pre><code>File "anim.py", line 11, in &lt;module&gt;
      text.image_create(END,image=photoImg)
    File "C:\Python27\lib\lib-tk\Tkinter.py", line 2976, in image_create
      *self._options(cnf, kw))
    TypeError: __str__ returned non-string (type file) 
  </code></pre>
  
  <p>"</p>
  
  <p>please tell me where i went wrong. Thanks in advance :)</p>
  
  <pre><code>from PIL import Image,ImageTk
  from Tkinter import *
  root = Tk()
  root.geometry("900x900+100+100")
  image1 = open('IMG_20160123_170503.jpg')
  photoImg = PhotoImage(image1)
  frame = Frame(root)
  frame.pack()
  text = Text(frame)
  text.pack()
  text.image_create(END,image=photoImg)
  root.mainloop()
  </code></pre>