有时候须要获取剪切板图片进行处理,这里是一种方法code
from PIL import ImageGrab image = ImageGrab.grabclipboard() # 获取剪贴板文件 image.save('xxx.png/bmp/jpg')