Paste transparent PNG with proper alpha


#1

It was allready reported as it is long term bug, but still not solved - when you open any alpha png, e.g. http://search.seznam.cz/r/img/logo-small-cs.png in the browser and then copy it and paste it to Balsamiq, the alpha channel is converted to black. If you first save it and then add it as Image, or if you add Image and paste the URL as file name, the image is normaly transparent.
This problem has many other programs on windows, but not all of them, it is a problem of the clipboard, but there is definitely some solution (e.g. look here http://superuser.com/questions/237784/copying-png-with-transparency-from-browser-shows-a-black-background-instead)


#2

Yeah, I’m sorry about that Tomas. We are still working on that one.

You’re on Windows 7, if I remember correctly? Let me know if you are on a different Windows/Mac version. We have been looking for reproducible steps for other OSes.


#3

this bug is an all Windows versions afaik, definitely with version 7 and Windows 10 (even the latest beta), all 64 bit, not sure with 32bit - they do store image data as bitmap without alpha
The solution is afaik this - clipboard contains for such image 4 type of data: HTML format, Bitmap, Bitmap DIB and Bitmap DIBV5.

You have 2 options - use Bitmap DIBV5 (maybe this https://groups.google.com/forum/#!topic/microsoft.public.dotnet.framework.drawing/0sSPCrzf8yE will help, althought i do not know how it works with Adobe Air - here is some info http://help.adobe.com/en_US/AIR/1.5/devappshtml/WS5b3ccc516d4fbf351e63e3d118666ade46-7d7e.html)

Second option is afaik to look into HTML format, where you will read something like:
Version:0.9
StartHTML:0000000105
EndHTML:0000000237
StartFragment:0000000141
EndFragment:0000000201
[html]
[body]
[!–StartFragment–][img src=“http://search.seznam.cz/r/img/logo-small-cs.png”/][!–EndFragment–]
[/body]
[/html]
(i have replaced < with [ as this editor seems to broke it otherwise)

So that second option is look for the HTML_FORMAT and read the img src and if exists load it instead of using the BITMAP_FORMAT


#4

Oh weird, let me run some tests, and then I will poke the devs on Monday to see what’s going on.