Lazarus trunk (Lazarus 2.1.0 r59932 FPC 3.0.4 i386-win32-win32/win64)
When I copy an image (running cheetah from freepascal.org) from Firefox I get:
Format=DataObject
Format=text/html
Format=HTML Format
Format=text/_moz_htmlinfo
Format=text/_moz_htmlcontext
Format=application/x-moz-file-promise-url
Format=application/x-moz-file-promise-dest-filename
Format=Preferred DropEffect
Format=application/x-moz-nativeimage
Format=image/bmp
------image/bmp------
(
Format=Ole Private Data
Format=image/bmp
------image/bmp------
(
End of format list, count=14
Image Format ID = 2
And then when I try to paste, I get an exception:
[Window Title]
project1
[Content]
Wrong image format.
Press OK to ignore and risk data corruption.
Press Abort to kill the program.
[OK] [Abort]
I get the same exception if I try to paste from IrfanView or MS Paint.
I can paste a screenshot from my desktop (made outside the test application) into the second TImage without problems though.
[Edit]
The exception goes away and the image pastes when I change the code:
Fmt := clipboard.FindPictureFormatID;
if 0 = Fmt then // ret first picture format found
memo1.append('fmt = 0, nothing we can paste as image')
else begin
//Image2.Picture.Bitmap.assign(Clipboard);
Image2.Picture.LoadFromClipboardFormat(Fmt);
Bart