This file is indexed.

/usr/include/GNUstep/AppKit/NSColorList.h is in libgnustep-gui-dev 0.26.2-3.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
/* 
   NSColorList.h

   Manage named lists of NSColors.

   Copyright (C) 1996 Free Software Foundation, Inc.

   Author:  Scott Christley <scottc@net-community.com>
   Date: 1996
   Author: Nicola Pero <n.pero@mi.flashnet.it>
   Date: 2000
   
   This file is part of the GNUstep GUI Library.

   This library is free software; you can redistribute it and/or
   modify it under the terms of the GNU Lesser General Public
   License as published by the Free Software Foundation; either
   version 2 of the License, or (at your option) any later version.

   This library is distributed in the hope that it will be useful,
   but WITHOUT ANY WARRANTY; without even the implied warranty of
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.	 See the GNU
   Lesser General Public License for more details.

   You should have received a copy of the GNU Lesser General Public
   License along with this library; see the file COPYING.LIB.
   If not, see <http://www.gnu.org/licenses/> or write to the 
   Free Software Foundation, 51 Franklin Street, Fifth Floor, 
   Boston, MA 02110-1301, USA.
*/ 

#ifndef _GNUstep_H_NSColorList
#define _GNUstep_H_NSColorList
#import <GNUstepBase/GSVersionMacros.h>

#import <Foundation/NSObject.h>
#import <AppKit/AppKitDefines.h>

@class NSString;
@class NSArray;
@class NSMutableArray;
@class NSDictionary;
@class NSMutableDictionary;

@class NSColor;

@interface NSColorList : NSObject <NSCoding>

{
  NSString* _name;
  NSString* _fullFileName;
  BOOL _is_editable;

  // Color Lists are required to be a sort of ordered dictionary
  // For now it is implemented as follows (Scott Christley, 1996):

  // This object contains couples (keys (=color names), values (=colors))
  NSMutableDictionary* _colorDictionary;

  // This object contains the keys (=color names) in order
  NSMutableArray* _orderedColorKeys;
}

//
// Initializing an NSColorList
//
/**
 * Initializes a new, empty color list registered under given name.
 */
- (id) initWithName: (NSString *)name;

/**
 * <p>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 <em>without</em> the extension.)</p>
 *  
 * <p>The format of the file can be either an archive of an NSColorList
 * or an ASCII format.  ASCII files follow this format:</p>
 *
 * <p>first line  =  [#/colors] <br/>
 * each subsequent line describes a color as [int float+ string] <br/>
 * the first int describes the method (RGBA, etc.), the floats
 * provide its arguments (e.g., r, g, b, alpha), and string is name.</p>
 *
 * <p>The <em>method</em> 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.</p>
 */
- (id) initWithName: (NSString *)name
	   fromFile: (NSString *)path;

//
// Getting All Color Lists
//
+ (NSArray *) availableColorLists;

/** Returns the first color list (from the array of available lists)
 * matching name.
 */
+ (NSColorList *) colorListNamed: (NSString *)name;

/** Returns an array containing all the keyus in the color list
 */
- (NSArray *) allKeys;

/** Returns the color for the specified key (if any).
 */
- (NSColor *) colorWithKey: (NSString *)key;

/**
 * Returns a flag indicating whether the receiver is editable.
 */
- (BOOL) isEditable;

/** Inserts a color into the color list at the specified index.
 * Removes any other color with the same name.
 */
- (void) insertColor: (NSColor *)color
		 key: (NSString *)key
	     atIndex: (unsigned)location;

/**
 * Returns the name of the receiver.
 */
- (NSString *) name;

/** Removes the color for the specified key from the list.
 */
- (void) removeColorWithKey: (NSString *)key;

/** Removes the on-disk representation of the list.
 */
- (void) removeFile;

/**
 * Sets the color for this key and appends it to the color list.
 */
- (void) setColor: (NSColor *)aColor
	   forKey: (NSString *)key;

/**
 * Writes the receiver to the specified path.<br />
 * If path is nil, writes to a file located in the current user's personal
 * Colors directory whose name is that of the list with the extension
 * 'clr' appended.<br />
 * If path is a directory, writes to a file in that directory whose name
 * is that of the list with the extension 'clr' appended.<br />
 * Otherwise (path is neither nil nor a directory), writes to the path
 * without appending the l.ist name.<br />
 * Returns YES on success, NO on failure.<br />
 * Writing with a path of nil will cause the receiver to be added to the
 * +availableColorLists if it is not already there.
 */
- (BOOL) writeToFile: (NSString *)path;

//
// NSCoding protocol
//
- (void) encodeWithCoder: (NSCoder *)aCoder;
- (id) initWithCoder: (NSCoder *)aDecoder;

@end

/* Notifications */
APPKIT_EXPORT NSString *NSColorListDidChangeNotification;

#endif // _GNUstep_H_NSColorList