Skip to content

Picture

Construct a picture widget with the parent MASTER.

Parameters

NameTypeDescription
mastertkinter.Tk
imagePIL.Image
widthint
heightint
textstr
fgstr
bgstr
textvariabletkinter.StringVar

Methods

update

Clear canvas to redraw

configure

Modify the widget

Example

py
from PIL import Image
import tkinter
import tkinterplus

root = tkinter.Tk()
widget = tkinterplus.Picture(root, Image.open('logo.png'))
widget.pack()
root.mainloop()

example-Picture

Not associated with or approved by Mojang Studios or Microsoft