Inherits from | |
Framework | /System/Library/Frameworks/AppKit.framework |
Companion guide | |
Declared in | NSColor.h |
This category adds a single method to the Foundation frameworkâs NSCoder class. This method, decodeNXColor
, is used to convert archived NXColor
structures into NSColor
objects.
NXColor
, a type that dates from pre-OpenStep versions of NEXTSTEP, was a struct
. Its replacement, NSColor
, is a class. The difficulties of converting from a struct
to a class require a special method like decodeNXColor
.
The decodeNXColor
method becomes part of the NSCoder
class only for applications that use the Application Kit.
Decodes a color structure from NEXTSTEP Release 3 or earlier and returns an NSColor
object.
- (NSColor *)decodeNXColor
An autoreleased NSColor
object. Returns nil
if the archived color is invalid.
This method does not have a matching method for encoding an NXColor
structure. Encode an NSColor
object instead.
NSColor.h
© 2006 Apple Computer, Inc. All Rights Reserved. (Last updated: 2006-05-23)