• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Transparent colors
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Transparent colors


  • Subject: Re: Transparent colors
  • From: "Ken Ferry" <email@hidden>
  • Date: Mon, 28 Jul 2008 23:18:10 -0700

Mm, okay, but I don't want people to get it in their heads that
something's wrong with these functions.  I'm pretty sure if you were
to investigate you'd find that it was something else.

I just ran a test suite and verified that NSRectFill and related
functions are not munging the compositing mode in the context.

-Ken
Cocoa Frameworks

On Mon, Jul 28, 2008 at 9:21 PM, Graham Cox <email@hidden> wrote:
> OK, thanks for the clarification.
>
> A bit odd though - on Tiger I was using a transparent colour with NSRectFill
> and that worked OK, whatever was drawing "underneath" came out as expected.
> On Leopard, it still draws that rect OK, but anything drawn underneath this
> rect (using the usual bezier path fill/stroke methods) suddenly draws in a
> different composition mode, as if the underlying graphics context got
> changed to something else but not changed back by the NSRectFill.
>
> However take this "analysis" with a pinch of salt because I didn't pursue
> the problem, I just changed to not using NSRectFill.
>
> Graham
>
>
> On 29 Jul 2008, at 12:59 pm, Ken Ferry wrote:
>
>> To draw on top of existing color rather than replacing it, you don't
>> want NSRectFill.  There you want NSRectFillUsingOperation with the
>> NSCompositeSourceOver operation.  That should be considered the
>> 'normal' drawing mode, so it's somewhat unfortunate that the nice
>> convenient looking NSRectFill uses copy mode.
>
>
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Transparent colors (From: Dale Miller <email@hidden>)
 >Re: Transparent colors (From: Graham Cox <email@hidden>)
 >Re: Transparent colors (From: "Ken Ferry" <email@hidden>)
 >Re: Transparent colors (From: "Ken Ferry" <email@hidden>)
 >Re: Transparent colors (From: Graham Cox <email@hidden>)

  • Prev by Date: Re: Pre-requisites for automatic image highlighting in NSButton?
  • Next by Date: Re: Authenticate Password.
  • Previous by thread: Re: Transparent colors
  • Next by thread: Re: Transparent colors
  • Index(es):
    • Date
    • Thread