How to add/get image data in the OS clipboard using Python?
问题 I have some Python code that edits image files and would like to know how to add image data to the Operating System clipboard and get it from there. When searching for a cross-platform solution to replace or get clipboard text in Python, there were many simple answers to do it (e.g. using the built-in Tkinter module with some code). However, these methods could only use plain text, not other clipboard data like images. My version of Python is 3.x on Windows but the answer needs to be cross