• 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: Darken image
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Darken image


  • Subject: Re: Darken image
  • From: Andreas Monitzer <email@hidden>
  • Date: Fri, 20 Jul 2001 02:39:40 +0200

On Friday, July 20, 2001, at 02:18 , Tom Waters wrote:

assuming the method signature that you left out was:

- (void)drawRect:(NSRect)theRect

you are using theRect (which has nothing to do with the size of anything,
since it's merely the rectangle that has been exposed via the union of a bunch of calls to needsDisplayInRect) as the fromRect parameter in your call to drawInRect... this would cause random results..

use NSZeroRect there to indicate you want the whole source image.

Ah, problem solved! Thanks! Even those strange drawing artifacts I got are gone :)

I experimented with those parameters and used the arguments that produced better results, seems that they weren't the best choice :-)

I've hacked on a more complete version of the sample I sent you last time,
I'll send it along in the next email...

Thanks!

I'm currently developing a Finder-like icon view (already did one in Classic Mac OS/Powerplant), I'll release the source when it's finished.

andy
--
Discussion forthcoming.


  • Prev by Date: Re: Darken image
  • Next by Date: Re: How to make a plugin?
  • Previous by thread: Re: Darken image
  • Next by thread: Where do I find detailed documentation on DO?
  • Index(es):
    • Date
    • Thread