Re: converting a NSView into an NSImage, when scaling via scaleUnitSquareToSize [SOLVED, kinda]

2009-10-04 Thread Martin Redington
Well, I seem to be able to get the image with the following (where scale is the absolute scale of the view, implemented in the category defined at http://developer.apple.com/mac/library/qa/qa2004/qa1346.html) This still feels wrong (note the use of frame instead of bounds for drawRect call), and

converting a NSView into an NSImage, when scaling via scaleUnitSquareToSize ...

2009-10-01 Thread Martin Redington
In order to work around the some of the issues I've been encountering when scrolling scaled NSTextView's, I've been looking at capturing the NSTextView as an NSImage, and using that instead (which would meet my requirements). I've tried the usual approaches (see below), but none of them are