Apple II
File Type Notes
_____________________________________________________________________________
Developer Technical Support
File Type: $CA (202)
Auxiliary Type: Reserved
Full Name: Finder Icons File
Short Name: Icons
Written by: Matt Deatherage July 1989
Files of this type and auxiliary type contain icons.
_____________________________________________________________________________
The Apple IIGS Finder keeps the icons it uses in files of type $CA. The
Finder searches for these files in a directory named Icons on each volume
mounted. Each icon contains information not only describing the icon and its
mask (both regular and "small icon" sizes), but also information to match the
icon to files from their file type, auxiliary type, and filename.
The Finder first attempts to load the file Finder.Icons from the Icons
directory on the boot disk, stopping with a fatal error if it is not present
(this file contains icons for devices as well as the icon to match files with
no other icon). It then loads other icon files from that directory, and then
from other disks.
The format of icon files is as follows:
+000 iBlkNext Long When loaded by the Finder, this is the
handle to the next icon file (a linked
list terminated by zero). On disk, this
field should be zero.
+004 iBlkID Word ID number of this type of icon file. This
field must be $0001 for the Finder to
recognize the icon file.
+006 iBlkPath Long When loaded by the Finder, this is the
handle to the pathname of this icon file.
On disk, this field should be zero.
+010 iBlkName 16 Bytes A 16-byte String of the name of the icon
file.
+026 iBlkIcons IconData A list of Icon Data records.
The format of Icon Data records is as follows:
+000 iDataLen Word The length of this Icon Data record. A
value of zero in this field terminates the
list of Icon Data records.
+002 iDataBoss 64 Bytes The pathname of the
application that owns this icon. If this
String has non-zero length, and the file
this icon is associated with is a document
(not an application, folder, device, or
trash can), the Finder attempts to launch
a file with this pathname when this icon
is opened or printed. This string should
be empty for non-documents. This is a
full pathname, and most developers
creating icons will wish to set this to
the full pathname of the application on
the shipping disk.
+066 iDataName 16 Bytes A 16-byte String containing a
file name. Files on disk must match the
specification of this string or this icon
will not be displayed for the files. The
asterisk (*) serves as a wildcard
character. For example, the string *.ASM
matches all filenames ending with the
characters .ASM.
+082 iDatatype Word File type associated with this icon.
Files on disk must have this file type for
this icon to be displayed. A file type of
$0000 in this field matches any file type
on disk. As an example, an application
icon would want to have the filename of
the application in the iDataName field and
the file type $00B3 (GS/OS Application) in
this field. Without the file type
specification, the icon would show up for
any file with the application's file name,
including a folder on a hard disk in which
the user has placed the application.
+084 iDataAux Word Auxiliary type associated with this icon.
Similar to the file type field, a value of
$0000 here matches any auxiliary type on
disk.
+086 iDataBig Icon The normal size icon image data.
iDataSmall Icon The small size icon image data.
The format of Icon records is the same as that listed in the QuickDraw II
Auxiliary chapter of the Apple IIGS Toolbox Reference Manual. Previous icon
structure documentation stated the iconType field of the Icon record (also
known as the imType field) had to be zero. This is no longer true; the Finder
respects color icons (bit 15 of iconType set) by not coloring the icon in
funny ways, even if the user asks for it. The Finder still does this if bit
15 of iconType says the icon is a black-and-white icon.
Further Reference
_____________________________________________________________________________
o Apple IIGS Toolbox Reference, Volume 2
o Apple IIGS Icon Editor