Re: How to clear an NSImage
Re: How to clear an NSImage
- Subject: Re: How to clear an NSImage
- From: Marco Binder <email@hidden>
- Date: Sat, 12 Apr 2003 18:00:38 +0200
Since you seem to know, how to draw thing in your image as you say, why
dont you then just draw a big rectangle of [NSColor clearColor]?!
[myImage lockFocus];
[[NSColor clearColor] set];
NSFillRect(NSMakeRect(0,0,[myImage size].width, [myImage size].height));
[myImage unlockFocus];
MArco
Am Samstag, 12.04.03 um 13:45 Uhr schrieb Arthur VIGAN:
Hi,
my question is quite simple: I have an NSImage instance with
transparent background and things drawn on it, and I would like to
clear what is drawn to have my NSImage empty, just with the
transparent background. How can I do?
Thakns in advance,
-- Arthur
_______________________________________________
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.
--
|\ /| email@hidden
http://www.marco-binder.de
| \/ | Telefon: 07531 / 94 19 94 Fax: 07531 / 94 19 92
| |ARCO Snail-Mail: Banater Str. 3 - 78467 Konstanz
BINDER _____________________________________________________
_______________________________________________
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.