Open dhanjit opened 5 years ago
This actually works now. At least on my system running xsel 1.2.0:
`` ~ ❯❯❯ xsel -b < 099.jpg ~ ❯❯❯ xclip -seletion clipboard -t TARGETS -o TIMESTAMP TARGETS MULTIPLE text/html text/_moz_htmlcontext text/_moz_htmlinfo UTF8_STRING COMPOUND_TEXT TEXT STRING text/plain;charset=utf-8 text/plain text/x-moz-url-priv
And CTRL+v in to various applications seems to work fine.
Scratch that, it only kinda works. If I've previously copied a file from my file browser to the clipboard then sometimes using xsel to put a different file in the clipboard works, but not always.
This are the TARGETS when I do a simple right click -> copy image on firefox. The same goes for chrome.
This is what I get with xsel.
And ofcourse pasting the image is something like hangouts doesn't work.
Sadly, currently xclip also doesn't correctly copy an image from file. Neither does any other such tool. CopyQ (https://github.com/hluk/CopyQ) is a heavy alternative to this but doesn't have a non-daemon mode.
It would be good to have xsel support it, as there are no lightweight alternatives currently. Also xsel is already used by many folk and other applications.