Up
Authors
- Scott Christley (
scottc@net-community.com
)
-
- Nicola Pero (
n.pero@mi.flashnet.it
)
-
Manage named lists of NSColors.
Copyright: (C) 1996, 2000 Free Software Foundation, Inc.
- Declared in:
- AppKit/NSColorList.h
- Conforms to:
- NSCoding
Availability: OpenStep
Description forthcoming.
Instance Variables
Method summary
+ (NSArray*)
availableColorLists;
Availability: OpenStep
Description forthcoming.
+ (
NSColorList*)
colorListNamed: (NSString*)name;
Availability: OpenStep
Description forthcoming.
- (NSArray*)
allKeys;
Availability: OpenStep
Description forthcoming.
- (
NSColor*)
colorWithKey: (NSString*)key;
Availability: OpenStep
Description forthcoming.
- (void)
encodeWithCoder: (NSCoder*)aCoder;
Availability: OpenStep
Description forthcoming.
- (id)
initWithCoder: (NSCoder*)aDecoder;
Availability: OpenStep
Description forthcoming.
- (id)
initWithName: (NSString*)name;
Availability: OpenStep
Initializes a new, empty color list registered
under given name.
- (id)
initWithName: (NSString*)name
fromFile: (NSString*)path;
Availability: OpenStep
Initializes a new color list registered under
given name, taking contents from the
file specified in path. (Path should
include the filename with extension (usually
".clr"), and by convention name
should be the same as filename without
the extension.)
The format of the file can be either an archive of an
NSColorList or an ASCII format. ASCII files
follow this format:
first line = [#/colors]
each subsequent line
describes a color as [int
float+ string]
the first
int describes the method (RGBA,
etc.), the floats provide its arguments (e.g., r,
g, b, alpha), and string is name.
The method corresponds to one of the
NSColor
initializers. We are looking for
documentation of the exact correspondence
on OpenStep; for now the only supported method is
"0", which is an RGBA format with the arguments in
order R,G,B, A.
- (void)
insertColor: (
NSColor*)color
key: (NSString*)key
atIndex: (unsigned)location;
Availability: OpenStep
Description forthcoming.
- (BOOL)
isEditable;
Availability: OpenStep
Description forthcoming.
- (NSString*)
name;
Availability: OpenStep
Description forthcoming.
- (void)
removeColorWithKey: (NSString*)key;
Availability: OpenStep
Description forthcoming.
- (void)
removeFile;
Availability: OpenStep
Description forthcoming.
- (void)
setColor: (
NSColor*)aColor
forKey: (NSString*)key;
Availability: OpenStep
Description forthcoming.
- (BOOL)
writeToFile: (NSString*)path;
Availability: OpenStep
Description forthcoming.
Instance Variables for NSColorList Class
@protected NSMutableDictionary* _colorDictionary;
Warning the underscore at the start of the
name of this instance variable indicates that, even
though it is not technically private, it is
intended for internal use within the package, and
you should not use the variable in other code.
@protected NSString* _fullFileName;
Warning the underscore at the start of the
name of this instance variable indicates that, even
though it is not technically private, it is
intended for internal use within the package, and
you should not use the variable in other code.
@protected BOOL _is_editable;
Warning the underscore at the start of the
name of this instance variable indicates that, even
though it is not technically private, it is
intended for internal use within the package, and
you should not use the variable in other code.
@protected NSString* _name;
Warning the underscore at the start of the
name of this instance variable indicates that, even
though it is not technically private, it is
intended for internal use within the package, and
you should not use the variable in other code.
@protected NSMutableArray* _orderedColorKeys;
Warning the underscore at the start of the
name of this instance variable indicates that, even
though it is not technically private, it is
intended for internal use within the package, and
you should not use the variable in other code.
Up