after copying a image and use the configured shortcut keys in Obsidian, I only get the warning "Coudn't find image in clipboard".
Solution:
The basic problem is that on Linux, the clipboard only stores a reference to the underlying data instead of the real binary data. So after the code runs, the type of file (file = await navigator.clipboard.read();) is just plain text.
To solve this problem, instead of using the default system screenshot tool, I ultilize the tool "flameshot" (maybe other tools are also available), which allows me to capture screenshots and store the real image data in the clipboard.
I know this is nothing to do with the plugin itself, so I just want to offer a solution for our linux user who may meet this problem. Maybe there are better solutions, please please let me know!
OS:
Ubuntu 22.04
Discription:
after copying a image and use the configured shortcut keys in Obsidian, I only get the warning "Coudn't find image in clipboard".
Solution:
The basic problem is that on Linux, the clipboard only stores a reference to the underlying data instead of the real binary data. So after the code runs, the type of file (
file = await navigator.clipboard.read();
) is just plain text. To solve this problem, instead of using the default system screenshot tool, I ultilize the tool "flameshot" (maybe other tools are also available), which allows me to capture screenshots and store the real image data in the clipboard. I know this is nothing to do with the plugin itself, so I just want to offer a solution for our linux user who may meet this problem. Maybe there are better solutions, please please let me know!