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

NSShadow


  • Subject: NSShadow
  • From: M Pulis <email@hidden>
  • Date: Tue, 18 Nov 2008 02:19:38 -0700

Folks,

I have an NSControl, in IB i've set a shadow and a color (green). it has an IBOutlet and is "hooked" up to my controller. When my app is run, the checkbox has a lovely green shadow. Go baby go....

During runtime I want to change the shadow color - but am failing to do so. So, to simplify the logic...

In awake from nib I see the control (mCheckbox) is not nil, so I try to set the shadow color to black :

IBOutlet NSControl *mCheckBox;

/* awakefromnib */
NSShadow *aShadow = [mCheckbox shadow];
[aShadow setShadowColor:[[NSColor blackColor] colorWithAlphaComponent: 1.0]];
[mCheckbox setShadow:aShadow];


No change. No errors. Nothing nil.

Looks like it makes sense to me... but... it does not work, so, I'm missing something... somewhere... should be obvious.... just not to me.

Been searching docs and sample code bits (have not found an example of changing a shadow on a control) - trying foolish things - stuck. This has to be simpler than the two hours spent getting this far.

Thanks!

Gary
_______________________________________________

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


  • Follow-Ups:
    • Re: NSShadow
      • From: "Ken Ferry" <email@hidden>
  • Prev by Date: Re: Outlets / IBOutlet declarations (was Re: Interface Builder & Wiring Objects)
  • Next by Date: Re: Opening Ports in Leopard
  • Previous by thread: Re: core-data crash on save. [SOLVED]
  • Next by thread: Re: NSShadow
  • Index(es):
    • Date
    • Thread