I have a NSWindow that when I call dataWithEPSInsideRect: on it, I get the
following error appearing in the Console.

<Error>: CMSStreamPSDefinition : CMGetPS2ColorSpace: returned -4200

I only get the error if it is running on 10.5. It works great on 10.6

What I'm trying to do is create an image of the window. Here is the code.

NSData * data = [myWindow dataWithEPSInsideRect: rect];
NSImage * image = [[[NSImage alloc] initWithData:data] autorelease];

I'm not sure why I'm getting the error. Also the NSData returned on 10.5
does not build a sufficient image.
1) Is there something I can do to prevent this error from happening and get
the correct NSData to make an image?

2) Maybe there is a better way to capture an image of a window. This method
of creating the image of the window is very slow. I would be interested in
alternatives.

Thank you for the help
-dave
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to