Re: Upside Down
Re: Upside Down
- Subject: Re: Upside Down
- From: Scott Anguish <email@hidden>
- Date: Tue, 12 Aug 2003 17:58:17 -0400
Is your view flipped?
On Tuesday, August 12, 2003, at 1:32 PM, Lorenzo wrote:
Hi,
I don't understand why the API "drawInRect" draws the NSImage upside
down.
- (void)drawRect:(NSRect)theRect
{
NSRect fromRect = NSMakeRect(0, 0, [maskPressedSx size].width,
[maskPressedSx size].height);
NSRect imageRect = NSMakeRect(0, 0, [maskPressedSx size].width,
[maskPressedSx size].height);
[maskPressedSx drawInRect:imageRect fromRect:fromRect
operation:NSCompositeSourceOver fraction:1.0];
I guess that is because it works with the Y axis reversed.
If so, how to define the rects "fromRect" and "imageRect" in order to
draw
the image properly? Thank you.
Best Regards
--
Lorenzo
email: email@hidden
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
References: | |
| >Upside Down (From: Lorenzo <email@hidden>) |