From https://invent.kde.org/graphics/spectacle/-/issues/7 ``` I would like to suggest adding a button in the "Copy Image to Clipboard" dropdown which copies the base64 of the image to the Clipboard so that it can be easily pasted in things like markdown documents and such. ``` And add an option in `After taking a screenshot` selection * Copy image to clipboard (Base64)
Huh, I've never heard of that. Can you point me to some documentation about how this works? Is this only a feature for a specific flavor of Markdown?
Created attachment 161525 [details] smime.p7s
The format for data is here https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URLs and it looks like this: in html: <img src="data:image/png;base64,iVBORw0KGgoAAA ANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4 //8/w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU 5ErkJggg==" alt="Red dot" /> in markdown:  so clipboard should have string data starting with data:image/png;base64, and ends with(out) base64 paddings == PS For QT it is something like this https://doc.qt.io/qt-6/qbytearray.html#toBase64
Doesn't seem like a high priority and it's a pretty advanced user option, but I'll leave this report open.
You might actually want to look into customizing Klipper (the clipboard applet) actions. You can make Klipper run commands on things you copied to the clipboard and there may be a way to convert images in the clipboard to base64.