On Jul 31, 2008, at 2:20 PM, David Springer wrote:
I would like to add instances of a subclass of NSColor to the color
panel.  The problem is, when you change to another app that does not
know about this subclass, the NSColorPanel kind of freaks out and
shows all the colors as white (even the system colors) - in some cases
it just crashes the other app.  Is there a way I can tell NSColorPanel
to add my special colors only for my app, and not affect other apps?

The problem goes a bit deeper. At least in the past, if the user puts
a custom colors on the palette of colors, it would get archived and will
other apps may raise/crash trying to unarchive load the color list from
~/Library/Colors/NSColorPanelSwatches.plist.  If you do this, it would
be good to make sure your colors *archive* themselves as normal colors,
possibly using -replacementObjectForArchiver:, substituting a stock color.

-tim

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to