是否必须将我的.ai文件转换为png?我的代码适用于png/jpg/gif,但是对于.ai,它说文件类型不被识别
from tkinter import *
root = Tk()
vector_image = PhotoImage(file='adobe_illustrator.ai')
label = Label(root)
label.config(image=vector_image)
label.pack()
root.mainloop()
发布于 2020-03-11 21:42:49
不,tkinter不支持矢量图形。可能有第三方python库可以为您转换它。
https://stackoverflow.com/questions/60644194
复制相似问题