Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
General
GeneralPortable MacsHardwareNetworking
Applications
Mac ApplicationsEudoraFirefox / MozillaInternet ExplorerOutlook ExpressMS OfficeEntourageExcelPowerPointWordVirtual PCMedia PlayerOther MS Products
Programming
Mac ProgrammingCodeWarriorPerl
Country Specific
Australian Mac GroupUK Mac Group

Mac Forum / Programming / Mac Programming / November 2005



Tip: Looking for answers? Try searching our database.

Obj-C/Cocoa: Capturing an NSWindow to an NSBitmapImageRep.

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Luke - 03 Nov 2005 09:44 GMT
I've been going in circles with this one. I wonder if it's possible -
of course it is! ;-) - to capture an NSBitmapImageRep of an on- or
off-screen NSWindow without resorting to referencing its contentView.

Are there (NSGraphicsContext?) methods that return a pixel by pixel
representation of a NSWindow (including the texture of its background?)
or, on a related topic, a portion of the screen. After instantiating an
NSWindow and sending it a makeKeyAndOrderFront: method, what next?

Thanks
Luke
matt neuburg - 03 Nov 2005 17:51 GMT
> I've been going in circles with this one. I wonder if it's possible -
> of course it is! ;-) - to capture an NSBitmapImageRep of an on- or
[quoted text clipped - 4 lines]
> or, on a related topic, a portion of the screen. After instantiating an
> NSWindow and sending it a makeKeyAndOrderFront: method, what next?

-dataWithPDFInsideRect:

m.

Signature

matt neuburg, phd = matt@tidbits.com, http://www.tidbits.com/matt/
Tiger - http://www.takecontrolbooks.com/tiger-customizing.html
AppleScript - http://www.amazon.com/exec/obidos/ASIN/0596005571
Read TidBITS! It's free and smart. http://www.tidbits.com

Luke - 04 Nov 2005 11:58 GMT
> > I've been going in circles with this one. I wonder if it's possible -
> > of course it is! ;-) - to capture an NSBitmapImageRep of an on- or
[quoted text clipped - 8 lines]
>
> m.

Done. Thank you.

Luke
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.