Reading image from system clipboard
Reading image from system clipboard
- Subject: Reading image from system clipboard
- From: Deepa <email@hidden>
- Date: Mon, 3 Aug 2009 11:37:12 +0530
- "x-copyrighted-material: http://www.robosoftin.com"
Hi,
I am developing an desktop app for which I want to implement a
behavior which is similar to 'New from clipboard' of Preview
application.
I tried using NSPasteboard:
// To get file copied to clipboard from Finder
NSArray *files = [[NSPasteboard generalPasteboard]
propertyListForType: NSFilenamesPboardType];
This returns array of files copied to the clipboard
// To get tiff image
NSData *pbData = [[NSPasteboard generalPasteboard] dataForType:
NSTIFFPboardType];
CIImage *pbImg = [CIImage imageWithData: pbData];
But this doesn't return null (tiff image data was copied to the
clipboard).
Am I doing something wrong here???
Can someone help me out to sove this problem. I also wanted to know a
method which copies and reads jpeg/gif/png image formats to/from
system clipboard.
Thanks in advance.
Thanks and Regards,
Deepa
email@hidden
-----------------------------------------------
Robosoft Technologies - Come home to Technology
Disclaimer: This email may contain confidential material. If you were not an intended recipient, please notify the sender and delete all copies. Emails to and from our network may be logged and monitored. This email and its attachments are scanned for virus by our scanners and are believed to be safe. However, no warranty is given that this email is free of malicious content or virus.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden