* Headers/AppKit/NSImageRep.h: Add

-drawInRect:fromRect:operation:fraction:respectFlipped:hints: method
* Source/NSImage.m:
* Source/NSImageRep.m: Refactor drawing code from NSImage to NSImageRep.
This should cause no functionlity change, but it lets NSImageRep
subclasses implement more efficient versions of -drawInRect:fromRect:...
that don't involve the (expensive) drawing of the image in a temporary
offscreen window and then drawing from there on to the destination surface.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@33764 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
ericwa 2011-08-18 23:57:50 +00:00
parent ea63bbc0ff
commit f3a9150d7c
4 changed files with 397 additions and 439 deletions

View file

@ -34,6 +34,7 @@
#import <Foundation/NSGeometry.h>
#import <Foundation/NSObject.h>
#import <AppKit/AppKitDefines.h>
#import <AppKit/NSGraphicsContext.h>
@class NSString;
@class NSArray;
@ -147,6 +148,14 @@ enum {
- (BOOL)draw;
- (BOOL)drawAtPoint:(NSPoint)aPoint;
- (BOOL)drawInRect:(NSRect)aRect;
#if OS_API_VERSION(MAC_OS_X_VERSION_10_6, GS_API_LATEST)
- (BOOL) drawInRect: (NSRect)dstRect
fromRect: (NSRect)srcRect
operation: (NSCompositingOperation)op
fraction: (float)delta
respectFlipped: (BOOL)respectFlipped
hints: (NSDictionary*)hints;
#endif
//
// Managing NSImageRep Subclasses