Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

image in tkinter

from tkinter import *
from PIL import ImageTk, Image

root = Tk()

c = Canvas(root, width=500, height=500)
c.pack()

img = ImageTk.PhotoImage(Image.open(r"imagepathimagename.extension"))
c.create_image(x, y, image=img, anchor=NW)
 
PREVIOUS NEXT
Tagged: #image #tkinter
ADD COMMENT
Topic
Name
9+9 =