Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: quartz replacement for EraseRect???




On Oct 26, 2005, at 4:42 AM, Hans Loonen wrote:

When I run this the picturepart show up nicely however the background is
pitch black!
In the QuickDraw solution I used EraseRect to clear the background (now
commented out) and I replaced it with it's Quartz counter part
CGContextClearRect. With the described result. How can I get back my
window's normal background instead of just black?

You need to fill the context with white:

CGContextSetRGBFillColor( context, 1, 1, 1, 1 );
CGContextFillRect( context, cgrect );

PS in the documentation of EraseRect it says: "Using the patCopy pattern
....". Is there a Quartz equivalent for that?

There's no direct equivalent.

-eric

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Carbon-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/carbon-dev/email@hidden

This email sent to email@hidden
References: 
 >quartz replacement for EraseRect??? (From: "Hans Loonen" <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.