• 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
Strange NSShadow behaviour in overlapping NSViews—bug?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Strange NSShadow behaviour in overlapping NSViews—bug?


  • Subject: Strange NSShadow behaviour in overlapping NSViews—bug?
  • From: Benjamin Dobson <email@hidden>
  • Date: Sun, 26 Apr 2009 21:59:08 +0100

Hello all,

I've subclassed NSButtonCell to provide custom drawing. This includes an NSShadow. All drawing is done inside the cell's bounds. As I want this to work easily in IB with minimum work, I've based it on the "Push" button style. This means the clickable button area is considerably smaller than the button's frame. This means putting two buttons next to each other overlaps the actual frame.

In this situation, the shadow in one of the two buttons is repeatedly drawn on top of itself, getting darker and decreasing in quality. Is this a bug or am I doing something wrong?

The code can be downloaded here: http://dl.getdropbox.com/u/896591/TestApp.zip

(Yes, I am making a set of HUD controls. And yes, I know there are a variety of third party frameworks available. However, I decided to create my own—both as a programming exercise and to avoid images.)_______________________________________________

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


  • Prev by Date: Re: FSPathCopyObjectSync and symbolic links?
  • Next by Date: Query regarding cursor change
  • Previous by thread: Re: NSTask, or threading?
  • Next by thread: Query regarding cursor change
  • Index(es):
    • Date
    • Thread