ftp.nice.ch/pub/next/tools/dock/Locus.1.0.NI.bs.tar.gz#/Locus/TechDocs/CustomIcons.rtf

This is CustomIcons.rtf in view mode; [Download] [Up]

Copyright 1993  Jeremy Slade.

You are free to use all or any parts of the Locus project
however you wish, just give credit where credit is due.
The author (Jeremy Slade) shall not be held responsible
for any damages that result out of use or misuse of any
part of this project.

JGS Thu Apr  8 21:50:48 PDT 1993


Custom Icon Support

	Items can be assigned a custom icon to be used according to the type(extension).  For example, all Items with an extension of .h could be assigned a special icon, while all items with an extension of .m could have a completely different one.  This is done by creating the icon and putting it in the ICONS_DIR, which is a subdirectory of the LIBRARY_DIR.  This is currently defined to be ~/Library/Locus/Icons.
	These icon files must be named according to the type(extension) of the files they are used for.  The name also indicates whether the icon is for the regular(large, 48x48) size icons, or the small, 24x24 icons.  The format of the name is:
	
			ext.large.tiff, ext.large.eps, etc.
		-- or --
			ext.small.tiff, ext.small.eps, etc.
			
	For example, the 1/4-size icon to be used for *.m files would be called: m.small.tiff
	
	The first time an item with a particular extension is to be draw, the ItemCell method -getIcon is called, which looks in the Custom Icon's dir first, and then asks the Workspace Manager for the Item's icon.  Once an icon is found, it is stored in a HashTable so that additional Items with the same extension will not have to repeat the process, but can instead just get the icon from table.  This table is built at run-time, and so all items with a particular extension will use the same icon for the life of that particular instance of Locus.app.  It might be useful at some point to have an option to empty the hash table and start over with 'fresh' icons so that custom icons can be added without having to restart.
	

These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.